@@ -4,7 +4,7 @@ if [ -z "$INSTALL_PATH" ]; then
echo
echo 'Error: No $INSTALL_PATH defined'
echo
- echo " usage: [PREFIX=prefix][BUILD_PATH=/path/to/build] INSTALL_PATH=/path/to/install make-trace-cmd.sh install|install_libs|clean|uninstall"
+ echo " usage: [PREFIX=prefix][BUILD_PATH=/path/to/build][CFLAGS=custom-cflags] INSTALL_PATH=/path/to/install make-trace-cmd.sh install|install_libs|clean|uninstall"
echo
echo " Used to create a self contained directory to copy to other machines."
echo
@@ -36,4 +36,8 @@ if pkg-config --with-path=/tmp --variable pc_path pkg-config &> /dev/null ; then
WITH_PATH="--with-path=$INSTALL_PATH$PKG_PATH"
fi
-PKG_CONFIG_PATH="$INSTALL_PATH/$PKG_PATH" PKG_CONFIG="pkg-config $WITH_PATH --define-variable=prefix=$INSTALL_PATH/$PREFIX" CFLAGS="-g -Wall -I$INSTALL_PATH/$PREFIX/include" make DESTDIR=$INSTALL_PATH $O_PATH prefix=$PREFIX $@
+if [ -z "$CFLAGS" ]; then
+ CFLAGS="-g -Wall"
+fi
+
+PKG_CONFIG_PATH="$INSTALL_PATH/$PKG_PATH" PKG_CONFIG="pkg-config $WITH_PATH --define-variable=prefix=$INSTALL_PATH/$PREFIX" CFLAGS="-I$INSTALL_PATH/$PREFIX/include $CFLAGS" make DESTDIR=$INSTALL_PATH $O_PATH prefix=$PREFIX $@