]> git.saurik.com Git - wxWidgets.git/blob - distrib/msw/zipdistinno.bat
e0b638342ac35c6636d91c0dadacc09bc91ff7f3
[wxWidgets.git] / distrib / msw / zipdistinno.bat
1 @echo off
2 rem Zip up an external, generic + Windows distribution of wxWindows 2
3 rem using Inno Setup + ScriptMaker
4 set src=%wxwin
5 set dest=%src\deliver
6 set webfiles=c:\wx2dev\wxWebSite
7 set inno=0
8
9 Rem Set this to the required version
10 set version=2.3.3
11
12 if "%src" == "" goto usage
13 if "%dest" == "" goto usage
14 if "%1" == "-help" goto usage
15 if "%1" == "--help" goto usage
16 if "%1" == "/?" goto usage
17 if "%1" == "innoonly" goto dounzip
18 if "%1" == "inno" set inno=1
19 if "%1" == "tidyup" goto tidyup
20 echo About to archive an external wxWindows distribution:
21 echo From %src
22 echo To %dest
23 if "%inno" == "1" echo with Inno Setup creation.
24 echo CTRL-C if this is not correct.
25 pause
26
27 erase %dest\wx*.zip
28 erase %dest\*.htb
29 erase %dest\ogl3*.zip
30 erase %dest\contrib*.zip
31 erase %dest\tex2rtf2*.zip
32 erase %dest\mmedia*.zip
33 erase %dest\jpeg*.zip
34 erase %dest\tiff*.zip
35 erase %dest\dialoged*.zip
36 erase %dest\utils*.zip
37 erase %dest\extradoc*.zip
38 erase %dest\stc*.zip
39 erase %dest\*-win32*.zip
40 erase %dest\setup*.*
41 erase %dest\*.txt
42 erase %dest\make*
43
44 if direxist %dest\wx erase /sxyz %dest\wx\
45 if not direxist %dest mkdir %dest
46 if direxist %dest%\wxWindows-%version% erase /sxyz %dest%\wxWindows-%version%
47
48 # Copy FAQ from wxWebSite CVS
49 if not direxist %webfiles% echo Error - %webfiles% does not exist
50 if not direxist %webfiles% goto end
51 echo Copying FAQ and other files from %webfiles
52 copy %webfiles%\site\faq*.htm %src\docs\html
53 copy %webfiles%\site\platform.htm %src\docs\html
54 copy %webfiles%\site\i18n.htm %src\docs\html
55
56 Rem Copy setup0.h files to setup.h
57 copy %src%\include\wx\os2\setup0.h %src%\include\wx\os2\setup.h
58 copy %src%\include\wx\msw\setup0.h %src%\include\wx\msw\setup.h
59
60 cd %src
61 echo Zipping...
62
63 Rem Zip up the complete wxOS2-xxx.zip file
64 zip32 -@ %dest\wxOS2-%version%.zip < %src\distrib\msw\generic.rsp
65 zip32 -@ -u %dest%\wxOS2-%version%.zip < %src\distrib\msw\os2.rsp
66 zip32 -@ -u %dest%\wxOS2-%version%.zip < %src\distrib\msw\wx_chm.rsp
67 zip32 -@ -u %dest%\wxOS2-%version%.zip < %src\distrib\msw\jpeg.rsp
68 zip32 -@ -u %dest%\wxOS2-%version%.zip < %src\distrib\msw\tiff.rsp
69 zip32 -u -@ %dest%\wxOS2-%version%.zip < %src%\distrib\msw\tiff.rsp
70 zip32 -u -@ %dest%\wxOS2-%version%.zip < %src%\distrib\msw\jpeg.rsp
71 zip32 -u -@ %dest%\wxOS2-%version%.zip < %src%\distrib\msw\utils.rsp
72 zip32 -u -@ %dest%\wxOS2-%version%.zip < %src%\distrib\msw\tex2rtf.rsp
73 zip32 -u -@ %dest%\wxOS2-%version%.zip < %src%\distrib\msw\dialoged.rsp
74 zip32 -u -@ %dest%\wxOS2-%version%.zip < %src%\distrib\msw\ogl.rsp
75 zip32 -u -@ %dest%\wxOS2-%version%.zip < %src%\distrib\msw\xml.rsp
76 zip32 -u -@ %dest%\wxOS2-%version%.zip < %src%\distrib\msw\contrib.rsp
77 zip32 -u -@ %dest%\wxOS2-%version%.zip < %src%\distrib\msw\makefile.rsp
78
79 Rem Rearchive under wxWindows-%version%
80 call %WXWIN%\distrib\msw\rearchive wxOS2-%version%.zip wxWindows-%version% %dest%
81
82 zip32 -d %dest%\wxOS2-%version%.zip %dest%/src/gtk/descrip.mms %dest%/src/motif/descrip.mms
83
84 echo Zipping wxMac distribution
85
86 copy %src%\include\wx\mac\setup0.h %src%\include\wx\setup.h
87
88 zip32 -@ %dest%\wxMac-%version%.zip < %src%\distrib\msw\generic.rsp
89 zip32 -u -@ %dest%\wxMac-%version%.zip < %src%\distrib\msw\mac.rsp
90 zip32 -u -@ %dest%\wxMac-%version%.zip < %src%\distrib\msw\cw.rsp
91 zip32 -u -@ %dest%\wxMac-%version%.zip < %src%\distrib\msw\tiff.rsp
92 zip32 -u -@ %dest%\wxMac-%version%.zip < %src%\distrib\msw\jpeg.rsp
93 zip32 -u -@ %dest%\wxMac-%version%.zip < %src%\distrib\msw\utils.rsp
94 zip32 -u -@ %dest%\wxMac-%version%.zip < %src%\distrib\msw\tex2rtf.rsp
95 zip32 -u -@ %dest%\wxMac-%version%.zip < %src%\distrib\msw\dialoged.rsp
96 zip32 -u -@ %dest%\wxMac-%version%.zip < %src%\distrib\msw\ogl.rsp
97 zip32 -u -@ %dest%\wxMac-%version%.zip < %src%\distrib\msw\xml.rsp
98 zip32 -u -@ %dest%\wxMac-%version%.zip < %src%\distrib\msw\stc.rsp
99 zip32 -u -@ %dest%\wxMac-%version%.zip < %src%\distrib\msw\contrib.rsp
100 zip32 -u -@ %dest%\wxMac-%version%.zip < %src%\distrib\msw\makefile.rsp
101
102 erase /Y %src%\include\wx\setup.h
103
104 call %WXWIN%\distrib\msw\rearchive wxMac-%version%.zip wxWindows-%version% %dest%
105
106 zip32 -d %dest%\wxMac-%version%.zip %dest%/src/gtk/descrip.mms %dest%/src/motif/descrip.mms
107
108 Rem Create wxWindows-%version%-win.zip which is used to create wxMSW
109 echo Zipping individual components
110 zip32 -@ %dest\wxWindows-%version%-win.zip < %src\distrib\msw\generic.rsp
111 zip32 -@ -u %dest\wxWindows-%version%-win.zip < %src\distrib\msw\makefile.rsp
112 zip32 -@ -u %dest\wxWindows-%version%-win.zip < %src\distrib\msw\msw.rsp
113 zip32 -@ -u %dest\wxWindows-%version%-win.zip < %src\distrib\msw\ogl.rsp
114 zip32 -@ -u %dest\wxWindows-%version%-win.zip < %src\distrib\msw\mmedia.rsp
115 zip32 -@ -u %dest\wxWindows-%version%-win.zip < %src\distrib\msw\stc.rsp
116 zip32 -@ -u %dest\wxWindows-%version%-win.zip < %src\distrib\msw\tex2rtf.rsp
117 zip32 -@ -u %dest\wxWindows-%version%-win.zip < %src\distrib\msw\jpeg.rsp
118 zip32 -@ -u %dest\wxWindows-%version%-win.zip < %src\distrib\msw\tiff.rsp
119 zip32 -@ -u %dest\wxWindows-%version%-win.zip < %src\distrib\msw\xml.rsp
120 zip32 -@ -u %dest\wxWindows-%version%-win.zip < %src\distrib\msw\contrib.rsp
121 zip32 -@ -u %dest\wxWindows-%version%-win.zip < %src\distrib\msw\dialoged.rsp
122 zip32 -@ -u %dest\wxWindows-%version%-win.zip < %src\distrib\msw\utils.rsp
123 zip32 -@ -u %dest\wxWindows-%version%-win.zip < %src\distrib\msw\utilmake.rsp
124 zip32 -@ -u %dest\wxWindows-%version%-win.zip < %src\distrib\msw\univ.rsp
125
126 call %WXWIN%\distrib\msw\rearchive wxWindows-%version%-win.zip wxWindows-%version% %dest%
127
128 zip32 -d %dest%\wxWindows-%version%-win.zip %dest%/src/gtk/descrip.mms %dest%/src/motif/descrip.mms
129
130 zip32 -@ %dest\wxWindows-%version%-DocSource.zip < %src\distrib\msw\docsrc.rsp
131 call %WXWIN%\distrib\msw\rearchive wxWindows-%version%-DocSource.zip wxWindows-%version% %dest%
132
133 zip32 -@ %dest\wxWindows-%version%-WinHelp.zip < %src\distrib\msw\wx_hlp.rsp
134 call %WXWIN%\distrib\msw\rearchive wxWindows-%version%-WinHelp.zip wxWindows-%version% %dest%
135
136 zip32 -@ %dest\wxWindows-%version%-HTML.zip < %src\distrib\msw\wx_html.rsp
137 call %WXWIN%\distrib\msw\rearchive wxWindows-%version%-HTML.zip wxWindows-%version% %dest%
138
139 zip32 -@ %dest\wxWindows-%version%-PDF.zip < %src\distrib\msw\wx_pdf.rsp
140 call %WXWIN%\distrib\msw\rearchive wxWindows-%version%-PDF.zip wxWindows-%version% %dest%
141
142 Rem zip32 -@ %dest\wxWindows-%version%-Word.zip < %src\distrib\msw\wx_word.rsp
143 Rem call %WXWIN%\distrib\msw\rearchive wxWindows-%version%-Word.zip wxWindows-%version% %dest%
144
145 zip32 -@ %dest\wxWindows-%version%-HTB.zip < %src\distrib\msw\wx_htb.rsp
146 call %WXWIN%\distrib\msw\rearchive wxWindows-%version%-HTB.zip wxWindows-%version% %dest%
147
148 zip32 -@ %dest\wxWindows-%version%-HTMLHelp.zip < %src\distrib\msw\wx_chm.rsp
149 call %WXWIN%\distrib\msw\rearchive wxWindows-%version%-HTMLHelp.zip wxWindows-%version% %dest%
150
151 Rem PDF/HTML docs that should go into the Windows setup because
152 Rem there are no WinHelp equivalents
153 zip32 -@ %dest\wxWindows-%version%-ExtraDoc.zip < %src\distrib\msw\extradoc.rsp
154 call %WXWIN%\distrib\msw\rearchive wxWindows-%version%-ExtraDoc.zip wxWindows-%version% %dest%
155
156 Rem zip up Univ-specific files
157 zip32 -@ %dest\wxWindows-%version%-Univ.zip < %src\distrib\msw\univ.rsp
158 call %WXWIN%\distrib\msw\rearchive wxWindows-%version%-Univ.zip wxWindows-%version% %dest%
159
160 rem VC++ project files
161 zip32 -@ %dest\wxWindows-%version%-VC.zip < %src\distrib\msw\vc.rsp
162 call %WXWIN%\distrib\msw\rearchive wxWindows-%version%-VC.zip wxWindows-%version% %dest%
163
164 rem BC++ project files
165 zip32 -@ %dest\wxWindows-%version%-BC.zip < %src\distrib\msw\bc.rsp
166 call %WXWIN%\distrib\msw\rearchive wxWindows-%version%-BC.zip wxWindows-%version% %dest%
167
168 rem CodeWarrior project files
169 zip32 -@ %dest\wxWindows-%version%-CW.zip < %src\distrib\msw\cw.rsp
170 call %WXWIN%\distrib\msw\rearchive wxWindows-%version%-CW.zip wxWindows-%version% %dest%
171
172 rem Dialog Editor source and binary
173 Rem erase %dest\dialoged-source.zip
174 Rem zip32 -@ %dest\dialoged-source.zip < %src\distrib\msw\dialoged.rsp
175 Rem zip32 -j %dest\dialoged-%version%.zip %dest\dialoged-source.zip %src\bin\dialoged.exe %src\docs\winhelp\dialoged.hlp %src\docs\winhelp\dialoged.cnt
176 Rem erase %dest\dialoged-source.zip
177
178 copy %src\docs\changes.txt %dest\changes-%version%.txt
179 copy %src\docs\msw\install.txt %dest\install-msw-%version%.txt
180 copy %src\docs\mac\install.txt %dest\install-mac-%version%.txt
181 copy %src\docs\motif\install.txt %dest\install-motif-%version%.txt
182 copy %src\docs\gtk\install.txt %dest\install-gtk-%version%.txt
183 copy %src\docs\x11\install.txt %dest\install-x11-%version%.txt
184 copy %src\docs\readme.txt %dest\readme-%version%.txt
185 copy %src\docs\motif\readme.txt %dest\readme-motif-%version%.txt
186 copy %src\docs\gtk\readme.txt %dest\readme-gtk-%version%.txt
187 copy %src\docs\x11\readme.txt %dest\readme-x11-%version%.txt
188 copy %src\docs\x11\readme-nanox.txt %dest\readme-nanox-%version%.txt
189 copy %src\docs\msw\readme.txt %dest\readme-msw-%version%.txt
190 copy %src\docs\mac\readme.txt %dest\readme-mac-%version%.txt
191 copy %src\docs\os2\install.txt %dest\install-os2-%version%.txt
192 copy %src\docs\readme_vms.txt %dest\readme-vms-%version%.txt
193 copy %src\docs\motif\makewxmotif %dest\makewxmotif-%version%
194 copy %src\docs\gtk\makewxgtk %dest\makewxgtk-%version%
195
196 Rem Skip Inno Setup if inno is 0.
197 if "%inno" == "0" goto end
198
199 :dounzip
200
201 Rem Make dialoged-win32.zip and tex2rtf-win32.zip
202
203 Rem cd %src\bin
204 Rem zip32 %dest\dialoged-win32-%version%.zip dialoged.*
205 Rem zip32 %dest\tex2rtf-win32-%version%.zip tex2rtf.*
206
207 cd %dest
208
209 rem Unzip the Windows files into 'wxWindows-%version%'
210
211 unzip32 -o wxWindows-%version%-win.zip
212 unzip32 -o wxWindows-%version%-VC.zip
213 unzip32 -o wxWindows-%version%-BC.zip
214 unzip32 -o wxWindows-%version%-HTMLHelp.zip
215 unzip32 -o wxWindows-%version%-ExtraDoc.zip
216 Rem Need Word file, for Remstar DB classes
217 Rem Not any more
218 Rem unzip32 -o wxWindows-%version%-Word.zip
219
220 Rem After this change of directory, we're in the
221 Rem temporary 'wx' directory and not acting on
222 Rem the source wxWindows directory.
223 cd %dest%\wxWindows-%version%
224
225 rem Now delete a few files that are unnecessary
226 attrib -R *
227 erase /Y BuildCVS.txt descrip.mms
228 erase /Y setup.h_vms
229 erase /Y docs\html\wxbook.htm docs\html\roadmap.htm
230 Rem erase /Y contrib\docs\winhelp\mmedia.*
231 Rem erase /Y contrib\docs\winhelp\stc.*
232 Rem erase /Y contrib\docs\htmlhelp\mmedia.*
233 Rem erase /Y contrib\docs\htmlhelp\stc.*
234 Rem erase /Y contrib\docs\pdf\*.*
235 erase /sxzy contrib\docs\latex\ogl
236 erase /Y src\mingegcs.bat
237 erase /Y distrib
238
239 rem Now copy some binary files to 'bin'
240 if not isdir bin mkdir bin
241 copy %src\bin\dialoged.exe bin
242 copy %src\bin\dialoged.hlp bin
243 copy %src\bin\dialoged.chm bin
244 copy %src\bin\tex2rtf.exe bin
245 copy %src\bin\tex2rtf.hlp bin
246 copy %src\bin\tex2rtf.cnt bin
247 copy %src\bin\dbgview.* bin
248 copy %src\bin\widgets.exe bin
249 copy %src\bin\widgets.exe.manifest bin
250 copy %src\bin\life.exe bin
251 copy %src\bin\life.exe.manifest bin
252 copy %src\demos\life\breeder.lif bin
253 copy %src\docs\htmlhelp\dialoged.chm bin
254 copy %src\docs\htmlhelp\tex2rtf.chm bin
255
256 if not direxist docs\pdf mkdir docs\pdf
257 copy %src\docs\pdf\wxTutorial.pdf docs\pdf
258
259 Rem Make wxMSW-xxx.zip
260 cd %dest%
261 zip32 -r wxMSW-%version%.zip wxWindows-%version%/*
262 cd wxWindows-%version%
263
264 echo Calling 'makeinno' to generate wxwin2.iss...
265 call %WXWIN\distrib\msw\makeinno.bat
266
267 erase /Y %dest\setup.*
268
269 rem Now invoke Inno Setup on the new wxwin2.iss
270 set innocmd="C:\Program Files\Inno Setup 2\compil32.exe" /cc %WXWIN\distrib\msw\wxwin2.iss
271 echo Invoking %innocmd...
272 start "Inno Setup" /w %innocmd%
273 Rem pause Press any key to continue with the wxWindows distribution...
274
275 :tidyup
276 cd %dest
277
278 rem Put all the setup files into a single zip archive.
279 zip32 wxMSW-%version%-setup.zip readme-%version%.txt setup*.*
280
281 erase /Y wxWindows-%version%-win.zip
282 erase /Y wxWindows-%version%-ExtraDoc.zip
283
284 echo wxWindows archived.
285
286 goto end
287
288 :usage
289 echo DOS wxWindows distribution. Zips up all MSW, OS/2, Mac and doc files,
290 echo and optionally makes a setup.exe echo if you specify 'inno'
291 echo (skipping the zipping if you use 'innoonly').
292 echo.
293 echo "Usage: zipdistinno [inno | innoonly]"
294
295 :end