2004-09-30 19:20:20 -04:00
|
|
|
#! /bin/bash
|
2004-06-08 19:42:22 -04:00
|
|
|
|
2006-07-04 00:01:16 -04:00
|
|
|
COMMON_FLAGS="OFFICIAL_BUILD=1 SHARED=1 MONOLITHIC=0 USE_OPENGL=1 CXXFLAGS=/D__NO_VC_CRTDBG__ "
|
2004-12-16 20:22:27 -05:00
|
|
|
HYBRID_FLAGS="DEBUG_FLAG=1 WXDEBUGFLAG=h"
|
2004-06-08 19:42:22 -04:00
|
|
|
MAKE_FLAGS=$COMMON_FLAGS
|
|
|
|
|
|
|
|
|
|
|
|
# set flags based on build type if given
|
|
|
|
if [ "$1" = "debug" ]; then
|
|
|
|
MAKE_FLAGS="$COMMON_FLAGS BUILD=debug UNICODE=0 MSLU=0"
|
|
|
|
shift
|
|
|
|
|
|
|
|
elif [ "$1" = "hybrid" ]; then
|
|
|
|
MAKE_FLAGS="$COMMON_FLAGS BUILD=release $HYBRID_FLAGS UNICODE=0 MSLU=0"
|
|
|
|
shift
|
|
|
|
|
|
|
|
elif [ "$1" = "release" ]; then
|
|
|
|
MAKE_FLAGS="$COMMON_FLAGS BUILD=release UNICODE=0 MSLU=0"
|
|
|
|
shift
|
|
|
|
|
|
|
|
elif [ "$1" = "debug-uni" ]; then
|
|
|
|
MAKE_FLAGS="$COMMON_FLAGS BUILD=debug UNICODE=1 MSLU=1"
|
|
|
|
shift
|
|
|
|
|
|
|
|
elif [ "$1" = "hybrid-uni" ]; then
|
|
|
|
MAKE_FLAGS="$COMMON_FLAGS BUILD=release $HYBRID_FLAGS UNICODE=1 MSLU=1"
|
|
|
|
shift
|
|
|
|
|
|
|
|
elif [ "$1" = "release-uni" ]; then
|
|
|
|
MAKE_FLAGS="$COMMON_FLAGS BUILD=release UNICODE=1 MSLU=1"
|
|
|
|
shift
|
|
|
|
else
|
|
|
|
echo "----------------------------------------------"
|
|
|
|
echo " Build type not specified"
|
|
|
|
echo " debug"
|
|
|
|
echo " hybrid"
|
|
|
|
echo " release"
|
|
|
|
echo " debug-uni"
|
|
|
|
echo " hybrid-uni"
|
|
|
|
echo " release-uni"
|
|
|
|
echo "----------------------------------------------"
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
|
# now run nmake, echoing the command-line first
|
|
|
|
echo nmake -f makefile.vc $MAKE_FLAGS $@
|
|
|
|
nmake -f makefile.vc $MAKE_FLAGS $@
|
|
|
|
|
|
|
|
# quit with nmake's exit code
|
|
|
|
exit $?
|
|
|
|
|
|
|
|
|