File: rules

package info (click to toggle)
rally-openstack 2.2.0-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 8,568 kB
  • sloc: python: 54,150; sh: 252; makefile: 33
file content (50 lines) | stat: -rwxr-xr-x 1,397 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
#!/usr/bin/make -f

include /usr/share/openstack-pkg-tools/pkgos.make

%:
	dh $@ --buildsystem=python_distutils --with python3

override_dh_clean:
	dh_clean

override_dh_auto_clean:
	python3 setup.py clean

override_dh_install:
	echo "Do nothing..."

override_dh_auto_test:
	echo "Do nothing..."

override_dh_auto_build:
	echo "Do nothing..."

override_dh_auto_install:
	pkgos-dh_auto_install --no-py2 --in-tmp

	mkdir -p $(CURDIR)/debian/tmp/etc/rally
	oslo-config-generator --output-file $(CURDIR)/debian/tmp/etc/rally/rally-openstack.conf \
		--namespace rally \
		--namespace rally_openstack \
		--namespace oslo.db \
		--namespace oslo.log

ifeq (,$(findstring nocheck, $(DEB_BUILD_OPTIONS)))
	set -e ; set -x ; for PYVER in $(PYTHON3S); do \
		PYTHONPATH=$(CURDIR)/debian/tmp/usr/lib/python3/dist-packages \
			PYTHON=python$$PYVER \
			python$$PYVER -m pytest -Wignore -Wignore::pytest.PytestCollectionWarning tests/unit ; \
	done
endif

	dh_install
	
#	rm -rf $(CURDIR)/debian/python3-rally/usr/etc
#	mv $(CURDIR)/debian/python3-rally/usr/bin $(CURDIR)/debian/rally/usr


override_dh_python3:
	dh_python3 --shebang=/usr/bin/python3
	rm -rf $(CURDIR)/debian/python3-rally-openstack/usr/share/doc/python3-rally-openstack/rally-jobs/plugins/__pycache__
	rm -rf $(CURDIR)/debian/python3-rally-openstack/usr/share/doc/python3-rally-openstack/rally-jobs/plugins/test_relative_import/__pycache__