]> git.saurik.com Git - wxWidgets.git/blob - distrib/msw/makeall.bat
More details about the internal module name changes
[wxWidgets.git] / distrib / msw / makeall.bat
1 Rem @echo off
2 Rem This script compiles wxWindows and some samples/demos with
3 Rem a range of compilers.
4 Rem Note that it currently uses batch scripts local to Julian Smart's machine,
5 Rem to set up the environment correctly.
6 Rem This is a 4DOS batch file, though 4DOS dependencies have been kept to
7 Rem a minimum.
8 Rem Julian Smart, August 12th, 2000
9 Rem TODO: making a Unicode distribution by modifying setup.h programmatically.
10 Rem TODO: check differing setup.h options, again by programmatic modification
11
12 set WXDIR=%WXWIN%
13 set FATWXWIN=%WXDIR%
14 set FULLWXWIN=%WXDIR%
15 if not %@INDEX["%WXDIR%","wxWindows"] == "-1" set FATWXWIN=%@PATH[%WXDIR%]wxwind~1
16 if not %@INDEX["%WXDIR%","wxWindows"] == "-1" set FULLWXWIN=%@PATH[%WXDIR%]wxWindows
17
18 Rem The following line is for a specific environment -- edit, or comment out
19 Rem Not working in 4NT?
20 Rem if not %@INDEX["%WXDIR%","wx2stable"] == "-1" set FATWXWIN=c:\wx2sta~1\wxwind~1
21
22 echo Full wxWindows path is %FULLWXWIN%, FAT path is %FATWXWIN%
23 set BUILDDEST=%TEMP%\wxWinBuild
24 Rem Only carry on if we haven't specified a single target
25 set CARRYON=0
26
27 rem goto end
28
29 if "%1" == "vc6" goto dovc6
30 if "%1" == "bc55" goto dobc55
31 if "%1" == "bc50" goto dobc50
32 if "%1" == "ming2952" goto doming2952
33 if "%1" == "cygwin11" goto docygwin11
34 if "%1" == "vc1" goto dovc1
35 if "%1" == "bc16" goto dobc16
36
37 set CARRYON=1
38
39 if not direxist %BUILDDEST% mkdir /S %BUILDDEST%
40
41
42 :dovc6
43
44 cd %WXDIR%\samples
45 erase /S *.exe
46 cd %WXDIR%\demos
47 erase /S *.exe
48 cd %WXDIR%\contrib\samples
49 erase /S *.exe
50 cd %WXDIR%\utils\tex2rtf\src
51 erase /S *.exe
52
53 echo Starting wxWindows build at %_TIME, %_DATE
54
55 Rem First, VC++ 6.
56
57 echo === VC++ 6 ===
58 echo ==============
59
60 Rem Set up the environment
61 call msvc6
62
63 echo *** VC++ Debug ***
64 Rem VC++ Debug
65 cd %WXDIR%\src\msw
66 nmake -f makefile.vc cleanall
67 nmake -f makefile.vc
68 if not direxist %BUILDDEST%\VC6Debug mkdir /S %BUILDDEST%\VC6Debug
69 erase /F /Y %BUILDDEST%\VC6Debug
70 cd %WXDIR%\samples
71 nmake -f makefile.vc clean
72
73 Rem Make one sample, just to make sure Debug mode is OK
74 cd %WXDIR%\samples\controls
75 nmake -f makefile.vc
76 copy controls.exe %BUILDDEST%\VC6Debug
77 nmake -f makefile.vc clean
78
79 cd %WXDIR%\src\msw
80 nmake -f makefile.vc cleanall
81
82 echo *** VC++ Release ***
83
84 nmake -f makefile.vc cleanall FINAL=1
85 nmake -f makefile.vc FINAL=1
86
87 if not direxist %BUILDDEST%\VC6Release mkdir /S %BUILDDEST%\VC6Release
88 erase /F /Y %BUILDDEST%\VC6Release
89
90 cd %WXDIR%\samples
91 nmake -f makefile.vc clean FINAL=1
92 nmake -f makefile.vc FINAL=1
93 Rem Copy all executables to VC6Release
94 Rem Euch, this is the only way I can think of right now
95 Rem to copy them to the same directory. Daft but...
96 erase %TEMP%\temp.zip
97 zip16 -r %TEMP%\temp.zip *.exe
98 unzip32 -o %TEMP%\temp.zip -d %BUILDDEST%\VC6Release
99 nmake -f makefile.vc clean FINAL=1
100
101 cd %WXDIR%\demos
102 nmake -f makefile.vc clean FINAL=1
103 nmake -f makefile.vc FINAL=1
104 Rem Copy all executables to VC6Release
105 erase %TEMP%\temp.zip
106 zip16 -r %TEMP%\temp.zip *.exe
107 unzip32 -o %TEMP%\temp.zip -d %BUILDDEST%\VC6Release
108 nmake -f makefile.vc clean FINAL=1
109
110 Rem Compile OGL
111 cd %WXDIR%\contrib\src\ogl
112 nmake -f makefile.vc clean FINAL=1
113 nmake -f makefile.vc FINAL=1
114 cd %WXDIR%\contrib\samples\ogl\ogledit
115 nmake -f makefile.vc clean FINAL=1
116 nmake -f makefile.vc FINAL=1
117 copy *.exe %BUILDDEST%\VC6Release
118 nmake -f makefile.vc clean FINAL=1
119 cd %WXDIR%\contrib\samples\ogl\studio
120 nmake -f makefile.vc clean FINAL=1
121 nmake -f makefile.vc FINAL=1
122 copy *.exe %BUILDDEST%\VC6Release
123 nmake -f makefile.vc clean FINAL=1
124 cd %WXDIR%\contrib\src\ogl
125 nmake -f makefile.vc clean FINAL=1
126
127 Rem Compile Tex2RTF
128 cd %WXDIR%\utils\tex2rtf\src
129 nmake -f makefile.vc clean FINAL=1
130 nmake -f makefile.vc FINAL=1
131 copy *.exe %BUILDDEST%\VC6Release
132 nmake -f makefile.vc clean FINAL=1
133
134 Rem Clean up
135
136 cd %WXDIR%\src\msw
137 nmake -f makefile.vc cleanall FINAL=1
138
139 echo *** VC++ Debug DLL ***
140
141 nmake -f makefile.vc cleanall WXMAKINGDLL=1
142 nmake -f makefile.vc dll pch
143
144 if not direxist %BUILDDEST%\VC6DebugDLL mkdir /S %BUILDDEST%\VC6DebugDLL
145 erase /F /Y %BUILDDEST%\VC6DebugDLL
146
147 copy %WXDIR%\lib\*d.dll %BUILDDEST%\VC6DebugDLL
148
149 Rem Make one sample, for a sanity check
150
151 cd %WXDIR%\samples\controls
152 nmake -f makefile.vc WXUSINGDLL=1
153 copy controls.exe %BUILDDEST%\VC6DebugDLL
154 nmake -f makefile.vc clean
155
156 cd %WXDIR%\src\msw
157 nmake -f makefile.vc cleanall WXMAKINGDLL=1
158
159 echo *** VC++ Release DLL ***
160
161 nmake -f makefile.vc cleanall FINAL=1 WXMAKINGDLL=1
162 nmake -f makefile.vc dll pch FINAL=1
163
164 if not direxist %BUILDDEST%\VC6ReleaseDLL mkdir /S %BUILDDEST%\VC6ReleaseDLL
165 erase /F /Y %BUILDDEST%\VC6ReleaseDLL
166
167 copy %WXDIR%\lib\*.dll %BUILDDEST%\VC6ReleaseDLL
168
169 Rem Make one sample, for a sanity check
170
171 cd %WXDIR%\samples\controls
172 nmake -f makefile.vc WXUSINGDLL=1 FINAL=1
173 copy controls.exe %BUILDDEST%\VC6ReleaseDLL
174 nmake -f makefile.vc clean FINAL=1
175
176 cd %WXDIR%\src\msw
177 nmake -f makefile.vc cleanall WXMAKINGDLL=1 FINAL=1
178
179 if "%CARRYON" == "0" goto end
180
181 :dobc55
182
183 echo === BC++ 5.5 ===
184 echo ================
185
186 call bcb55
187
188 echo *** WIN32 BC++ Debug ***
189
190 Rem WIN32 BC++ Debug
191 cd %WXDIR%\src\msw
192 make -f makefile.b32 cleanall
193 make -f makefile.b32
194 if not direxist %BUILDDEST%\BC55Debug mkdir /S %BUILDDEST%\BC55Debug
195 erase /F /Y %BUILDDEST%\BC55Debug
196 cd %WXDIR%\samples
197 make -f makefile.b32 clean
198
199 Rem Make one sample, just to make sure Debug mode is OK
200 cd %WXDIR%\samples\controls
201 make -f makefile.b32
202 copy controls.exe %BUILDDEST%\BC55Debug
203 make -f makefile.b32 clean
204
205 Rem Compile OGL
206 cd %WXDIR%\contrib\src\ogl
207 make -f makefile.b32 clean
208 make -f makefile.b32
209 cd %WXDIR%\contrib\samples\ogl\ogledit
210 make -f makefile.b32 clean
211 make -f makefile.b32
212 copy *.exe %BUILDDEST%\BC55Debug
213 make -f makefile.b32 clean
214 cd %WXDIR%\contrib\samples\ogl\studio
215 make -f makefile.b32 clean
216 make -f makefile.b32
217 copy *.exe %BUILDDEST%\BC55Debug
218 make -f makefile.b32 clean
219 cd %WXDIR%\contrib\src\ogl
220 make -f makefile.b32 clean
221
222 cd %WXDIR%\src\msw
223 make -f makefile.b32 cleanall
224
225 goto bcdebugdll
226
227 echo *** WIN32 BC++ Release ***
228
229 make -f makefile.b32 cleanall FINAL=1
230 make -f makefile.b32 FINAL=1
231
232 if not direxist %BUILDDEST%\BC55Release mkdir /S %BUILDDEST%\BC55Release
233 erase /F /Y %BUILDDEST%\BC55Release
234
235 cd %WXDIR%\samples
236 make -f makefile.b32 clean FINAL=1
237 make -f makefile.b32 FINAL=1
238 Rem Copy all executables to BC55Release
239 erase %TEMP%\temp.zip
240 zip16 -r %TEMP%\temp.zip *.exe
241 unzip32 -o %TEMP%\temp.zip -d %BUILDDEST%\BC55Release
242 make -f makefile.b32 clean FINAL=1
243
244 cd %WXDIR%\demos
245 make -f makefile.b32 clean FINAL=1
246 make -f makefile.b32 FINAL=1
247 Rem Copy all executables to BC55Release
248 erase %TEMP%\temp.zip
249 zip16 -r %TEMP%\temp.zip *.exe
250 unzip32 -o %TEMP%\temp.zip -d %BUILDDEST%\BC55Release
251 make -f makefile.b32 clean FINAL=1
252
253 Rem Compile OGL
254 cd %WXDIR%\contrib\src\ogl
255 make -f makefile.b32 clean FINAL=1
256 make -f makefile.b32 FINAL=1
257 cd %WXDIR%\contrib\samples\ogl\ogledit
258 make -f makefile.b32 clean FINAL=1
259 make -f makefile.b32 FINAL=1
260 copy *.exe %BUILDDEST%\BC55Release
261 make -f makefile.b32 clean FINAL=1
262 cd %WXDIR%\contrib\samples\ogl\studio
263 make -f makefile.b32 clean FINAL=1
264 make -f makefile.b32 FINAL=1
265 copy *.exe %BUILDDEST%\BC55Release
266 make -f makefile.b32 clean FINAL=1
267 cd %WXDIR%\contrib\src\ogl
268 make -f makefile.b32 clean FINAL=1
269
270 Rem Compile Tex2RTF
271 cd %WXDIR%\utils\tex2rtf\src
272 make -f makefile.b32 clean FINAL=1
273 make -f makefile.b32 FINAL=1
274 copy *.exe %BUILDDEST%\BC55Release
275 make -f makefile.b32 clean FINAL=1
276
277 Rem Clean up
278
279 cd %WXDIR%\src\msw
280 make -f makefile.b32 cleanall FINAL=1
281
282 :bcdebugdll
283
284 echo *** WIN32 BC++ Debug DLL ***
285
286 make -f makefile.b32 cleanall
287 make -f makefile.b32 dll
288
289 if not direxist %BUILDDEST%\BC55DebugDLL mkdir /S %BUILDDEST%\BC55DebugDLL
290 erase /F /Y %BUILDDEST%\BC55DebugDLL
291
292 copy %WXDIR%\lib\*.dll %BUILDDEST%\BC55DebugDLL
293
294 Rem Make one sample, for a sanity check
295
296 cd %WXDIR%\samples\controls
297 make -f makefile.b32 WXUSINGDLL=1
298 copy controls.exe %BUILDDEST%\BC55DebugDLL
299 make -f makefile.b32 clean
300
301 cd %WXDIR%\src\msw
302 make -f makefile.b32 cleanall
303
304 if "%CARRYON" == "0" goto end
305
306 Rem Skip BC++ 5.0, obsolete
307 goto docygwin11
308 :dobc50
309
310
311 echo === BC++ 5.0 ===
312 echo ================
313
314 call borland
315
316 echo *** WIN32 BC++ Debug ***
317
318 Rem WIN32 BC++ Debug
319 cd %WXDIR%\src\msw
320 make -f makefile.b32 cleanall
321 make -f makefile.b32
322 if not direxist %BUILDDEST%\BC50Debug mkdir /S %BUILDDEST%\BC50Debug
323 erase /F /Y %BUILDDEST%\BC50Debug
324 cd %WXDIR%\samples
325 make -f makefile.b32 clean
326
327 Rem Make one sample, just to make sure Debug mode is OK
328 cd %WXDIR%\samples\controls
329 make -f makefile.b32
330 copy controls.exe %BUILDDEST%\BC50Debug
331 make -f makefile.b32 clean
332
333 cd %WXDIR%\src\msw
334 make -f makefile.b32 cleanall
335
336 if "%CARRYON" == "0" goto end
337
338 :docygwin11
339
340
341 echo === Cygwin 1.1 ===
342 echo ==================
343
344 call cygwin11
345
346 echo *** Cygwin Debug ***
347
348 Rem Cygwin Release
349 cd %WXDIR%\src\msw
350 make -f makefile.g95 cleanall
351 make -f makefile.g95 FINAL=1
352 if not direxist %BUILDDEST%\Cygwin11Release mkdir /S %BUILDDEST%\Cygwin11Release
353 erase /F /Y %BUILDDEST%\Cygwin11Release
354 cd %WXDIR%\samples
355 make -f makefile.g95 clean FINAL=1
356
357 if not direxist %BUILDDEST%\Cygwin11Release mkdir /S %BUILDDEST%\Cygwin11Release
358 erase /F /Y %BUILDDEST%\Cygwin11Release
359
360 cd %WXDIR%\samples
361 make -f makefile.g95 clean FINAL=1
362 make -f makefile.g95 FINAL=1
363 Rem Copy all executables to Cygwin11Release
364 erase %TEMP%\temp.zip
365 zip16 -r %TEMP%\temp.zip *.exe
366 unzip32 -o %TEMP%\temp.zip -d %BUILDDEST%\Cygwin11Release
367 make -f makefile.g95 clean FINAL=1
368
369 cd %WXDIR%\demos
370 make -f makefile.g95 clean FINAL=1
371 make -f makefile.g95 FINAL=1
372 Rem Copy all executables to Cygwin11Release
373 erase %TEMP%\temp.zip
374 zip16 -r %TEMP%\temp.zip *.exe
375 unzip32 -o %TEMP%\temp.zip -d %BUILDDEST%\Cygwin11Release
376 make -f makefile.g95 clean FINAL=1
377
378 Rem Compile OGL
379 cd %WXDIR%\contrib\src\ogl
380 make -f makefile.g95 clean FINAL=1
381 make -f makefile.g95 FINAL=1
382 cd %WXDIR%\contrib\samples\ogl\ogledit
383 make -f makefile.g95 clean FINAL=1
384 make -f makefile.g95 FINAL=1
385 copy *.exe %BUILDDEST%\Cygwin11Release
386 make -f makefile.g95 clean FINAL=1
387 cd %WXDIR%\contrib\samples\ogl\studio
388 make -f makefile.g95 clean FINAL=1
389 make -f makefile.g95 FINAL=1
390 copy *.exe %BUILDDEST%\Cygwin11Release
391 make -f makefile.g95 clean FINAL=1
392 cd %WXDIR%\contrib\src\ogl
393 make -f makefile.g95 clean FINAL=1
394
395 Rem Compile Tex2RTF
396 cd %WXDIR%\utils\tex2rtf\src
397 make -f makefile.g95 clean FINAL=1
398 make -f makefile.g95 FINAL=1
399 copy *.exe %BUILDDEST%\Cygwin11Release
400 make -f makefile.g95 clean FINAL=1
401
402 echo Stripping executables...
403 strip %BUILDDEST%\Cygwin11Release\*.exe
404
405 Rem Cleanup
406
407 cd %WXDIR%\src\msw
408 make -f makefile.g95 cleanall
409
410 if "%CARRYON" == "0" goto end
411
412 :doming2952
413
414 echo === Mingw32 2.95.2 ===
415 echo ======================
416
417 call ming2952
418
419 echo *** Cygwin Debug ***
420
421 Rem Cygwin Release
422 cd %WXDIR%\src\msw
423 make -f makefile.g95 cleanall
424 make -f makefile.g95 FINAL=1
425 if not direxist %BUILDDEST%\Ming2952Release mkdir /S %BUILDDEST%\Ming2952Release
426 erase /F /Y %BUILDDEST%\Ming2952Release
427 cd %WXDIR%\samples
428 make -f makefile.g95 clean FINAL=1
429
430 if not direxist %BUILDDEST%\Ming2952Release mkdir /S %BUILDDEST%\Ming2952Release
431 erase /F /Y %BUILDDEST%\Ming2952Release
432
433 cd %WXDIR%\samples
434 make -f makefile.g95 clean FINAL=1
435 make -f makefile.g95 FINAL=1
436 Rem Copy all executables to Ming2952Release
437 erase %TEMP%\temp.zip
438 zip16 -r %TEMP%\temp.zip *.exe
439 unzip32 -o %TEMP%\temp.zip -d %BUILDDEST%\Ming2952Release
440 make -f makefile.g95 clean FINAL=1
441
442 cd %WXDIR%\demos
443 make -f makefile.g95 clean FINAL=1
444 make -f makefile.g95 FINAL=1
445 Rem Copy all executables to Ming2952Release
446 erase %TEMP%\temp.zip
447 zip16 -r %TEMP%\temp.zip *.exe
448 unzip32 -o %TEMP%\temp.zip -d %BUILDDEST%\Ming2952Release
449 make -f makefile.g95 clean FINAL=1
450
451 Rem Compile OGL
452 cd %WXDIR%\contrib\src\ogl
453 make -f makefile.g95 clean FINAL=1
454 make -f makefile.g95 FINAL=1
455 cd %WXDIR%\contrib\samples\ogl\ogledit
456 make -f makefile.g95 clean FINAL=1
457 make -f makefile.g95 FINAL=1
458 copy *.exe %BUILDDEST%\Ming2952Release
459 make -f makefile.g95 clean FINAL=1
460 cd %WXDIR%\contrib\samples\ogl\studio
461 make -f makefile.g95 clean FINAL=1
462 make -f makefile.g95 FINAL=1
463 copy *.exe %BUILDDEST%\Ming2952Release
464 make -f makefile.g95 clean FINAL=1
465 cd %WXDIR%\contrib\src\ogl
466 make -f makefile.g95 clean FINAL=1
467
468 Rem Compile Tex2RTF
469 cd %WXDIR%\utils\tex2rtf\src
470 make -f makefile.g95 clean FINAL=1
471 make -f makefile.g95 FINAL=1
472 copy *.exe %BUILDDEST%\Ming2952Release
473 make -f makefile.g95 clean FINAL=1
474
475 echo Stripping executables...
476 strip %BUILDDEST%\Ming2952Release\*.exe
477
478 Rem Cleanup
479
480 cd %WXDIR%\src\msw
481 make -f makefile.g95 cleanall
482
483 if "%CARRYON" == "0" goto end
484
485 :dovc1
486
487 echo === 16-bit VC++ ===
488 echo ===================
489
490 Rem Set up the environment
491 call msvc1
492
493 Rem Needs full wxWindows path for making libraries
494 set WXWIN=%FULLWXWIN%
495
496 echo *** VC++ Debug ***
497 Rem VC++ Debug
498 cd %WXDIR%\src\msw
499 nmake -f makefile.dos cleanall
500 nmake -f makefile.dos
501 if not direxist %BUILDDEST%\VC1Debug mkdir /S %BUILDDEST%\VC1Debug
502 erase /F /Y %BUILDDEST%\VC1Debug
503
504 Rem Make one sample, just to make sure Debug mode is OK
505 cd %WXDIR%\samples\minimal
506 nmake -f makefile.dos clean
507 Rem Needs FAT wxWindows path for making executables
508 set WXWIN=%FATWXWIN%
509 nmake -f makefile.dos
510
511 copy minimal.exe /S %BUILDDEST%\VC1Debug
512 nmake -f makefile.dos clean
513
514 cd %WXDIR%\src\msw
515 nmake -f makefile.dos cleanall
516
517 Rem Needs full wxWindows path for making libraries
518 set WXWIN=%FULLWXWIN%
519
520 echo *** VC++ Release ***
521
522 nmake -f makefile.dos cleanall FINAL=1
523 nmake -f makefile.dos FINAL=1
524
525 if not direxist %BUILDDEST%\VC1Release mkdir /S %BUILDDEST%\VC1Release
526 erase /F /Y %BUILDDEST%\VC1Release
527
528 Rem Make one sample, just to make sure Release mode is OK
529 cd %WXDIR%\samples\minimal
530 nmake -f makefile.dos clean
531 nmake -f makefile.dos FINAL=1
532 Rem Needs FAT wxWindows path for making executables
533 set WXWIN=%FATWXWIN%
534 nmake -f makefile.dos FINAL=1
535 copy minimal.exe /S %BUILDDEST%\VC1Release
536 nmake -f makefile.dos clean
537 set WXWIN=%tmpwxwin%
538
539 Rem Clean up
540
541 cd %WXDIR%\src\msw
542 nmake -f makefile.dos cleanall FINAL=1
543
544 if "%CARRYON" == "0" goto end
545
546 :dobc16
547
548 echo === 16-bit BC++ ===
549 echo ===================
550
551 Rem Set up the environment
552 call borland
553
554 echo *** 16-bit BC++ Debug ***
555 Rem 16-bit BC++ Debug
556 cd %WXDIR%\src\msw
557 make -f makefile.bcc cleanall
558 make -f makefile.bcc
559 if not direxist %BUILDDEST%\BC16Debug mkdir /S %BUILDDEST%\BC16Debug
560 erase /F /Y %BUILDDEST%\BC16Debug
561
562 Rem Make one sample, just to make sure Debug mode is OK
563 cd %WXDIR%\samples\minimal
564 make -f makefile.bcc clean
565 make -f makefile.bcc
566 copy minimal.exe /S %BUILDDEST%\BC16Debug
567 make -f makefile.bcc clean
568
569 cd %WXDIR%\src\msw
570 make -f makefile.bcc cleanall
571
572 echo *** 16-bit BC++ Release ***
573
574 make -f makefile.bcc cleanall FINAL=1
575 make -f makefile.bcc FINAL=1
576
577 if not direxist %BUILDDEST%\BC16Release mkdir /S %BUILDDEST%\BC16Release
578 erase /F /Y %BUILDDEST%\BC16Release
579
580 Rem Make one sample, just to make sure Release mode is OK
581 cd %WXDIR%\samples\minimal
582 make -f makefile.bcc clean
583 make -f makefile.bcc FINAL=1
584 copy minimal.exe /S %BUILDDEST%\BC16Release
585 make -f makefile.bcc clean
586
587 Rem Clean up
588
589 cd %WXDIR%\src\msw
590 make -f makefile.bcc cleanall FINAL=1
591
592 :end
593
594 echo Finished wxWindows build at %_TIME, %_DATE
595