File: rules

package info (click to toggle)
python-openstacksdk 4.7.1-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 13,712 kB
  • sloc: python: 127,028; sh: 153; makefile: 23
file content (41 lines) | stat: -rwxr-xr-x 2,271 bytes parent folder | download | duplicates (2)
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
#!/usr/bin/make -f

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

%:
	dh $@ --buildsystem=pybuild --with python3,sphinxdoc

override_dh_auto_clean:
	rm -rf build .stestr *.egg-info
	find . -iname '*.pyc' -delete
	for i in $$(find . -type d -iname __pycache__) ; do rm -rf $$i ; done

override_dh_auto_build:
	echo "Do nothing..."

override_dh_auto_install:
	pkgos-dh_auto_install --no-py2 --in-tmp
ifeq (,$(findstring nocheck, $(DEB_BUILD_OPTIONS)))
	# Non-deterministic. See https://bugs.debian.org/1084147
	# openstack.tests.unit.identity.v3.test_proxy.TestIdentityProxyRegion.test_region_update
	# Non-deterministic: See https://bugs.debian.org/1091040
	# openstack.tests.unit.network.v2.test_proxy.TestNetworkNetworkSegment.test_network_segment_range_delete
	# Does not work with /tmp as tmpfs:
	# openstack.tests.unit.config.test_config.TestBackwardsCompatibility.test_project_password
	# Failing on bookworm backports, maybe non-deterministic:
	# network.v2.test_bgp_speaker.TestBgpSpeaker.test_add_bgp_speaker_to_dragent
	# compute.v2.test_proxy.TestCompute.test_server_group_delete_ignore
	OS_LOG_CAPTURE=true pkgos-dh_auto_test --no-py2 'openstack\.tests\.unit\.(?!(.*baremetal\.v1\.test_proxy\.TestWaitForNodesProvisionState\.test_timeout_and_failures_not_fail.*|.*config\.test_loader\.TestLoader\.test__load_yaml_json_file_without_perm.*|.*cloud.test_security_groups\.TestSecurityGroups\.test_update_security_group_bad_kwarg.*|.*cloud\.test_port\.TestPort\.test_create_port_parameters.*|.*test_stats\.TestStats\.test_servers_error.*|identity\.v3\.test_proxy\.TestIdentityProxyRegion\.test_region_update|network\.v2\.test_proxy\.TestNetworkNetworkSegment\.test_network_segment_range_delete|config\.test_config\.TestBackwardsCompatibility\.test_project_password|network\.v2\.test_bgp_speaker\.TestBgpSpeaker\.test_add_bgp_speaker_to_dragent|compute\.v2\.test_proxy\.TestCompute\.test_server_group_delete_ignore))'
endif

override_dh_auto_test:
	echo "Do nothing..."

override_dh_sphinxdoc:
ifeq (,$(findstring nodoc, $(DEB_BUILD_OPTIONS)))
	python3 -m sphinx -b html doc/source debian/python-openstacksdk-doc/usr/share/doc/python-openstacksdk-doc/html
	dh_sphinxdoc -O--buildsystem=pybuild
endif

override_dh_python3:
	dh_python3 --shebang=/usr/bin/python3