3 # Make a distribution of an application on MSW.
5 # ../distrib/msw/makesetup.sh --wxmsw --verbose &> log
7 # If your zip accepts Cygwin-style paths, then
8 # use cygpath, else substitute echo
25 SCRIPTDIR
=$WXWIN/distrib
/msw
26 WEBFILES
=c
:/wx
2dev
/wxWebSite
27 # Set this to the required version
30 .
$SCRIPTDIR/setup.var
37 if [ -f $thefile ]; then
38 sed -e "$theexpr" < $thefile > $thefile.tmp
39 mv $thefile.tmp
$thefile
41 echo "*** $thefile not found."
47 echo $1 | sed -e "s/\//\\\\\\\/g" > /tmp
/filename.tmp
48 RETVALUE
=`cat /tmp/filename.tmp`
49 rm -f /tmp
/filename.tmp
54 echo $1 | sed -e "s/\//\\\\/g" > /tmp
/filename.tmp
55 RETVALUE
=`cat /tmp/filename.tmp`
56 rm -f /tmp
/filename.tmp
61 if [ "$VERBOSE" != "1" ]; then
72 echo Re
-archiving $archive as
$dirname
76 if [ -d $dirname ]; then
81 unzip $ZIPFLAGS ..
/$archive
84 zip $ZIPFLAGS -r $archive $dirname/*
95 echo Re
-tarring $archive as
$dirname
99 if [ -d $dirname ]; then
107 tar cfz
$archive $dirname/*
112 # Find the version from wx/version.h
116 echo "#include <stdio.h>" > /tmp
/appver.c
117 echo "#include \"$VERSIONSYMBOLFILE\"" >> /tmp
/appver.c
118 echo "int main() { printf(\"%.2f\", $VERSIONSYMBOL); }" >> /tmp
/appver.c
119 gcc
/tmp
/appver.c
-I$APPDIR -o /tmp
/appver
120 VERSION
=`/tmp/appver`
121 rm -f /tmp
/appver
/tmp
/appver.c
129 # Zip up the complete wxOS2-xxx.zip file
130 zip $ZIPFLAGS -@
$DESTDIR/wxOS2
-$VERSION.
zip < $APPDIR/distrib
/msw
/generic.rsp
131 zip $ZIPFLAGS -@
-u $DESTDIR/wxOS2
-$VERSION.
zip < $APPDIR/distrib
/msw
/os2.rsp
132 zip $ZIPFLAGS -@
-u $DESTDIR/wxOS2
-$VERSION.
zip < $APPDIR/distrib
/msw
/jpeg.rsp
133 zip $ZIPFLAGS -@
-u $DESTDIR/wxOS2
-$VERSION.
zip < $APPDIR/distrib
/msw
/tiff.rsp
134 zip $ZIPFLAGS -u -@
$DESTDIR/wxOS2
-$VERSION.
zip < $APPDIR/distrib
/msw
/tiff.rsp
135 zip $ZIPFLAGS -u -@
$DESTDIR/wxOS2
-$VERSION.
zip < $APPDIR/distrib
/msw
/jpeg.rsp
136 zip $ZIPFLAGS -u -@
$DESTDIR/wxOS2
-$VERSION.
zip < $APPDIR/distrib
/msw
/utils.rsp
137 zip $ZIPFLAGS -u -@
$DESTDIR/wxOS2
-$VERSION.
zip < $APPDIR/distrib
/msw
/tex2rtf.rsp
138 zip $ZIPFLAGS -u -@
$DESTDIR/wxOS2
-$VERSION.
zip < $APPDIR/distrib
/msw
/ogl.rsp
139 zip $ZIPFLAGS -u -@
$DESTDIR/wxOS2
-$VERSION.
zip < $APPDIR/distrib
/msw
/xml.rsp
140 zip $ZIPFLAGS -u -@
$DESTDIR/wxOS2
-$VERSION.
zip < $APPDIR/distrib
/msw
/contrib.rsp
141 zip $ZIPFLAGS -u -@
$DESTDIR/wxOS2
-$VERSION.
zip < $APPDIR/distrib
/msw
/deprecated.rsp
142 zip $ZIPFLAGS -u -@
$DESTDIR/wxOS2
-$VERSION.
zip < $APPDIR/distrib
/msw
/makefile.rsp
144 # Rearchive under wxWidgets-$VERSION
145 if [ -d $DESTDIR/wxWidgets
-$VERSION ]; then
146 rm -f -r $DESTDIR/wxWidgets
-$VERSION
149 mkdir $DESTDIR/wxWidgets
-$VERSION
150 cd $DESTDIR/wxWidgets
-$VERSION
151 unzip $ZIPFLAGS ..
/wxOS2
-$VERSION.
zip
152 # No longer do this, configure should be OK
153 # echo Overwriting with OS2-specific versions of configure files...
154 # unzip $ZIPFLAGS -o $APPDIR/distrib/os2/os2-specific.zip
155 rm -f src
/gtk
/descrip.mms src
/motif
/descrip.mms docs
/pdf
/*.pdf
156 rm -f src
/tiff
/*.mcp src
/jpeg
/*.mcp src
/png
/*.mcp src
/zlib
/*.mcp
157 rm -f -r docs
/html
/tex2rtf
159 # echo Making OS/2 files lower case...
160 # no longer necessary
161 # $SCRIPTDIR/namedown include/wx/os2/*.H
162 # $SCRIPTDIR/namedown src/os2/*.CPP src/os2/*.I
164 echo Copying readme files...
165 cp $APPDIR/docs
/os
2/install.txt INSTALL
-OS2.txt
166 cp $APPDIR/docs
/licence.txt LICENCE.txt
167 cp $APPDIR/docs
/lgpl.txt COPYING.LIB
168 cp $APPDIR/docs
/changes.txt CHANGES.txt
169 cp $APPDIR/docs
/readme.txt README.txt
173 rm -f wxOS2
-$VERSION.
zip
174 zip $ZIPFLAGS -r wxOS2
-$VERSION.
zip wxWidgets
-$VERSION/*
179 echo Spinning wxMac...
182 echo Zipping wxMac distribution
184 cp $APPDIR/include
/wx
/mac
/setup0.h
$APPDIR/include
/wx
/setup.h
186 zip $ZIPFLAGS -@
$DESTDIR/wxMac
-$VERSION.
zip < $APPDIR/distrib
/msw
/generic.rsp
187 zip $ZIPFLAGS -u -@
$DESTDIR/wxMac
-$VERSION.
zip < $APPDIR/distrib
/msw
/mac.rsp
188 zip $ZIPFLAGS -u -@
$DESTDIR/wxMac
-$VERSION.
zip < $APPDIR/distrib
/msw
/cocoa.rsp
189 zip $ZIPFLAGS -u -@
$DESTDIR/wxMac
-$VERSION.
zip < $APPDIR/distrib
/msw
/cw_mac.rsp
190 zip $ZIPFLAGS -u -@
$DESTDIR/wxMac
-$VERSION.
zip < $APPDIR/distrib
/msw
/tiff.rsp
191 zip $ZIPFLAGS -u -@
$DESTDIR/wxMac
-$VERSION.
zip < $APPDIR/distrib
/msw
/jpeg.rsp
192 zip $ZIPFLAGS -u -@
$DESTDIR/wxMac
-$VERSION.
zip < $APPDIR/distrib
/msw
/utils.rsp
193 zip $ZIPFLAGS -u -@
$DESTDIR/wxMac
-$VERSION.
zip < $APPDIR/distrib
/msw
/tex2rtf.rsp
194 zip $ZIPFLAGS -u -@
$DESTDIR/wxMac
-$VERSION.
zip < $APPDIR/distrib
/msw
/ogl.rsp
195 zip $ZIPFLAGS -u -@
$DESTDIR/wxMac
-$VERSION.
zip < $APPDIR/distrib
/msw
/xml.rsp
196 zip $ZIPFLAGS -u -@
$DESTDIR/wxMac
-$VERSION.
zip < $APPDIR/distrib
/msw
/stc.rsp
197 zip $ZIPFLAGS -u -@
$DESTDIR/wxMac
-$VERSION.
zip < $APPDIR/distrib
/msw
/contrib.rsp
198 zip $ZIPFLAGS -u -@
$DESTDIR/wxMac
-$VERSION.
zip < $APPDIR/distrib
/msw
/deprecated.rsp
199 zip $ZIPFLAGS -u -@
$DESTDIR/wxMac
-$VERSION.
zip < $APPDIR/distrib
/msw
/makefile.rsp
201 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-CW-Mac.
zip < $APPDIR/distrib
/msw
/cw_mac.rsp
203 rm -f $APPDIR/include
/wx
/setup.h
205 if [ -d $DESTDIR/wxWidgets
-$VERSION ]; then
206 rm -f -r $DESTDIR/wxWidgets
-$VERSION
209 mkdir $DESTDIR/wxWidgets
-$VERSION
210 cd $DESTDIR/wxWidgets
-$VERSION
211 unzip $ZIPFLAGS ..
/wxMac
-$VERSION.
zip
212 rm -f src
/gtk
/descrip.mms src
/motif
/descrip.mms docs
/pdf
/*.pdf
213 rm -f -r docs
/html
/tex2rtf docs
/htmlhelp
215 echo Copying readme files...
216 cp $APPDIR/docs
/mac
/readme.txt README
-MAC.txt
217 cp $APPDIR/docs
/mac
/install.txt INSTALL
-MAC.txt
218 cp $APPDIR/docs
/licence.txt LICENCE.txt
219 cp $APPDIR/docs
/lgpl.txt COPYING.LIB
220 cp $APPDIR/docs
/changes.txt CHANGES.txt
221 cp $APPDIR/docs
/readme.txt README.txt
225 rm -f wxMac
-$VERSION.
zip
226 zip $ZIPFLAGS -r wxMac
-$VERSION.
zip wxWidgets
-$VERSION/*
231 echo Zipping wxMSW...
234 # Create wxWidgets-$VERSION-win.zip which is used to create wxMSW
235 echo Zipping individual components
236 rm -f $DESTDIR/wxWidgets
-$VERSION-win.
zip
237 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-win.
zip < $APPDIR/distrib
/msw
/generic.rsp
238 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-win.
zip < $APPDIR/distrib
/msw
/makefile.rsp
239 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-win.
zip < $APPDIR/distrib
/msw
/msw.rsp
240 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-win.
zip < $APPDIR/distrib
/msw
/ogl.rsp
241 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-win.
zip < $APPDIR/distrib
/msw
/mmedia.rsp
242 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-win.
zip < $APPDIR/distrib
/msw
/stc.rsp
243 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-win.
zip < $APPDIR/distrib
/msw
/tex2rtf.rsp
244 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-win.
zip < $APPDIR/distrib
/msw
/jpeg.rsp
245 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-win.
zip < $APPDIR/distrib
/msw
/tiff.rsp
246 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-win.
zip < $APPDIR/distrib
/msw
/xml.rsp
247 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-win.
zip < $APPDIR/distrib
/msw
/contrib.rsp
248 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-win.
zip < $APPDIR/distrib
/msw
/deprecated.rsp
249 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-win.
zip < $APPDIR/distrib
/msw
/utils.rsp
250 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-win.
zip < $APPDIR/distrib
/msw
/utilmake.rsp
251 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-win.
zip < $APPDIR/distrib
/msw
/univ.rsp
252 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-win.
zip < $APPDIR/distrib
/msw
/wince.rsp
253 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-win.
zip < $APPDIR/distrib
/msw
/palmos.rsp
258 echo Zipping wxAll...
261 echo Zipping individual components
262 rm -f $DESTDIR/wxWidgets
-$VERSION-all.
zip
264 # Save adding all the wxMSW files again
265 if [ ! -f $DESTDIR/wxWidgets
-$VERSION-win.
zip ]; then
268 cp $DESTDIR/wxWidgets
-$VERSION-win.
zip $DESTDIR/wxWidgets
-$VERSION-all.
zip
270 cat $APPDIR/distrib
/msw
/cw_mac.rsp
$APPDIR/distrib
/msw
/vc.rsp
$APPDIR/distrib
/msw
/x11.rsp
$APPDIR/distrib
/msw
/gtk.rsp
$APPDIR/distrib
/msw
/cocoa.rsp
$APPDIR/distrib
/msw
/motif.rsp
$APPDIR/distrib
/msw
/mac.rsp
$APPDIR/distrib
/msw
/mgl.rsp
$APPDIR/distrib
/msw
/os2.rsp
$APPDIR/distrib
/msw
/palmos.rsp
| sort | uniq > /tmp
/all.txt
271 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-all.
zip < /tmp
/all.txt
273 if [ -d $DESTDIR/wxWidgets
-$VERSION ]; then
274 rm -f -r $DESTDIR/wxWidgets
-$VERSION
277 mkdir $DESTDIR/wxWidgets
-$VERSION
278 cd $DESTDIR/wxWidgets
-$VERSION
279 unzip $ZIPFLAGS ..
/wxWidgets
-$VERSION-all.
zip
281 echo Copying readme files...
282 cp $APPDIR/docs
/licence.txt LICENCE.txt
283 cp $APPDIR/docs
/lgpl.txt COPYING.LIB
284 cp $APPDIR/docs
/changes.txt CHANGES.txt
285 cp $APPDIR/docs
/readme.txt README.txt
289 rm -f $DESTDIR/wxWidgets
-$VERSION-all.
zip
290 zip $ZIPFLAGS -r wxWidgets
-$VERSION.
zip wxWidgets
-$VERSION/*
297 echo Zipping wxBase...
298 rm -f $DESTDIR/wxBase
-$VERSION.
zip
299 zip $ZIPFLAGS -@
$DESTDIR/wxBase
-$VERSION.
zip < $APPDIR/distrib
/msw
/base.rsp
301 if [ -d $DESTDIR/wxWidgets
-$VERSION ]; then
302 rm -f -r $DESTDIR/wxWidgets
-$VERSION
305 mkdir $DESTDIR/wxWidgets
-$VERSION
306 cd $DESTDIR/wxWidgets
-$VERSION
307 unzip $ZIPFLAGS ..
/wxBase
-$VERSION.
zip
309 echo Copying readme files...
310 cp $APPDIR/docs
/base
/readme.txt README.txt
311 cp $APPDIR/docs
/licence.txt LICENCE.txt
312 cp $APPDIR/docs
/lgpl.txt COPYING.LIB
313 cp $APPDIR/docs
/changes.txt CHANGES.txt
314 cp $APPDIR/docs
/readme.txt README2.txt
318 rm -f wxBase
-$VERSION.
zip
319 zip $ZIPFLAGS -r wxBase
-$VERSION.
zip wxWidgets
-$VERSION/*
326 echo Creating
$DESTDIR/wxWidgets
-$VERSION-DocSource.
zip
327 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-DocSource.
zip < $APPDIR/distrib
/msw
/docsrc.rsp
328 rearchive wxWidgets
-$VERSION-DocSource.
zip wxWidgets
-$VERSION $DESTDIR
330 echo Creating
$DESTDIR/wxWidgets
-$VERSION-WinHelp.
zip
331 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-WinHelp.
zip < $APPDIR/distrib
/msw
/wx_hlp.rsp
332 rearchive wxWidgets
-$VERSION-WinHelp.
zip wxWidgets
-$VERSION $DESTDIR
334 echo Creating
$DESTDIR/wxWidgets
-$VERSION-HTML.
zip
335 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-HTML.
zip < $APPDIR/distrib
/msw
/wx_html.rsp
336 rearchive wxWidgets
-$VERSION-HTML.
zip wxWidgets
-$VERSION $DESTDIR
338 echo Creating
$DESTDIR/wxWidgets
-$VERSION-PDF.
zip
339 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-PDF.
zip < $APPDIR/distrib
/msw
/wx_pdf.rsp
340 rearchive wxWidgets
-$VERSION-PDF.
zip wxWidgets
-$VERSION $DESTDIR
342 echo Creating
$DESTDIR/wxWidgets
-$VERSION-PDF.
tar.gz
343 tar zcf
/c
/wx
2dev
/wxWindows
/deliver
/wxWidgets
-$VERSION-PDF.
tar.gz docs
/pdf
/*.pdf
344 rearchivetar wxWidgets
-$VERSION-PDF.
tar.gz wxWidgets
-$VERSION /c
/wx
2dev
/wxWindows
/deliver
346 # zip $ZIPFLAGS -@ $DESTDIR/wxWidgets-$VERSION-Word.zip < $APPDIR/distrib/msw/wx_word.rsp
347 # rearchive wxWidgets-$VERSION-Word.zip wxWidgets-$VERSION $DESTDIR
349 echo Creating
$DESTDIR/wxWidgets
-$VERSION-HTB.
zip
350 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-HTB.
zip < $APPDIR/distrib
/msw
/wx_htb.rsp
351 rearchive wxWidgets
-$VERSION-HTB.
zip wxWidgets
-$VERSION $DESTDIR
353 echo Creating
$DESTDIR/wxWidgets
-$VERSION-HTMLHelp.
zip
354 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-HTMLHelp.
zip < $APPDIR/distrib
/msw
/wx_chm.rsp
355 rearchive wxWidgets
-$VERSION-HTMLHelp.
zip wxWidgets
-$VERSION $DESTDIR
357 # Add Linuxy docs to a separate archive to be transported to Linux for the
358 # Linux-based releases
359 echo Creating
$DESTDIR/wxWidgets
-$VERSION-LinuxDocs.
zip
360 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-LinuxDocs.
zip < $APPDIR/distrib
/msw
/wx_html.rsp
361 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-LinuxDocs.
zip < $APPDIR/distrib
/msw
/wx_pdf.rsp
362 zip $ZIPFLAGS -@
-u $DESTDIR/wxWidgets
-$VERSION-LinuxDocs.
zip < $APPDIR/distrib
/msw
/wx_htb.rsp
364 # PDF/HTML docs that should go into the Windows setup because
365 # there are no WinHelp equivalents
366 echo Creating
$DESTDIR/wxWidgets
-$VERSION-ExtraDoc.
zip
367 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-ExtraDoc.
zip < $APPDIR/distrib
/msw
/extradoc.rsp
368 rearchive wxWidgets
-$VERSION-ExtraDoc.
zip wxWidgets
-$VERSION $DESTDIR
375 # zip up Univ-specific files
376 echo Creating
$DESTDIR/wxWidgets
-$VERSION-Univ.
zip
377 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-Univ.
zip < $APPDIR/distrib
/msw
/univ.rsp
378 rearchive wxWidgets
-$VERSION-Univ.
zip wxWidgets
-$VERSION $DESTDIR
381 echo Creating
$DESTDIR/wxWidgets
-$VERSION-VC.
zip
382 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-VC.
zip < $APPDIR/distrib
/msw
/vc.rsp
383 # rearchive wxWidgets-$VERSION-VC.zip wxWidgets-$VERSION $DESTDIR
385 # eVC++ project files
386 echo Creating
$DESTDIR/wxWidgets
-$VERSION-eVC.
zip
387 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-eVC.
zip < $APPDIR/distrib
/msw
/wince.rsp
388 # rearchive wxWidgets-$VERSION-eVC.zip wxWidgets-$VERSION $DESTDIR
391 echo Creating
$DESTDIR/wxWidgets
-$VERSION-DMC.
zip
392 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-DMC.
zip < $APPDIR/distrib
/msw
/dmc.rsp
393 # rearchive wxWidgets-$VERSION-DMC.zip wxWidgets-$VERSION $DESTDIR
396 echo Creating
$DESTDIR/wxWidgets
-$VERSION-BC.
zip
397 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-BC.
zip < $APPDIR/distrib
/msw
/bc.rsp
398 # rearchive wxWidgets-$VERSION-BC.zip wxWidgets-$VERSION $DESTDIR
400 # CodeWarrior project files
401 echo Creating
$DESTDIR/wxWidgets
-$VERSION-CW.
zip
402 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-CW.
zip < $APPDIR/distrib
/msw
/cw.rsp
403 # rearchive wxWidgets-$VERSION-CW.zip wxWidgets-$VERSION $DESTDIR
410 # Put all archives for transit to Linux in a zip file
411 echo Creating
$DESTDIR/wxWidgets
-$VERSION-LinuxTransit.
zip
412 rm -f $DESTDIR/wxWidgets
-$VERSION-LinuxTransit.
zip
413 zip $ZIPFLAGS $DESTDIR/wxWidgets
-$VERSION-LinuxTransit.
zip wxWidgets
-$VERSION-LinuxDocs.
zip wxWidgets
-$VERSION-VC.
zip wxWidgets
-$VERSION-DMC.
zip wxWidgets
-$VERSION-eVC.
zip wxWidgets
-$VERSION-CW-Mac.
zip
415 if [ ! -f $DESTDIR/wxWidgets
-$VERSION-HTMLHelp.
zip ]; then
417 echo Creating
$DESTDIR/wxWidgets
-$VERSION-HTMLHelp.
zip
418 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-HTMLHelp.
zip < $APPDIR/distrib
/msw
/wx_chm.rsp
419 rearchive wxWidgets
-$VERSION-HTMLHelp.
zip wxWidgets
-$VERSION $DESTDIR
423 if [ ! -f $DESTDIR/wxWidgets
-$VERSION-ExtraDoc.
zip ]; then
425 echo Creating
$DESTDIR/wxWidgets
-$VERSION-ExtraDoc.
zip
426 zip $ZIPFLAGS -@
$DESTDIR/wxWidgets
-$VERSION-ExtraDoc.
zip < $APPDIR/distrib
/msw
/extradoc.rsp
427 rearchive wxWidgets
-$VERSION-ExtraDoc.
zip wxWidgets
-$VERSION $DESTDIR
431 rm -f -r wxWidgets
-$VERSION
433 echo Unzipping the Windows files into wxWidgets
-$VERSION
435 mkdir -p wxWidgets
-$VERSION
437 unzip $ZIPFLAGS -o wxWidgets
-$VERSION-win.
zip -d wxWidgets
-$VERSION
438 unzip $ZIPFLAGS -o wxWidgets
-$VERSION-VC.
zip -d wxWidgets
-$VERSION
439 unzip $ZIPFLAGS -o wxWidgets
-$VERSION-DMC.
zip -d wxWidgets
-$VERSION
440 unzip $ZIPFLAGS -o wxWidgets
-$VERSION-BC.
zip -d wxWidgets
-$VERSION
441 unzip $ZIPFLAGS -o wxWidgets
-$VERSION-CW.
zip -d wxWidgets
-$VERSION
443 unzip $ZIPFLAGS -o wxWidgets
-$VERSION-HTMLHelp.
zip
444 unzip $ZIPFLAGS -o wxWidgets
-$VERSION-ExtraDoc.
zip
446 # After this change of directory, we're in the
447 # temporary 'wx' directory and not acting on
448 # the source wxWidgets directory.
449 cd $DESTDIR/wxWidgets
-$VERSION
451 # Now delete a few files that are unnecessary
453 rm -f BuildCVS.txt descrip.mms
455 rm -f docs
/html
/wxbook.htm docs
/html
/roadmap.htm
456 rm -f -r contrib
/docs
/latex
/ogl
457 rm -f src
/mingegcs.bat
460 rm -f src
/gtk
/descrip.mms src
/motif
/descrip.mms
462 echo Copying readme files...
463 cp $APPDIR/docs
/msw
/readme.txt README
-MSW.txt
464 cp $APPDIR/docs
/msw
/install.txt INSTALL
-MSW.txt
465 cp $APPDIR/docs
/licence.txt LICENCE.txt
466 cp $APPDIR/docs
/lgpl.txt COPYING.LIB
467 cp $APPDIR/docs
/changes.txt CHANGES.txt
468 cp $APPDIR/docs
/readme.txt README.txt
470 # Now cp some binary files to 'bin'
471 if [ ! -d bin
]; then
474 cp $APPDIR/bin
/tex2rtf.exe bin
475 cp $APPDIR/bin
/tex2rtf.chm bin
476 cp $APPDIR/bin
/widgets.exe bin
477 cp $APPDIR/bin
/life.exe bin
478 cp $APPDIR/demos
/life
/breeder.lif bin
479 cp $APPDIR/docs
/htmlhelp
/tex2rtf.chm bin
481 if [ ! -d docs
/pdf
]; then
484 #cp $APPDIR/docs/pdf/wxTutorial.pdf docs/pdf
488 zip $ZIPFLAGS -r wxMSW
-$VERSION.
zip wxWidgets
-$VERSION/*
489 cd wxWidgets
-$VERSION
491 echo Generating
$SETUPSCRIPTNAME
492 rm -f $SETUPSCRIPTNAME
494 sh
$SCRIPTDIR/makeinno.sh
$SETUPIMAGEDIR $INNOTOP $INNOBOTTOM $SETUPSCRIPTNAME
496 if [ ! -f $SETUPSCRIPTNAME ]; then
497 echo "*** Error - something went wrong with the script file generation."
501 # Now replace %VERSION% with the real application version, and other
503 echo Replacing variables
in the setup
script
504 doreplace
$SETUPSCRIPTNAME "s/%VERSION%/$VERSION/g"
505 doreplace
$SETUPSCRIPTNAME "s/%COPYRIGHTHOLDER%/$AUTHOR/g"
506 doreplace
$SETUPSCRIPTNAME "s/%VENDOR%/$VENDOR/g"
508 unix2dosname
$READMEFILE
509 doreplace
$SETUPSCRIPTNAME "s;%READMEFILE%;$RETVALUE;g"
511 unix2dosname
$READMEAFTERFILE
512 doreplace
$SETUPSCRIPTNAME "s;%READMEAFTERFILE%;$RETVALUE;g"
514 unix2dosname
$LICENSEFILE
515 doreplace
$SETUPSCRIPTNAME "s;%LICENSEFILE%;$RETVALUE;g"
517 doreplace
$SETUPSCRIPTNAME "s/%APPNAME%/$APPNAME/g"
518 doreplace
$SETUPSCRIPTNAME "s/%APPTITLE%/$APPTITLE/g"
520 unix2dosname
$SETUPIMAGEDIR
521 doreplace
$SETUPSCRIPTNAME "s;%SOURCEDIR%;$RETVALUE;g"
523 unix2dosname
$DESTDIR
524 doreplace
$SETUPSCRIPTNAME "s;%OUTPUTDIR%;$RETVALUE;g"
526 doreplace
$SETUPSCRIPTNAME "s/%APPEXTENSION%/$APPEXTENSION/g"
528 # FIXME: how do we get the first name in the list?
529 if [ "$MANUALFILES" != "" ]; then
530 HELPFILE
=`basename $MANUALFILES`
531 unix2dosname
$HELPFILE
532 doreplace
$SETUPSCRIPTNAME "s;%HELPFILE%;$RETVALUE;g"
535 rm -f $DESTDIR/setup
*.
* $DESTDIR/wxMSW
-$VERSION-Setup.exe
537 # Inno Setup complains if this step is not done
538 unix2dos
--unix2dos $SETUPSCRIPTNAME
540 # Now invoke INNO compiler on the new ISS file
541 # First, make a DOS filename or Inno Setup will get confused.
543 unix2dosname2
$SETUPSCRIPTNAME
544 DOSFILENAME
=$RETVALUE
546 # Note: the double slash is Mingw32/MSYS convention for
547 # denoting a switch, that must not be converted into
548 # a path (otherwise /c = c:/)
550 cd `dirname $SETUPSCRIPTNAME`
551 BASESCRIPTNAME
=`basename $SETUPSCRIPTNAME`
552 echo Invoking Inno Setup compiler on
$BASESCRIPTNAME
554 "$SETUPCOMPILER" //cc
$BASESCRIPTNAME
556 if [ ! -f $DESTDIR/setup.exe
]; then
557 echo "*** Error - the setup.exe was not generated."
562 mv setup.exe wxMSW
-$VERSION-Setup.exe
564 # echo Putting all the setup files into a single zip archive
565 # zip wxMSW-$VERSION-setup.zip readme-$VERSION.txt setup*.*
567 rm -f wxWidgets
-$VERSION-win.
zip
568 rm -f wxWidgets
-$VERSION-ExtraDoc.
zip
569 rm -f wxWidgets
-$VERSION-DMC.
zip
570 rm -f wxWidgets
-$VERSION-eVC.
zip
571 rm -f wxWidgets
-$VERSION-Univ.
zip
572 rm -f wxWidgets
-$VERSION-VC.
zip
573 rm -f wxWidgets
-$VERSION-DocSource.
zip
574 rm -f wxWidgets
-$VERSION-LinuxDocs.
zip
576 echo If you saw no warnings or errors
, $APPTITLE was successfully spun.
582 # if [ -d $SETUPIMAGEDIR ]; then
583 # echo Removing contents of existing $SETUPIMAGEDIR
584 # rm -f -r $SETUPIMAGEDIR/*
587 if [ ! -d $SETUPIMAGEDIR ]; then
588 echo Making the
$SETUPIMAGEDIR for preparing the setup
589 mkdir -p $SETUPIMAGEDIR
593 if [ "$READMEFILE" != "" ] && [ -f $READMEFILE ]; then
594 echo Copying readme.txt
595 cp $READMEFILE $SETUPIMAGEDIR
597 # echo "*** Warning - $READMEFILE not found"
600 if [ "$LICENSEFILE" != "" ] && [ -f $LICENSEFILE ]; then
601 echo Copying licence.txt
602 cp $LICENSEFILE $SETUPIMAGEDIR
604 # echo "*** Warning - $LICENSEFILE not found"
607 if [ "$MAKEMANUAL" != "0" ]; then
608 if [ -d $MANUALDIR ]; then
612 echo "*** Warning - $MANUALDIR not found"
616 rm -f $DESTDIR/wx
*.
zip
618 rm -f $DESTDIR/ogl3
*.
zip
619 rm -f $DESTDIR/contrib
*.
zip
620 rm -f $DESTDIR/tex2rtf2
*.
zip
621 rm -f $DESTDIR/mmedia
*.
zip
622 rm -f $DESTDIR/jpeg
*.
zip
623 rm -f $DESTDIR/tiff
*.
zip
624 rm -f $DESTDIR/utils
*.
zip
625 rm -f $DESTDIR/extradoc
*.
zip
626 rm -f $DESTDIR/stc
*.
zip
627 rm -f $DESTDIR/*-win32*.
zip
628 rm -f $DESTDIR/setup
*.
*
632 if [ -d $DESTDIR/wx
]; then
636 if [ ! -d $DESTDIR ]; then
639 if [ -d $DESTDIR/wxWidgets
-$VERSION ]; then
640 rm -f -r $DESTDIR/wxWidgets
-$VERSION
643 # Copy FAQ from wxWebSite CVS
644 if [ ! -d $WEBFILES ]; then
645 echo Error
- $WEBFILES does not exist
649 echo Copying FAQ and other files from
$WEBFILES
650 cp $WEBFILES/site
/faq
*.htm
$APPDIR/docs
/html
651 cp $WEBFILES/site
/platform.htm
$APPDIR/docs
/html
652 cp $WEBFILES/site
/i18n.htm
$APPDIR/docs
/html
654 # Copy setup0.h files to setup.h
655 # OS/2 always built with configure now
656 # cp $APPDIR/include/wx/os2/setup0.h $APPDIR/include/wx/os2/setup.h
657 cp $APPDIR/include
/wx
/msw
/setup0.h
$APPDIR/include
/wx
/msw
/setup.h
658 cp $APPDIR/include
/wx
/univ
/setup0.h
$APPDIR/include
/wx
/univ
/setup.h
661 if [ "$SPINOS2" = "1" ] || [ "$SPINALL" = "1" ]; then
666 if [ "$SPINMAC" = "1" ] || [ "$SPINALL" = "1" ]; then
671 if [ "$SPINMSW" = "1" ] || [ "$SPINALL" = "1" ]; then
676 if [ "$SPINBASE" = "1" ] || [ "$SPINALL" = "1" ]; then
681 if [ "$SPINWXALL" = "1" ] || [ "$SPINALL" = "1" ]; then
686 if [ "$SPINDOCS" = "1" ] || [ "$SPINALL" = "1" ]; then
693 cp $APPDIR/docs
/changes.txt
$DESTDIR/changes
-$VERSION.txt
694 cp $APPDIR/docs
/readme.txt
$DESTDIR/readme
-$VERSION.txt
696 cp $APPDIR/docs
/msw
/readme.txt
$DESTDIR/readme
-msw-$VERSION.txt
697 cp $APPDIR/docs
/msw
/install.txt
$DESTDIR/install-msw-$VERSION.txt
699 cp $APPDIR/docs
/mac
/readme.txt
$DESTDIR/readme
-mac-$VERSION.txt
700 cp $APPDIR/docs
/mac
/install.txt
$DESTDIR/install-mac-$VERSION.txt
702 cp $APPDIR/docs
/motif
/readme.txt
$DESTDIR/readme
-motif-$VERSION.txt
703 cp $APPDIR/docs
/motif
/install.txt
$DESTDIR/install-motif-$VERSION.txt
705 cp $APPDIR/docs
/gtk
/readme.txt
$DESTDIR/readme
-gtk-$VERSION.txt
706 cp $APPDIR/docs
/gtk
/install.txt
$DESTDIR/install-gtk-$VERSION.txt
708 cp $APPDIR/docs
/x
11/readme.txt
$DESTDIR/readme
-x11-$VERSION.txt
709 # cp $APPDIR/docs/x11/readme-nanox.txt $DESTDIR/readme-nanox-$VERSION.txt
710 cp $APPDIR/docs
/x
11/install.txt
$DESTDIR/install-x11-$VERSION.txt
712 cp $APPDIR/docs
/mgl
/readme.txt
$DESTDIR/readme
-mgl-$VERSION.txt
713 cp $APPDIR/docs
/mgl
/install.txt
$DESTDIR/install-mgl-$VERSION.txt
715 cp $APPDIR/docs
/cocoa
/readme.txt
$DESTDIR/readme
-cocoa-$VERSION.txt
716 cp $APPDIR/docs
/cocoa
/install.txt
$DESTDIR/install-cocoa-$VERSION.txt
718 cp $APPDIR/docs
/base
/readme.txt
$DESTDIR/readme
-base-$VERSION.txt
720 cp $APPDIR/docs
/os
2/install.txt
$DESTDIR/install-os2-$VERSION.txt
722 cp $APPDIR/docs
/univ
/readme.txt
$DESTDIR/readme
-univ-$VERSION.txt
724 cp $APPDIR/docs
/readme_vms.txt
$DESTDIR/readme
-vms-$VERSION.txt
726 # cp $APPDIR/docs/motif/makewxmotif $DESTDIR/makewxmotif-$VERSION
727 # cp $APPDIR/docs/gtk/makewxgtk $DESTDIR/makewxgtk-$VERSION
729 # Time to regenerate the Inno Install script
730 if [ "$INNO" != "0" ]; then
735 # Get the makefiles that aren't in CVS and unarchive them
738 echo Getting eVC
++ project files...
739 curl http
://biolpc22.york.ac.uk
/pub
/CVS_Makefiles
/wx
-mk-evcprj.
zip --output /c
/transit
/wx
-mk-evcprj.
zip
740 echo Getting Digital Mars makefiles...
741 curl http
://biolpc22.york.ac.uk
/pub
/CVS_Makefiles
/wx
-mk-dmars.
zip --output /c
/transit
/wx
-mk-dmars.
zip
742 echo Getting VC
++ makefiles...
743 curl http
://biolpc22.york.ac.uk
/pub
/CVS_Makefiles
/wx
-mk-msvc.
zip --output /c
/transit
/wx
-mk-msvc.
zip
746 echo Unarchiving makefiles and project files...
747 unzip -o -a /c
/transit
/wx
-mk-evcprj.
zip
748 unzip -o -a /c
/transit
/wx
-mk-dmars.
zip
749 unzip -o -a /c
/transit
/wx
-mk-msvc.
zip
750 echo Done getting makefiles and project files.
753 # We can't use e.g. this:
754 # ls `cat $SRC/distrib/msw/makefile.rsp` zip -@ -u $DEST/wxWidgets-$VERSION-gen.zip
755 # because there's not enough space on the command line, plus we need to ignore the
757 # So if we need to (not in this script so far) we do something like this instead:
758 # expandlines $SRC/setup/files.rsp temp.txt
759 # zip -@ `$CYGPATHPROG -w $DEST/archive.zip` < temp.txt
768 for line
in `cat $toexpand` ; do
769 if [ $line != "" ]; then
770 ls $line >> $outputfile
777 echo "Usage: $PROGNAME [ options ]" 1>&2
779 echo " --help Display this help message"
780 echo " --upx Compress executable with UPX"
781 echo " --no-upx Do not compress executable with UPX"
782 echo " --inno Build the setup.exe"
783 echo " --no-inno Do not build the setup.exe"
784 echo " --wxmac Build wxMac distribution"
785 echo " --wxmsw Build wxMSW distribution"
786 echo " --wxos2 Build wxOS2 distribution"
787 echo " --wxall Build wxAll zip distribution"
788 echo " --wxbase Build wxBase zip distribution"
789 echo " --docs Build docs archives"
790 echo " --all Build all distributions (the default)"
791 echo " --getmakefiles Get out-of-CVS makefiles and unarchive into the wxWidgets source tree"
792 echo " --verbose Verbose zip operation"
794 echo Note that options only override settings
in $SCRIPTDIR/setup.var.
798 # Process command line options.
806 --wxmac) SPINMAC
=1; SPINALL
=0 ;;
807 --wxmsw) SPINMSW
=1; SPINALL
=0 ;;
808 --wxos2) SPINOS2
=1; SPINALL
=0 ;;
809 --wxall) SPINWXALL
=1; SPINALL
=0 ;;
810 --wxbase) SPINBASE
=1; SPINALL
=0 ;;
811 --getmakefiles) GETMAKEFILES
=1; SPINALL
=0 ;;
812 --docs) SPINDOCS
=1; SPINALL
=0 ;;
814 --verbose) VERBOSE
=1 ;;
825 if [ "$GETMAKEFILES" = "1" ]; then