5 # usage: die status message...
9 [ $# -gt 0 ] || set -- "Error - Halting"
14 # Get an ON/OFF string from a command:
16 if "$@" > /dev/null ; then
24 echo "Build mode $build_mode on $(uname -np)" >&2
36 die 1 "Unknown build_mode $build_mode"
40 if test "$(uname -o)" = "Msys"; then
41 if [ -z "$NUMBER_OF_PROCESSORS" ]; then
42 NUMBER_OF_PROCESSORS=1
44 GENERATOR="MSYS Makefiles"
46 NUMBER_OF_PROCESSORS="$(nproc)" || NUMBER_OF_PROCESSORS=1
47 GENERATOR="Unix Makefiles"
52 if [ -d $WORKSPACE/build ]
54 rm -rf $WORKSPACE/build
56 mkdir $WORKSPACE/build
59 cmake -G"$GENERATOR" -Denable_documentation=OFF $WORKSPACE
60 make dist -j$NUMBER_OF_PROCESSORS
61 tar xzf `cat VERSION`.tar.gz
65 -Denable_debug=ON -Denable_documentation=OFF -Denable_coverage=OFF \
66 -Denable_model-checking=$(onoff test "$build_mode" = "ModelChecker") \
67 -Denable_compile_optimization=$(onoff test "$build_mode" = "Debug") \
68 -Denable_smpi_MPICH3_testsuite=$(onoff test "$build_mode" != "DynamicAnalysis") \
69 -Denable_lua=$(onoff test "$build_mode" != "DynamicAnalysis") \
70 -Denable_mallocators=$(onoff test "$build_mode" != "DynamicAnalysis") \
71 -Denable_memcheck=$(onoff test "$build_mode" = "DynamicAnalysis") \
72 -Denable_compile_warnings=ON -Denable_smpi=ON -Denable_lib_static=OFF \
73 -Denable_latency_bound_tracking=OFF -Denable_gtnets=OFF -Denable_jedule=OFF \
74 -Denable_tracing=ON -Denable_java=ON
75 make -j$NUMBER_OF_PROCESSORS
82 ctest -T test --output-on-failure --no-compress-output || true
83 if [ -f Testing/TAG ] ; then
84 xsltproc $WORKSPACE/buildtools/jenkins/ctest2junit.xsl Testing/`head -n 1 < Testing/TAG`/Test.xml > CTestResults.xml
85 mv CTestResults.xml $WORKSPACE
88 if [ "$build_mode" = "DynamicAnalysis" ]
90 ctest -D ContinuousStart
91 ctest -D ContinuousConfigure
92 ctest -D ContinuousBuild
93 ctest -D ContinuousMemCheck
94 ctest -D ContinuousSubmit
97 ctest -D ContinuousStart
98 ctest -D ContinuousConfigure
99 ctest -D ContinuousBuild
100 ctest -D ContinuousTest
101 ctest -D ContinuousSubmit