1@echo off 2 3:: This is an example batchfile for building everything. Please 4:: edit this (or make your own) for your needs and wants using 5:: the instructions for calling makefile.vc found in makefile.vc 6:: 7:: RCS: @(#) $Id$ 8 9set SYMBOLS= 10 11:OPTIONS 12if "%1" == "/?" goto help 13if /i "%1" == "/help" goto help 14if %1.==symbols. goto SYMBOLS 15if %1.==debug. goto SYMBOLS 16goto OPTIONS_DONE 17 18:SYMBOLS 19 set SYMBOLS=symbols 20 shift 21 goto OPTIONS 22 23:OPTIONS_DONE 24 25:: reset errorlevel 26cd > nul 27 28:: We need to run the development environment batch script that comes 29:: with developer studio (v4,5,6,7,etc...) All have it. These paths 30:: might not be correct. You may need to edit these. 31:: 32if not defined MSDevDir ( 33 call "C:\Program Files\Microsoft Developer Studio\vc98\bin\vcvars32.bat" 34 ::call "C:\Program Files\Microsoft Developer Studio\vc\bin\vcvars32.bat" 35 ::call c:\dev\devstudio60\vc98\bin\vcvars32.bat 36 if errorlevel 1 goto no_vcvars 37) 38 39 40echo Sit back and have a cup of coffee while this grinds through ;) 41echo You asked for *everything*, remember? 42echo. 43title Building Tk, please wait... 44 45 46:: makefile.vc uses this for its default anyways, but show its use here 47:: just to be explicit and convey understanding to the user. Setting 48:: the INSTALLDIR envar prior to running this batchfile affects all builds. 49:: 50if "%INSTALLDIR%" == "" set INSTALLDIR=C:\Program Files\Tcl 51 52 53:: Where is the Tcl source directory? 54:: You can set the TCLDIR environment variable to your Tcl HEAD checkout 55if "%TCLDIR%" == "" set TCLDIR=..\..\tcl 56 57:: Build the normal stuff along with the help file. 58:: 59set OPTS=none 60if not %SYMBOLS%.==. set OPTS=symbols 61nmake -nologo -f makefile.vc release winhelp OPTS=%OPTS% %1 62if errorlevel 1 goto error 63 64:: Build the static core, dlls and shell. 65:: 66set OPTS=static 67if not %SYMBOLS%.==. set OPTS=symbols,static 68nmake -nologo -f makefile.vc release OPTS=%OPTS% %1 69if errorlevel 1 goto error 70 71:: Build the special static libraries that use the dynamic runtime. 72:: 73set OPTS=static,msvcrt 74if not %SYMBOLS%.==. set OPTS=symbols,static,msvcrt 75nmake -nologo -f makefile.vc core OPTS=%OPTS% %1 76if errorlevel 1 goto error 77 78:: Build the core and shell for thread support. 79:: 80set OPTS=threads 81if not %SYMBOLS%.==. set OPTS=symbols,threads 82nmake -nologo -f makefile.vc release OPTS=%OPTS% %1 83if errorlevel 1 goto error 84 85:: Build a static, thread support core library (no shell). 86:: 87set OPTS=static,threads 88if not %SYMBOLS%.==. set OPTS=symbols,static,threads 89nmake -nologo -f makefile.vc core OPTS=%OPTS% %1 90if errorlevel 1 goto error 91 92:: Build the special static libraries the use the dynamic runtime, 93:: but now with thread support. 94:: 95set OPTS=static,msvcrt,threads 96if not %SYMBOLS%.==. set OPTS=symbols,static,msvcrt,threads 97nmake -nologo -f makefile.vc core OPTS=%OPTS% %1 98if errorlevel 1 goto error 99 100set SYMBOLS= 101goto end 102 103:error 104echo *** BOOM! *** 105goto end 106 107:no_vcvars 108echo vcvars32.bat not found. You'll need to edit this batch script. 109goto out 110 111:help 112title buildall.vc.bat help message 113echo usage: 114echo %0 : builds Tk for all build types (do this first) 115echo %0 install : installs all the release builds (do this second) 116echo %0 symbols : builds Tk for all debugging build types. 117echo %0 symbols install : install all the debug builds 118echo. 119goto out 120 121:end 122title Building Tk, please wait... DONE! 123echo DONE! 124goto out 125 126:out 127pause 128title Command Prompt 129 130