2013-05-27 16:55:01 -07:00
|
|
|
#!/bin/bash
|
|
|
|
# Param1: The prefix to mingw staging
|
|
|
|
# Param2: Path to java comparison tool
|
|
|
|
# Param3: Number of make jobs. Defaults to 1.
|
|
|
|
|
|
|
|
set -e
|
|
|
|
set -o xtrace
|
|
|
|
|
|
|
|
MINGWPREFIX=$1
|
|
|
|
JAVA_COMPARISON_TOOL=$2
|
|
|
|
JOBS=${3-1}
|
|
|
|
|
|
|
|
if [ $# -lt 2 ]; then
|
|
|
|
echo "Usage: $0 [mingw-prefix] [java-comparison-tool] <make jobs>"
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
DISTDIR=@PACKAGE@-@VERSION@
|
|
|
|
|
2013-10-06 20:10:22 -07:00
|
|
|
# Test win32 build first (it breaks the most often)
|
|
|
|
cd @abs_top_srcdir@
|
|
|
|
make distdir
|
|
|
|
mv $DISTDIR win32-build
|
|
|
|
cd win32-build
|
|
|
|
./configure --disable-silent-rules --disable-ccache --prefix=$MINGWPREFIX --host=i586-mingw32msvc --with-qt-bindir=$MINGWPREFIX/host/bin --with-qt-plugindir=$MINGWPREFIX/plugins --with-qt-incdir=$MINGWPREFIX/include --with-boost=$MINGWPREFIX --with-protoc-bindir=$MINGWPREFIX/host/bin CPPFLAGS=-I$MINGWPREFIX/include LDFLAGS=-L$MINGWPREFIX/lib
|
|
|
|
make -j$JOBS
|
|
|
|
make check
|
|
|
|
|
|
|
|
# ... then linux build, with blockchain-tester:
|
2013-05-27 16:55:01 -07:00
|
|
|
cd @abs_top_srcdir@
|
|
|
|
make distdir
|
|
|
|
mv $DISTDIR linux-build
|
|
|
|
cd linux-build
|
2013-10-06 20:10:22 -07:00
|
|
|
./configure --disable-silent-rules --disable-ccache --with-comparison-tool="$JAVA_COMPARISON_TOOL"
|
2013-05-27 16:55:01 -07:00
|
|
|
make -j$JOBS
|
|
|
|
make check
|
|
|
|
|
2013-10-06 20:10:22 -07:00
|
|
|
# Test code coverage
|
2013-05-27 16:55:01 -07:00
|
|
|
cd @abs_top_srcdir@
|
|
|
|
make distdir
|
|
|
|
mv $DISTDIR linux-coverage-build
|
|
|
|
cd linux-coverage-build
|
|
|
|
./configure --enable-lcov --with-comparison-tool="$JAVA_COMPARISON_TOOL"
|
|
|
|
make -j$JOBS
|
|
|
|
make cov
|
|
|
|
|