DESTDIR=$2
SKIPCLEAN=$3
VERSION=$4
-shift;shift;shift;shift
-PYVER=$@
+PYVER=$5
# WXDIR is the cygwin path, WXWIN is the DOS path
export WXWIN
-# # Fix the PATH. (Why is this needed??)
-# PATH=/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/home/robind/bin:.:$WXDIR/lib/vc_dll:$PATH
-# export PATH
-# echo "-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-="
-# echo $PATH
-# echo "-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-="
-# exit 0
+
+# setup the compiler
+if [ $PYVER = 2.3 ]; then
+ echo "Using MSVC ver 6"
+ . msvcset local 6
+ echo `which cl.exe`
+else
+ echo "Using MSVC ver 7"
+ . msvcset local 7
+ echo `which cl.exe`
+fi
# untar the source
echo "Setting up for the build..."
cd $WXDIR/build/msw
cp $WXDIR/wxPython/distrib/msw/.m* .
+chmod +x .m*
# replace some settings in setup0.h and write to setup.h
cat > .my.sedexpr <<EOF
s/wxDIALOG_UNIT_COMPATIBILITY *1/wxDIALOG_UNIT_COMPATIBILITY 0/g
+s/wxUSE_EXCEPTIONS *1/wxUSE_EXCEPTIONS 0/g
s/wxUSE_DEBUG_CONTEXT *0/wxUSE_DEBUG_CONTEXT 1/g
s/wxUSE_MEMORY_TRACING *0/wxUSE_MEMORY_TRACING 1/g
s/wxUSE_DIALUP_MANAGER *1/wxUSE_DIALUP_MANAGER 0/g
s/wxUSE_POSTSCRIPT *0/wxUSE_POSTSCRIPT 1/g
s/wxUSE_AFM_FOR_POSTSCRIPT *1/wxUSE_AFM_FOR_POSTSCRIPT 0/g
s/wxUSE_DISPLAY *0/wxUSE_DISPLAY 1/g
+s/wxUSE_DIB_FOR_BITMAP *0/wxUSE_DIB_FOR_BITMAP 1/g
+s/wxUSE_DEBUGREPORT *1/wxUSE_DEBUGREPORT 0/g
EOF
cat $WXDIR/include/wx/msw/setup0.h | sed -f .my.sedexpr > $WXDIR/include/wx/msw/setup.h
rm .my.sedexpr