diff options
| author | Daniel P. Berrange <berrange@redhat.com> | 2013-11-12 18:21:57 +0000 |
|---|---|---|
| committer | Daniel P. Berrange <berrange@redhat.com> | 2013-11-21 17:08:42 +0000 |
| commit | 5d6138f798d8d5f7b53a2ef01805f40c71016c2a (patch) | |
| tree | 54d7ef6cd288f13df8d8fd24155d4eafa42d532b /autobuild.sh | |
| parent | 416085d75a3436181b7378e64948546128605cea (diff) | |
| download | libvirt-python-v7-5d6138f798d8d5f7b53a2ef01805f40c71016c2a.tar.gz libvirt-python-v7-5d6138f798d8d5f7b53a2ef01805f40c71016c2a.tar.xz libvirt-python-v7-5d6138f798d8d5f7b53a2ef01805f40c71016c2a.zip | |
Setup distutils build system
Create a setup.py for building libvirt python code and add
supporting files
Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
Diffstat (limited to 'autobuild.sh')
| -rwxr-xr-x | autobuild.sh | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/autobuild.sh b/autobuild.sh new file mode 100755 index 0000000..b3beaf1 --- /dev/null +++ b/autobuild.sh @@ -0,0 +1,24 @@ +#!/bin/sh + +set -ve + +: ${AUTOBUILD_INSTALL_ROOT="$HOME/builder"} + +rm -rf MANIFEST dist build + + +python setup.py sdist + +python setup.py build +python setup.py test +python setup.py install --root="$AUTOBUILD_INSTALL_ROOT" + +type -p /usr/bin/rpmbuild > /dev/null 2>&1 || exit 0 + +if [ -n "$AUTOBUILD_COUNTER" ]; then + EXTRA_RELEASE=".auto$AUTOBUILD_COUNTER" +else + NOW=`date +"%s"` + EXTRA_RELEASE=".$USER$NOW" +fi +rpmbuild --nodeps --define "extra_release $EXTRA_RELEASE" -ta --clean dist/*.tar.gz |
