clutchlog/build_all.sh
nojhan 243b22e4c1 feat: optimize out in Release builds
- fix: fastest scope matching,
- feat: try to allow the compiler to optimize out as many conditional statements as possible,
        which allow to use clutchlog for progress-only messages in Release mode.
- feat: build_all.sh test script,
- fix: typo in macro declarations in builds without clutchlog,
- update the README accordingly.
2020-09-15 23:12:19 +02:00

25 lines
469 B
Bash
Executable file

#!/bin/bash
build()
{
build_dir="$1_$2"
mkdir -p $build_dir
cd $build_dir
echo -ne "Build type: $1,\twith clutchlog: $2...\t"
(cmake -DCMAKE_BUILD_TYPE=$1 -DWITH_CLUTCHLOG=$2 .. && make && ctest) 2>&1 >> ../build_all.log
if [[ $? == 0 ]]; then
echo "OK"
else
echo "ERROR"
fi
cd ..
}
rm -f build_all.log
for t in "Debug" "Release" "RelWithDebInfo"; do
for w in "ON" "OFF"; do
build $t $w
done
done