Removed debian/rules stuff that is already in pkgos.make
[openstack-build/ceilometer-build.git] / trusty / debian / rules
1 #!/usr/bin/make -f
2
3 #export DH_VERBOSE=1
4
5 include /usr/share/openstack-pkg-tools/pkgos.make
6
7 %:
8         dh $@  --with python2
9
10 DEBVERS := $(shell dpkg-parsechangelog | sed -n -e 's/^Version: //p')
11 VERSION := $(shell echo '$(DEBVERS)' | sed -e 's/^[[:digit:]]*://' -e 's/[~-].*//')
12 DEBFLAVOR :=$(shell dpkg-parsechangelog | grep -E ^Distribution: | cut -d" " -f2)
13 DEBPKGNAME :=$(shell dpkg-parsechangelog | grep -E ^Source: | cut -d" " -f2)
14
15 override_dh_installchangelogs:
16         dh_installchangelogs debian/CHANGELOG
17
18 override_dh_auto_clean:
19         dh_auto_clean
20         rm -rf debian/*.upstart
21
22 override_dh_installinit:
23         if dpkg-vendor --derives-from ubuntu ; then \
24                 for i in *.upstart.in ; do \
25                         MYPKG=`echo $i | cut -d. -f1` ; \
26                         cp $MYPKG.upstart.in $MYPKG.upstart ; \
27                 done ; \
28         fi
29         dh_installinit --error-handler=true
30
31 override_dh_gencontrol:
32         if dpkg-vendor --derives-from ubuntu ; then \
33                 dh_gencontrol -- -T$(CURDIR)/debian/ubuntu_control_vars ; \
34         else \
35                 dh_gencontrol -- -T$(CURDIR)/debian/debian_control_vars ; \
36         fi