]> git.stg.codes - stg.git/blobdiff - projects/sgconf_xml/build
Massive refactoring.
[stg.git] / projects / sgconf_xml / build
index c4ff46b55b14967da3d8219d956d2a3bdc546f23..6816a4362647ab793ade6b7162adb016b28737fd 100755 (executable)
@@ -16,18 +16,15 @@ DATA_MODE=0644
 DIR_MODE=0755
 OWNER=root
 
 DIR_MODE=0755
 OWNER=root
 
-if [ -z $1 ]
+if [ "$1" = "debug" ]
 then
 then
-    MAKEOPTS="-j1"
+   DEFS="$DEFS -DDEBUG"
+   MAKEOPTS="$MAKEOPTS -j1"
+   CXXFLAGS="$CXXFLAGS -ggdb3 -W -Wall -Wextra"
+   DEBUG="yes"
 else
 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"
 fi
 
 CXXFLAGS="$CXXFLAGS -I/usr/local/include"
@@ -48,6 +45,7 @@ then
         6) OS=bsd5;;   
         7) OS=bsd7;;
         8) OS=bsd7;;
         6) OS=bsd5;;   
         7) OS=bsd7;;
         8) OS=bsd7;;
+        9) OS=bsd7;;
         *) OS=unknown;;
     esac
     MAKE="gmake"
         *) OS=unknown;;
     esac
     MAKE="gmake"
@@ -165,6 +163,7 @@ fi
 
 echo "OS=$OS" > $CONFFILE
 echo "STG_TIME=yes" >> $CONFFILE
 
 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
 echo "DIR_BUILD=$BUILD_DIR" >> $CONFFILE
 echo "DIR_LIB=\$(DIR_BUILD)/../../lib" >> $CONFFILE
 echo "DIR_LIBSRC=\$(DIR_BUILD)/../../stglibs" >> $CONFFILE