X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/2390d2729b5230dc87c948907f54293a2df760c5..7a5ef6cec95532655577ead42337d03d2b66f21c:/projects/rlm_stg/build diff --git a/projects/rlm_stg/build b/projects/rlm_stg/build index 0145d038..91fe7d9d 100755 --- a/projects/rlm_stg/build +++ b/projects/rlm_stg/build @@ -16,18 +16,15 @@ DATA_MODE=0644 DIR_MODE=0755 OWNER=root -if [ -z $1 ] +if [ "$1" = "debug" ] then - MAKEOPTS="-j1" + DEFS="$DEFS -DDEBUG" + MAKEOPTS="$MAKEOPTS -j1" + CXXFLAGS="$CXXFLAGS -ggdb3 -W -Wall -Wextra" + DEBUG="yes" else - if [ "$1" = "debug" ] - then - DEFS="-DDEBUG" - MAKEOPTS="-j1" - CXXFLAGS="$CXXFLAGS -ggdb3 -W -Wall" - else - MAKEOPTS="-j1" - fi + DEFS="$DEFS -DNDEBUG" + DEBUG="no" fi CXXFLAGS="$CXXFLAGS -I/usr/local/include" @@ -144,6 +141,7 @@ rm -f fake echo "OS=$OS" > $CONFFILE echo "STG_TIME=yes" >> $CONFFILE +echo "DEBUG=$DEBUG" >> $CONFFILE echo "DIR_BUILD=$BUILD_DIR" >> $CONFFILE echo "DIR_LIB=\$(DIR_BUILD)/../../lib" >> $CONFFILE echo "DIR_LIBSRC=\$(DIR_BUILD)/../../stglibs" >> $CONFFILE