2 # Makes the wxWidgets RPMs
10 echo Updating from CVS...
16 echo Making wxGTK RPMs...
17 RPM_ROOT
=$WXDEST/wxgtk
/rpm
-root
19 if [ ! -d $WXDEST ]; then
23 rm -f -r $WXDEST/wxgtk
25 mkdir $WXDEST/wxgtk
/release
31 cd $WXDEST/wxgtk
/release
33 $WXSRC/configure
--with-gtk --no-recursion
35 make -j1 dist bzip
-dist-only
37 echo Setting up RPM build dir
$RPM_ROOT...
42 mkdir $RPM_ROOT/RPMS
/i386
43 mkdir $RPM_ROOT/RPMS
/i686
44 mkdir $RPM_ROOT/RPMS
/noarch
45 mkdir $RPM_ROOT/SOURCES
49 echo %_topdir
$RPM_ROOT > ~
/.rpmmacros
51 echo Copying wxGTK
-$WXVER.
tar.bz2 to
$RPM_ROOT/SOURCES...
52 cp wxGTK
-$WXVER.
tar.bz2
$RPM_ROOT/SOURCES
53 echo Copying wxGTK.spec to
$RPM_ROOT/SPECS...
54 cp $WXSRC/wxGTK.spec
$RPM_ROOT/SPECS
56 echo Starting wxGTK RPM build
, rpmbuild args
=$RPMBUILDARGS...
58 rpmbuild
-ba $RPMBUILDARGS SPECS
/wxGTK.spec
2>&1 | tee wxGTK.out
60 echo Finished wxGTK RPM build
, in $RPM_ROOT.
66 mkdir $WXDEST/$PLATFORM
68 cp $RPM_ROOT/SRPMS
/*.rpm
$WXDEST/$PLATFORM
69 cp $RPM_ROOT/RPMS
/i
386/*.rpm
$WXDEST/$PLATFORM
70 cp $WXDEST/wxgtk
/release
/*.
tar.gz
$WXDEST/$PLATFORM
71 cp $WXDEST/wxgtk
/release
/*.
tar.bz2
$WXDEST/$PLATFORM
73 # rm -f -r $WXDEST/wxgtk
75 echo Now try the RPMs with rpm
-i.
80 echo Making wxMGL RPMs...
81 RPM_ROOT
=$WXDEST/wxmgl
/rpm
-root
83 if [ ! -d $WXDEST ]; then
87 rm -f -r $WXDEST/wxmgl
89 mkdir $WXDEST/wxmgl
/release
95 cd $WXDEST/wxmgl
/release
97 $WXSRC/configure
--with-mgl --no-recursion
99 make -j1 dist bzip
-dist-only
101 echo Setting up RPM build dir
$RPM_ROOT...
104 mkdir $RPM_ROOT/BUILD
106 mkdir $RPM_ROOT/RPMS
/i386
107 mkdir $RPM_ROOT/RPMS
/i686
108 mkdir $RPM_ROOT/RPMS
/noarch
109 mkdir $RPM_ROOT/SOURCES
110 mkdir $RPM_ROOT/SPECS
111 mkdir $RPM_ROOT/SRPMS
113 echo %_topdir
$RPM_ROOT > ~
/.rpmmacros
115 echo Copying wxMGL
-$WXVER.
tar.bz2 to
$RPM_ROOT/SOURCES...
116 cp wxMGL
-$WXVER.
tar.bz2
$RPM_ROOT/SOURCES
117 echo Copying wxMGL.spec to
$RPM_ROOT/SPECS...
118 cp $WXSRC/wxMGL.spec
$RPM_ROOT/SPECS
120 echo Starting wxMGL RPM build...
122 rpmbuild
-ba SPECS
/wxMGL.spec
2>&1 | tee wxMGL.out
124 echo Finished wxMGL RPM build
, in $RPM_ROOT.
130 cp $RPM_ROOT/SRPMS
/*.rpm
$WXDEST
131 cp $RPM_ROOT/RPMS
/i
386/*.rpm
$WXDEST
132 cp $WXDEST/wxmgl
/release
/*.
tar.gz
$WXDEST
133 cp $WXDEST/wxmgl
/release
/*.
tar.bz2
$WXDEST
135 # rm -f -r $WXDEST/wxmgl
137 echo Now try the RPMs with rpm
-i.
142 echo Making wxMotif RPMs...
143 RPM_ROOT
=$WXDEST/wxmotif
/rpm
-root
145 if [ ! -d $WXDEST ]; then
149 rm -f -r $WXDEST/wxmotif
150 mkdir $WXDEST/wxmotif
151 mkdir $WXDEST/wxmotif
/release
157 cd $WXDEST/wxmotif
/release
159 $WXSRC/configure
--with-motif --no-recursion
161 make -j1 dist bzip
-dist-only
163 echo Setting up RPM build dir
$RPM_ROOT...
166 mkdir $RPM_ROOT/BUILD
168 mkdir $RPM_ROOT/RPMS
/i386
169 mkdir $RPM_ROOT/RPMS
/i686
170 mkdir $RPM_ROOT/RPMS
/noarch
171 mkdir $RPM_ROOT/SOURCES
172 mkdir $RPM_ROOT/SPECS
173 mkdir $RPM_ROOT/SRPMS
175 echo %_topdir
$RPM_ROOT > ~
/.rpmmacros
177 echo Copying wxMOTIF
-$WXVER.
tar.bz2 to
$RPM_ROOT/SOURCES...
178 cp wxMOTIF
-$WXVER.
tar.bz2
$RPM_ROOT/SOURCES
179 echo Copying wxMotif.spec to
$RPM_ROOT/SPECS...
180 cp $WXSRC/wxMotif.spec
$RPM_ROOT/SPECS
182 echo Starting wxMotif RPM build...
184 rpmbuild
-ba SPECS
/wxMotif.spec
2>&1 | tee wxGTK.out
186 echo Finished wxMotif RPM build
, in $RPM_ROOT.
192 cp $RPM_ROOT/SRPMS
/*.rpm
$WXDEST
193 cp $RPM_ROOT/RPMS
/i
386/*.rpm
$WXDEST
194 cp $WXDEST/wxmotif
/release
/*.
tar.gz
$WXDEST
195 cp $WXDEST/wxmotif
/release
/*.
tar.bz2
$WXDEST
197 echo Rearchiving wxMotif tarballs to change wxMOTIF to wxMotif...
202 tar xfz ..
/wxMOTIF
-$WXVER.
tar.gz
203 mv wxMOTIF
-$WXVER wxMotif
-$WXVER
204 rm -f ..
/wxMOTIF
-$WXVER.
tar.gz
205 rm -f ..
/wxMOTIF
-$WXVER.
tar.bz2
206 tar cf ..
/wxMotif
-$WXVER.
tar *
207 gzip -c ..
/wxMotif
-$WXVER.
tar > ..
/wxMotif
-$WXVER.
tar.gz
208 bzip2 -f9 ..
/wxMotif
-$WXVER.
tar
211 # rm -f -r $WXDEST/wxmotif
213 echo Now try the RPMs with rpm
-i.
218 echo Making wxMac tarballs...
219 echo Note that this must be
done on a Mac.
220 if [ ! -d $WXDEST ]; then
224 rm -f -r $WXDEST/wxmac
226 mkdir $WXDEST/wxmac
/release
231 cd $WXDEST/wxmac
/release
233 $WXSRC/configure
--with-mac --no-recursion
235 make -j1 dist bzip
-dist-only
237 cp $WXDEST/wxmac
/release
/*.
tar.gz
$WXDEST
238 cp $WXDEST/wxmac
/release
/*.
tar.bz2
$WXDEST
240 echo Rearchiving wxMac tarballs to change wxMAC to wxMAC...
245 tar xfz ..
/wxMac
-$WXVER.
tar.gz
246 mv wxMAC
-$WXVER wxMac
-$WXVER
247 rm -f ..
/wxMAC
-$WXVER.
tar.gz
248 rm -f ..
/wxMAC
-$WXVER.
tar.bz2
249 tar cf ..
/wxMac
-$WXVER.
tar *
250 gzip -c ..
/wxMac
-$WXVER.
tar > ..
/wxMac
-$WXVER.
tar.gz
251 bzip2 -f9 ..
/wxMac
-$WXVER.
tar
255 rm -f -r $WXDEST/wxmac
256 echo Now try the RPMs with rpm
-i.
261 echo Making wxBase RPMs...
262 RPM_ROOT
=$WXDEST/wxbase
/rpm
-root
264 if [ ! -d $WXDEST ]; then
268 rm -f -r $WXDEST/wxbase
270 mkdir $WXDEST/wxbase
/release
276 cd $WXDEST/wxbase
/release
278 $WXSRC/configure
--disable-gui --no-recursion
280 make -j1 dist bzip
-dist-only
282 echo Setting up RPM build dir
$RPM_ROOT...
285 mkdir $RPM_ROOT/BUILD
287 mkdir $RPM_ROOT/RPMS
/i386
288 mkdir $RPM_ROOT/RPMS
/i686
289 mkdir $RPM_ROOT/RPMS
/noarch
290 mkdir $RPM_ROOT/SOURCES
291 mkdir $RPM_ROOT/SPECS
292 mkdir $RPM_ROOT/SRPMS
294 echo %_topdir
$RPM_ROOT > ~
/.rpmmacros
296 echo Copying wxBase
-$WXVER.
tar.bz2 to
$RPM_ROOT/SOURCES...
297 cp wxBase
-$WXVER.
tar.bz2
$RPM_ROOT/SOURCES
298 echo Copying wxBase.spec to
$RPM_ROOT/SPECS...
299 cp $WXSRC/wxBase.spec
$RPM_ROOT/SPECS
301 echo Starting wxBase RPM build
, rpmbuild args
=$RPMBUILDARGS...
303 rpmbuild
-ba $RPMBUILDARGS SPECS
/wxBase.spec
2>&1 | tee wxBase.out
305 echo Finished wxBase RPM build
, in $RPM_ROOT.
311 mkdir $WXDEST/$PLATFORM
313 cp $RPM_ROOT/SRPMS
/*.rpm
$WXDEST/$PLATFORM
314 cp $RPM_ROOT/RPMS
/i
386/*.rpm
$WXDEST/$PLATFORM
315 cp $WXDEST/wxbase
/release
/*.
tar.gz
$WXDEST/$PLATFORM
316 cp $WXDEST/wxbase
/release
/*.
tar.bz2
$WXDEST/$PLATFORM
318 # rm -f -r $WXDEST/wxbase
319 echo Now try the RPMs with rpm
-i.
324 echo Making wxX11 RPMs...
325 RPM_ROOT
=$WXDEST/wxx
11/rpm
-root
327 if [ ! -d $WXDEST ]; then
331 rm -f -r $WXDEST/wxx11
333 mkdir $WXDEST/wxx
11/release
339 cd $WXDEST/wxx
11/release
341 $WXSRC/configure
--with-x11 --no-recursion
343 make -j1 dist bzip
-dist-only
345 echo Setting up RPM build dir
$RPM_ROOT...
348 mkdir $RPM_ROOT/BUILD
350 mkdir $RPM_ROOT/RPMS
/i386
351 mkdir $RPM_ROOT/RPMS
/i686
352 mkdir $RPM_ROOT/RPMS
/noarch
353 mkdir $RPM_ROOT/SOURCES
354 mkdir $RPM_ROOT/SPECS
355 mkdir $RPM_ROOT/SRPMS
357 echo %_topdir
$RPM_ROOT > ~
/.rpmmacros
359 echo Copying wxX11
-$WXVER.
tar.bz2 to
$RPM_ROOT/SOURCES...
360 cp wxX11
-$WXVER.
tar.bz2
$RPM_ROOT/SOURCES
361 echo Copying wxX11.spec to
$RPM_ROOT/SPECS...
362 cp $WXSRC/wxX11.spec
$RPM_ROOT/SPECS
364 echo Starting wxX11 RPM build...
366 rpmbuild
-ba SPECS
/wxX11.spec
2>&1 | tee wxX11.out
368 echo Finished wxX11 RPM build
, in $RPM_ROOT.
374 cp $RPM_ROOT/SRPMS
/*.rpm
$WXDEST
375 cp $RPM_ROOT/RPMS
/i
386/*.rpm
$WXDEST
376 cp $WXDEST/wxx
11/release
/*.
tar.gz
$WXDEST
377 cp $WXDEST/wxx
11/release
/*.
tar.bz2
$WXDEST
379 # rm -f -r $WXDEST/wxx11
380 echo Now try the RPMs with rpm
-i.
402 echo Usage
: $PROGNAME "src-dir dest-dir version-number [ options ]"
404 echo " --help Display this help message"
405 echo " --wxgtk1 Spin wxGTK1 RPMs"
406 echo " --wxgtk2 Spin wxGTK2 RPMs"
407 echo " --wxgtk2unicode Spin wxGTK2 Unicode RPMs"
408 echo " --wxbase Spin wxBase RPMs"
409 echo " --wxbaseunicode Spin wxBase Unicode RPMs"
410 echo " --wxx11 Spin wxX11 RPMs"
411 echo " --wxmotif Spin wxMotif RPMs"
412 echo " --wxmgl Spin wxMGL RPMs"
413 echo " --wxmac Make wxMac tarball"
414 echo " --all Spin EVERYTHING"
415 echo " --updatecvs Update from CVS"
439 # Process command line options.
443 --wxx11) SPINWXX11
=1 ;;
444 --wxgtk1) SPINWXGTK1
=1 ;;
445 --wxgtk2) SPINWXGTK2
=1 ;;
446 --wxgtk2unicode) SPINWXGTK2UNICODE
=1 ;;
447 --wxmotif) SPINWXMOTIF
=1 ;;
448 --wxmgl) SPINWXMGL
=1 ;;
449 --wxmac) SPINWXMAC
=1 ;;
450 --wxbase) SPINWXBASE
=1 ;;
451 --wxbaseunicode) SPINWXBASEUNICODE
=1 ;;
452 --all) SPINEVERYTHING
=1 ;;
453 --updatecvs) UPDATECVS
=1 ;;
461 echo About to
make wxWidgets RPMs
:
465 echo CTRL
-C if this is not correct.
468 if [ "$UPDATECVS" = "1" ]; then
472 if [ "$SPINWXX11" = "1" ] || [ "$SPINEVERYTHING" = "1" ]; then
476 if [ "$SPINWXGTK1" = "1" ] || [ "$SPINEVERYTHING" = "1" ]; then
482 if [ "$SPINWXGTK2" = "1" ] || [ "$SPINEVERYTHING" = "1" ]; then
483 RPMBUILDARGS
="--with gtk2"
488 if [ "$SPINWXGTK2UNICODE" = "1" ] || [ "$SPINEVERYTHING" = "1" ]; then
489 RPMBUILDARGS
="--with gtk2 --with unicode"
494 if [ "$SPINWXBASE" = "1" ] || [ "$SPINEVERYTHING" = "1" ]; then
499 if [ "$SPINWXBASEUNICODE" = "1" ] || [ "$SPINEVERYTHING" = "1" ]; then
500 RPMBUILDARGS
="--with unicode"
505 if [ "$SPINWXMOTIF" = "1" ] || [ "$SPINEVERYTHING" = "1" ]; then
509 if [ "$SPINWXMGL" = "1" ] || [ "$SPINEVERYTHING" = "1" ]; then
513 if [ "$SPINWXMAC" = "1" ]; then