File: rules

package info (click to toggle)
nova 2012.1.1-18
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 18,900 kB
  • sloc: python: 102,511; sql: 3,318; sh: 2,488; xml: 1,131; makefile: 146
file content (86 lines) | stat: -rwxr-xr-x 2,963 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
#!/usr/bin/make -f

# Verbose mode
# export DH_VERBOSE=1

%:
	dh $@ --with python2

override_dh_auto_clean:
	dh_auto_clean
	rm -fr doc/source/api
	rm -fr doc/build/man
	rm -fr doc/build/html
	rm -fr doc/build/doctress
	rm -rf tests.sqlite clean.sqlite run_tests.log
	rm -rf CA
	rm -rf nova.egg-info
	rm -f po/nova.pot

override_dh_auto_build:
	dh_auto_build
ifeq (,$(findstring nodocs, $(DEB_BUILD_OPTIONS)))
	python setup.py build_sphinx
endif

override_dh_install:
	dh_install
	chmod 440 $(CURDIR)/debian/nova-common/etc/sudoers.d/nova_sudoers
	#install -D -m 0664 $(CURDIR)/debian/nova-volume.default $(CURDIR)/debian/nova-volume/etc/default/nova-volume
	for hypervisor in qemu kvm uml lxc; do \
		install -D -m 0600 $(CURDIR)/debian/nova-compute-$${hypervisor}.conf $(CURDIR)/debian/nova-compute-$${hypervisor}/etc/nova/nova-compute.conf; \
	done
	install -D -m 0600 $(CURDIR)/debian/nova-compute-xen.conf.dist $(CURDIR)/debian/nova-compute-xen/usr/share/doc/nova-compute-xen/nova-compute.conf.dist

override_dh_fixperms:
	dh_fixperms -Xnova_sudoers
	rm -f $(CURDIR)/debian/python-nova/usr/share/pyshared/nova/CA/.gitignore
	rm -f $(CURDIR)/debian/python-nova/usr/share/pyshared/nova/CA/projects/.gitignore
	rm -f $(CURDIR)/debian/python-nova/usr/share/pyshared/nova/CA/reqs/.gitignore

ifeq (,$(findstring nocheck, $(DEB_BUILD_OPTIONS)))
override_dh_auto_test:
	./run_tests.sh -N -P
endif

override_dh_installinit:
	dh_installinit
	dh_installinit -pnova-console --name=nova-consoleauth

override_dh_installdocs:
ifeq (,$(findstring nodocs, $(DEB_BUILD_OPTIONS)))
	dh_installdocs
	ln -sf /usr/share/javascript/jquery/jquery.js $(CURDIR)/debian/nova-doc/usr/share/doc/nova-doc/html/_static/jquery.js
	ln -sf /usr/share/javascript/underscore/underscore.min.js $(CURDIR)/debian/nova-doc/usr/share/doc/nova-doc/html/_static/underscore.js
else
override_dh_installman:
endif

override_dh_python2:
	dh_python2
	dh_python2  /usr/lib/xcp
	rm debian/python-nova/usr/lib/python2.6/dist-packages/nova/CA/.gitignore
	rm debian/python-nova/usr/lib/python2.6/dist-packages/nova/CA/projects/.gitignore
	rm debian/python-nova/usr/lib/python2.6/dist-packages/nova/CA/reqs/.gitignore
	rm debian/python-nova/usr/lib/python2.7/dist-packages/nova/CA/.gitignore
	rm debian/python-nova/usr/lib/python2.7/dist-packages/nova/CA/projects/.gitignore
	rm debian/python-nova/usr/lib/python2.7/dist-packages/nova/CA/reqs/.gitignore

get-vcs-source:
	git remote add upstream git://github.com/openstack/nova.git || true
	git fetch upstream
	git archive --prefix=nova-2012.1/ 2012.1 | xz >../nova_2012.1.orig.tar.xz
	if ! git checkout master ; then \
		echo "No upstream branch: checking out" ; \
		git checkout -b master upstream/master ; \
	fi
	git checkout debian/unstable

display-po-stats:
	cd $(CURDIR)/debian/po ; for i in *.po ; do \
		echo -n $$i": " ; \
		msgfmt -o /dev/null --statistic $$i ; \
	done

call-for-po-trans:
	podebconf-report-po --call --withtranslators --languageteam