Commit fa5f7738 authored by Martin Beseda's avatar Martin Beseda

ENH + NEW: Added variable check to build.sh and created new build-ci.sh with...

ENH + NEW: Added variable check to build.sh and created new build-ci.sh with configuration for CI runner server.
parent ac656f1c
......@@ -8,6 +8,6 @@ job:
- git clone https://github.com/ArashPartow/exprtk.git
- cp exprtk/exprtk.hpp /usr/include
- export TERM=xterm
- ./build.sh
- ./build-ci.sh
script: "./run_tests.sh"
#!/bin/sh
#------------#------------------------------------------------------------
# Parameters #
#------------#
# Build type (Release/Debug)
BUILD_TYPE=Debug
# C++ compiler
CXX_COMPILER="g++"
if [ -z "$BUILD_TYPE" ] || [ -z "$CXX_COMPILER" ]; then
(>&2 echo "Set, please, both BUILD_TYPE and CXX_COMPILER variables in the 'build.sh' script.")
exit 2
fi
$(pwd)/clean.sh
cmake -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON -DCMAKE_BUILD_TYPE=${BUILD_TYPE} -DCMAKE_CXX_COMPILER=${CXX_COMPILER} .
cmake --build . --config ${BUILD_TYPE} -- -j${N_CORES} && (tput setaf 2; echo "Build complete."; echo "For examples have a look at the folder build/bin/examples."; tput sgr 0; ) || (tput setaf 1; echo "Build finished with errors!"; tput sgr 0; exit 1;)
......@@ -5,11 +5,15 @@
#------------#
# Build type (Release/Debug)
BUILD_TYPE=Debug
BUILD_TYPE=
# C++ compiler
CXX_COMPILER="g++-8"
CXX_COMPILER=
if [ -z "$BUILD_TYPE" ] || [ -z "$CXX_COMPILER" ]; then
(>&2 echo "Set, please, both BUILD_TYPE and CXX_COMPILER variables in the 'build.sh' script.")
exit 2
fi
$(pwd)/clean.sh
cmake -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON -DCMAKE_BUILD_TYPE=${BUILD_TYPE} -DCMAKE_CXX_COMPILER=${CXX_COMPILER} .
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment