7 rm -rf $WORKSPACE/build
12 export PATH=./lib/:../../lib:$PATH
14 if test "$(uname -o)" = "Msys"
17 cmake -G "MSYS Makefiles" $WORKSPACE
18 #$NUMBER_OF_PROCESSORS should be already set on win
19 if [ -z "$NUMBER_OF_PROCESSORS" ]; then
20 NUMBER_OF_PROCESSORS=1
23 if [ $? -ne 0 ] ; then
24 echo "Failed to do the first cmake - Halting"
30 if [ $? -ne 0 ] ; then
31 echo "Failed to build dist - Halting"
35 cmake -G "MSYS Makefiles" -Denable_java=ON -Denable_model-checking=OFF -Denable_lua=OFF -Denable_compile_optimizations=ON -Denable_smpi=ON -Denable_smpi_MPICH3_testsuite=ON -Denable_compile_warnings=OFF .
37 if [ $? -ne 0 ] ; then
38 echo "Failed to perform the Cmake for $build_mode - Halting"
42 make -j$NUMBER_OF_PROCESSORS
44 if [ $? -ne 0 ] ; then
45 echo "Build failure - Halting"
51 if [ $? -ne 0 ] ; then
52 echo "Failure while generating the Windows executable - Halting"
57 NUMBER_OF_PROCESSORS=0
59 cpuinfo_file="/proc/cpuinfo"
60 if [ -f "${cpuinfo_file}" ]; then
61 NUMBER_OF_PROCESSORS=$(grep -c "processor.: " ${cpuinfo_file})
63 # grep returns 0 or cpuinfo not found
64 if [ $NUMBER_OF_PROCESSORS = 0 ]; then
65 NUMBER_OF_PROCESSORS=1
70 if [ $? -ne 0 ] ; then
71 echo "Failed to do the first cmake - Halting"
78 if [ $? -ne 0 ] ; then
79 echo "Failed to build dist - Halting"
83 tar xzf `cat VERSION`.tar.gz
85 if [ $? -ne 0 ] ; then
86 echo "Failed to extract the generated tgz - Halting"
92 if [ $? -ne 0 ] ; then
93 echo "Path `cat VERSION` cannot be found - Halting"
97 if [ "$build_mode" = "Debug" ]
99 cmake -Denable_coverage=ON -Denable_java=ON -Denable_model-checking=OFF -Denable_lua=ON -Denable_compile_optimizations=ON -Denable_smpi=ON -Denable_smpi_MPICH3_testsuite=ON -Denable_compile_warnings=ON .
102 if [ "$build_mode" = "ModelChecker" ]
104 cmake -Denable_coverage=ON -Denable_java=ON -Denable_smpi=ON -Denable_model-checking=ON -Denable_lua=ON -Denable_compile_optimizations=OFF -Denable_compile_warnings=ON .
107 if [ "$build_mode" = "DynamicAnalysis" ]
109 cmake -Denable_lua=OFF -Denable_java=ON -Denable_tracing=ON -Denable_smpi=ON -Denable_compile_optimizations=OFF -Denable_compile_warnings=ON -Denable_lib_static=OFF -Denable_model-checking=OFF -Denable_latency_bound_tracking=OFF -Denable_gtnets=OFF -Denable_jedule=OFF -Denable_mallocators=OFF -Denable_memcheck=ON .
112 if [ $? -ne 0 ] ; then
113 echo "Failed to perform the Cmake for $build_mode - Halting"
117 make -j$NUMBER_OF_PROCESSORS
119 if [ $? -ne 0 ] ; then
120 echo "Build failure - Halting"
127 echo "running tests with $NUMBER_OF_PROCESSORS processors"
129 ctest -T test --no-compress-output --timeout 100 -j$NUMBER_OF_PROCESSORS || true
130 if [ -f Testing/TAG ] ; then
131 xsltproc $WORKSPACE/buildtools/jenkins/ctest2junit.xsl -o "$WORKSPACE/CTestResults.xml" Testing/`head -n 1 < Testing/TAG`/Test.xml
134 ctest -D ContinuousStart
135 ctest -D ContinuousConfigure
136 ctest -D ContinuousBuild
137 ctest -D ContinuousTest
138 ctest -D ContinuousSubmit