adding debian/rules for package building
This commit is contained in:
2
debian/changelog
vendored
2
debian/changelog
vendored
@@ -1,4 +1,4 @@
|
|||||||
nova-compute-openvz (1.0-1) UNRELEASED; urgency=low
|
openvz-nova-driver (1.0-1) UNRELEASED; urgency=low
|
||||||
|
|
||||||
* Initial release. (Closes: #XXXXXX)
|
* Initial release. (Closes: #XXXXXX)
|
||||||
|
|
||||||
|
|||||||
6
debian/control
vendored
6
debian/control
vendored
@@ -1,10 +1,10 @@
|
|||||||
Source: nova-compute-openvz
|
Source: openvz-nova-driver
|
||||||
Maintainer: Daniel Salinas <imsplitbit@gmail.com>
|
Maintainer: Daniel Salinas <imsplitbit@gmail.com>
|
||||||
Priority: optional
|
Priority: optional
|
||||||
Build-Depends: python-setuptools (>= 0.6b3), debhelper (>= 7.4.3), python-support (>= 0.8.4)
|
Build-Depends: debhelper (>= 7.4.3), python-support (>= 0.8.4)
|
||||||
Standards-Version: 3.8.4
|
Standards-Version: 3.8.4
|
||||||
|
|
||||||
Package: nova-compute-openvz
|
Package: openvz-nova-driver
|
||||||
Architecture: all
|
Architecture: all
|
||||||
Depends: ${misc:Depends},
|
Depends: ${misc:Depends},
|
||||||
${python:Depends},
|
${python:Depends},
|
||||||
|
|||||||
36
debian/rules
vendored
Executable file
36
debian/rules
vendored
Executable file
@@ -0,0 +1,36 @@
|
|||||||
|
#!/usr/bin/make -f
|
||||||
|
|
||||||
|
export MASTER_HEAD=`git log -1 --format=%h master`
|
||||||
|
export DEVELOPMENT_HEAD=`git log -1 --format=%h development`
|
||||||
|
export CHANGELOGENTRY="$(VERSION_STRING)"
|
||||||
|
|
||||||
|
%:
|
||||||
|
dh $@ --with python2
|
||||||
|
|
||||||
|
# If you want to run an automated build (for something like Jenkins),
|
||||||
|
# this is the thing for you. Just run:
|
||||||
|
#
|
||||||
|
# debian/rules automated-build
|
||||||
|
#
|
||||||
|
automated-build:
|
||||||
|
# Make a backup of the upstream debian/control
|
||||||
|
cp -av debian/control debian/control.pristine
|
||||||
|
|
||||||
|
# Add the current git hash to the Description field of the package
|
||||||
|
sed -i "s/^Description: .*$$/& (master: $(MASTER_HEAD) development: $(DEVELOPMENT_HEAD))/" debian/control
|
||||||
|
|
||||||
|
# Update the changelog
|
||||||
|
dch -v $(CHANGELOGENTRY) "Automated build."
|
||||||
|
|
||||||
|
# Clean up
|
||||||
|
dh clean
|
||||||
|
|
||||||
|
# Build it
|
||||||
|
dh build --with python2
|
||||||
|
fakeroot dh binary --with python2
|
||||||
|
|
||||||
|
# Put the upstream debian/control back in place
|
||||||
|
mv -v debian/control.pristine debian/control
|
||||||
|
|
||||||
|
override_dh_install:
|
||||||
|
dh_install --fail-missing
|
||||||
Reference in New Issue
Block a user