Added scripts to build debian packages
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@43712 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -88,11 +88,16 @@ def getTasks(config_env):
|
|||||||
# Job("co-mdk2006.24","distrib/all/build-rpm", ["beast", "co-mdk2006", "mdk2006", "2.4"], env=config_env),
|
# Job("co-mdk2006.24","distrib/all/build-rpm", ["beast", "co-mdk2006", "mdk2006", "2.4"], env=config_env),
|
||||||
])
|
])
|
||||||
|
|
||||||
|
xavierTask = Task([
|
||||||
|
Job("xavier", "distrib/all/build-deb", ["xavier", "/work/chroot/dapper", "dapper"], env=config_env),
|
||||||
|
])
|
||||||
|
|
||||||
buildTasks = [ #jaguarTask,
|
buildTasks = [ #jaguarTask,
|
||||||
pantherTask,
|
pantherTask,
|
||||||
tigerTask,
|
tigerTask,
|
||||||
beastTask1,
|
beastTask1,
|
||||||
beastTask2,
|
beastTask2,
|
||||||
|
xavierTask,
|
||||||
]
|
]
|
||||||
|
|
||||||
# Finalization. This is for things that must wait until all the
|
# Finalization. This is for things that must wait until all the
|
||||||
@@ -121,7 +126,8 @@ def usage():
|
|||||||
print " skipdocs Don't rebuild the docs"
|
print " skipdocs Don't rebuild the docs"
|
||||||
print " skipwin Don't do the remote Windows build"
|
print " skipwin Don't do the remote Windows build"
|
||||||
print " skiposx Don't do the remote OSX build"
|
print " skiposx Don't do the remote OSX build"
|
||||||
print " skiplinux Don't do the remote Linux (RPM) build"
|
print " skiprpm Don't do the remote Linux (RPM) build"
|
||||||
|
print " skipdeb Don't do the remote Linux (DEB) build"
|
||||||
print " skipclean Don't do the cleanup step on the remote builds"
|
print " skipclean Don't do the cleanup step on the remote builds"
|
||||||
print " skipupload Don't upload the builds to starship"
|
print " skipupload Don't upload the builds to starship"
|
||||||
print " ansi Also do the ansi builds"
|
print " ansi Also do the ansi builds"
|
||||||
@@ -166,8 +172,11 @@ def main(args):
|
|||||||
elif flag == "skiposx":
|
elif flag == "skiposx":
|
||||||
config.skiposx = "yes"
|
config.skiposx = "yes"
|
||||||
|
|
||||||
elif flag == "skiplinux":
|
elif flag == "skipdeb":
|
||||||
config.skiplinux = "yes"
|
config.skipdeb = "yes"
|
||||||
|
|
||||||
|
elif flag == "skiprpm":
|
||||||
|
config.skiprpm = "yes"
|
||||||
|
|
||||||
elif flag == "skipclean":
|
elif flag == "skipclean":
|
||||||
config.skipclean = "yes"
|
config.skipclean = "yes"
|
||||||
@@ -198,7 +207,8 @@ def main(args):
|
|||||||
file("DAILY_BUILD", "w").write(config.DAILY)
|
file("DAILY_BUILD", "w").write(config.DAILY)
|
||||||
sys.path.append('.')
|
sys.path.append('.')
|
||||||
import setup
|
import setup
|
||||||
config.VERSION = setup.VERSION
|
v = config.VERSION = setup.VERSION
|
||||||
|
config.VER2 = '.'.join(v.split('.')[:2])
|
||||||
|
|
||||||
config_env = config.asDict()
|
config_env = config.asDict()
|
||||||
config_env.update(os.environ)
|
config_env.update(os.environ)
|
||||||
|
53
wxPython/distrib/all/build-deb
Executable file
53
wxPython/distrib/all/build-deb
Executable file
@@ -0,0 +1,53 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
#----------------------------------------------------------------------
|
||||||
|
|
||||||
|
set -o errexit
|
||||||
|
#set -o xtrace
|
||||||
|
|
||||||
|
host=$1
|
||||||
|
chRootRoot=$2
|
||||||
|
chRootName=$3
|
||||||
|
|
||||||
|
|
||||||
|
function TestOnline {
|
||||||
|
local host=$1
|
||||||
|
local message=$2
|
||||||
|
|
||||||
|
if ping -q -c1 -w1 $host > /dev/null; then
|
||||||
|
return 0
|
||||||
|
else
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
if [ $skipdeb != yes ]; then
|
||||||
|
# We use a chroot environment on th elocal machine for the debian
|
||||||
|
# builds, so this build is pretty simple. Just copy the tarball
|
||||||
|
# and a build script to /tmp, and then run do-build-deb in the
|
||||||
|
# chroot.
|
||||||
|
|
||||||
|
if TestOnline $host; then
|
||||||
|
|
||||||
|
echo "The $host machine is online, build continuing..."
|
||||||
|
|
||||||
|
echo "Copying source files and build script..."
|
||||||
|
ssh root@$host "mkdir -p $chRootRoot/$LINUX_BUILD && rm -rf $chRootRoot/$LINUX_BUILD/*"
|
||||||
|
scp $STAGING_DIR/wxPython-src* distrib/all/do-build-deb \
|
||||||
|
root@$host:$chRootRoot/$LINUX_BUILD
|
||||||
|
|
||||||
|
ssh root@$host "dchroot --chroot $chRootName --directory $LINUX_BUILD \"do-build-deb $VERSION $VER2\""
|
||||||
|
|
||||||
|
echo "Fetching the results..."
|
||||||
|
mkdir -p $STAGING_DIR/$chRootName
|
||||||
|
ssh root@$host "rm $chRootRoot/$LINUX_BUILD/do-build-deb"
|
||||||
|
scp "root@$host:$chRootRoot/$LINUX_BUILD/*" $STAGING_DIR/$chRootName
|
||||||
|
ssh root@$host "rm $chRootRoot/$LINUX_BUILD/*"
|
||||||
|
echo "Done!"
|
||||||
|
else
|
||||||
|
echo "The $host machine is **OFFLINE**, skipping the binary DEB build."
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
@@ -43,7 +43,8 @@ onlysource = no
|
|||||||
skipdocs = no
|
skipdocs = no
|
||||||
skipwin = no
|
skipwin = no
|
||||||
skiposx = no
|
skiposx = no
|
||||||
skiplinux = no
|
skipdeb = no
|
||||||
|
skiprpm = no
|
||||||
skipclean = no
|
skipclean = no
|
||||||
skipupload = no
|
skipupload = no
|
||||||
skipnewdocs = no
|
skipnewdocs = no
|
||||||
|
@@ -19,14 +19,14 @@ if [ $KIND = daily ]; then
|
|||||||
echo "Copying to the local file server..."
|
echo "Copying to the local file server..."
|
||||||
destdir=/stuff/temp/$VERSION
|
destdir=/stuff/temp/$VERSION
|
||||||
mkdir -p $destdir
|
mkdir -p $destdir
|
||||||
cp $STAGING_DIR/* $destdir
|
cp -R $STAGING_DIR/* $destdir
|
||||||
|
|
||||||
if [ $skipupload != yes ]; then
|
if [ $skipupload != yes ]; then
|
||||||
destdir=$UPLOAD_PREVIEW_ROOT/$DAILY
|
destdir=$UPLOAD_PREVIEW_ROOT/$DAILY
|
||||||
echo "Copying to $UPLOAD_HOST at $destdir..."
|
echo "Copying to $UPLOAD_HOST at $destdir..."
|
||||||
if [ $UPLOAD_METHOD = ssh ]; then
|
if [ $UPLOAD_METHOD = ssh ]; then
|
||||||
ssh $UPLOAD_HOST "mkdir -p $destdir"
|
ssh $UPLOAD_HOST "mkdir -p $destdir"
|
||||||
scp -p $STAGING_DIR/* $UPLOAD_HOST:/$destdir
|
scp -pr $STAGING_DIR/* $UPLOAD_HOST:/$destdir
|
||||||
fi
|
fi
|
||||||
if [ $UPLOAD_METHOD = ftp ]; then
|
if [ $UPLOAD_METHOD = ftp ]; then
|
||||||
lftp -c "open $UPLOAD_HOST; mkdir $destdir"
|
lftp -c "open $UPLOAD_HOST; mkdir $destdir"
|
||||||
@@ -61,7 +61,7 @@ EOF
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
echo "Cleaning up staging dir..."
|
echo "Cleaning up staging dir..."
|
||||||
rm $STAGING_DIR/*
|
rm -r $STAGING_DIR/*
|
||||||
rmdir $STAGING_DIR
|
rmdir $STAGING_DIR
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
@@ -73,14 +73,14 @@ if [ $KIND = release ]; then
|
|||||||
echo "Copying to the local file server..."
|
echo "Copying to the local file server..."
|
||||||
destdir=/stuff/Development/wxPython/dist/$VERSION
|
destdir=/stuff/Development/wxPython/dist/$VERSION
|
||||||
mkdir -p $destdir
|
mkdir -p $destdir
|
||||||
cp $STAGING_DIR/* $destdir
|
cp -R $STAGING_DIR/* $destdir
|
||||||
|
|
||||||
if [ $skipupload != yes ]; then
|
if [ $skipupload != yes ]; then
|
||||||
echo "Copying to $UPLOAD_HOST..."
|
echo "Copying to $UPLOAD_HOST..."
|
||||||
destdir=$UPLOAD_RELEASE_ROOT/$VERSION
|
destdir=$UPLOAD_RELEASE_ROOT/$VERSION
|
||||||
if [ $UPLOAD_METHOD = ssh ]; then
|
if [ $UPLOAD_METHOD = ssh ]; then
|
||||||
ssh $UPLOAD_HOST "mkdir -p $destdir"
|
ssh $UPLOAD_HOST "mkdir -p $destdir"
|
||||||
scp -p $STAGING_DIR/* $UPLOAD_HOST:/$destdir
|
scp -pr $STAGING_DIR/* $UPLOAD_HOST:/$destdir
|
||||||
fi
|
fi
|
||||||
if [ $UPLOAD_METHOD = ftp ]; then
|
if [ $UPLOAD_METHOD = ftp ]; then
|
||||||
lftp -c "open $UPLOAD_HOST; mkdir $destdir"
|
lftp -c "open $UPLOAD_HOST; mkdir $destdir"
|
||||||
|
@@ -28,7 +28,7 @@ function TestOnline {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if [ $skiplinux != yes ]; then
|
if [ $skiprpm != yes ]; then
|
||||||
|
|
||||||
startedCoHost=no
|
startedCoHost=no
|
||||||
hostAvailable=no
|
hostAvailable=no
|
||||||
|
31
wxPython/distrib/all/do-build-deb
Executable file
31
wxPython/distrib/all/do-build-deb
Executable file
@@ -0,0 +1,31 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# ---------------------------------------------------------------------------
|
||||||
|
|
||||||
|
set -o errexit
|
||||||
|
set -o xtrace
|
||||||
|
|
||||||
|
echo "-=-=-=- Hello from $HOSTNAME -=-=-=-"
|
||||||
|
|
||||||
|
VERSION=$1
|
||||||
|
VER2=$2
|
||||||
|
|
||||||
|
|
||||||
|
tar xjf wxPython-src-$VERSION.tar.bz2
|
||||||
|
rm wxPython-src-$VERSION.tar.bz2
|
||||||
|
|
||||||
|
mv wxPython-src-$VERSION wxwidgets$VER2-$VERSION
|
||||||
|
cd wxwidgets$VER2-$VERSION
|
||||||
|
|
||||||
|
CLVERSION=`dpkg-parsechangelog | sed -n 's/Version: //p' | sed 's/-.*//'`
|
||||||
|
if [ $CLVERSION != $VERSION ]; then
|
||||||
|
dch --newversion $VERSION-0 "automated build"
|
||||||
|
fi
|
||||||
|
|
||||||
|
debian/rules debian/control
|
||||||
|
dpkg-buildpackage -rfakeroot -us -uc
|
||||||
|
|
||||||
|
cd ..
|
||||||
|
rm -r wxwidgets$VER2-$VERSION
|
||||||
|
|
||||||
|
echo "-=-=-=- Goodbye! -=-=-=-"
|
||||||
|
exit 0
|
Reference in New Issue
Block a user