2004-06-14 15:53:50 -04:00
|
|
|
#!/bin/bash
|
|
|
|
# ---------------------------------------------------------------------------
|
|
|
|
# Build the wxPython source RPMs on a Linux box. This is normally called
|
|
|
|
# from build-all but it should be able to be used standalone too...
|
|
|
|
#
|
|
|
|
# The command line must have the following parameters:
|
|
|
|
#
|
2004-07-06 16:58:16 -04:00
|
|
|
# 1. the path of the build dir. The src RPMs will be here when we start
|
|
|
|
# and the binary RPMs will be left here when we're done.
|
|
|
|
# 2. skipclean flag (yes|no)
|
|
|
|
# 3. the VERSION
|
|
|
|
# 4. the remaining args are the versions of Python to build for
|
2004-06-14 15:53:50 -04:00
|
|
|
#
|
|
|
|
# ---------------------------------------------------------------------------
|
|
|
|
|
|
|
|
set -o errexit
|
|
|
|
#set -o xtrace
|
|
|
|
|
|
|
|
echo "-=-=-=- Hello from $HOSTNAME -=-=-=-"
|
|
|
|
|
2004-07-15 20:02:49 -04:00
|
|
|
if [ $# -lt 4]; then
|
2004-06-14 15:53:50 -04:00
|
|
|
echo "Usage: $0 WXDIR DESTDIR SKIPCLEAN VERSION PYVER..."
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
2004-07-06 16:58:16 -04:00
|
|
|
DESTDIR=$1
|
|
|
|
SKIPCLEAN=$2
|
|
|
|
VERSION=$3
|
|
|
|
shift;shift;shift
|
2004-06-14 15:53:50 -04:00
|
|
|
PYVER=$@
|
|
|
|
|
|
|
|
# Since this is probably a VMWare guest, make sure that the date and
|
|
|
|
# time are correct
|
|
|
|
ntpdate gate.alldunn.com
|
|
|
|
|
|
|
|
|
2004-07-06 16:58:16 -04:00
|
|
|
cd $DESTDIR
|
2004-06-14 15:53:50 -04:00
|
|
|
|
|
|
|
for ver in $PYVER; do
|
|
|
|
echo "Building the RPMs for Python $ver..."
|
2004-07-06 16:58:16 -04:00
|
|
|
myrpmbuild --rebuild wxPythonGTK-py$ver-$VERSION-1.src.rpm
|
|
|
|
myrpmbuild --rebuild wxPythonGTK2-py$ver-$VERSION-1.src.rpm
|
2004-06-14 15:53:50 -04:00
|
|
|
done
|
|
|
|
|
|
|
|
|
2004-07-15 20:02:49 -04:00
|
|
|
#echo "Copying RPMs to $DESTDIR..."
|
|
|
|
#cp wxPythonGTK*.i[0-9]86.rpm $DESTDIR
|
|
|
|
#cd $DESTDIR
|
2004-06-14 15:53:50 -04:00
|
|
|
|
|
|
|
|
|
|
|
if [ $SKIPCLEAN != yes ]; then
|
|
|
|
echo "Cleaning up..."
|
2004-07-06 16:58:16 -04:00
|
|
|
for ver in $PYVER; do
|
|
|
|
rm wxPythonGTK-py$ver-$VERSION-1.src.rpm
|
|
|
|
done
|
2004-06-14 15:53:50 -04:00
|
|
|
fi
|
|
|
|
|
|
|
|
echo "-=-=-=- Goodbye! -=-=-=-"
|