Debian Codegraph @

debian/rules

raw
1 #!/usr/bin/make -f
2
3 # Taken from the pygobject packaging.
4 PY3VERS := $(shell py3versions -r)
5
6 include /usr/share/dpkg/architecture.mk
7
8 export DEB_BUILD_MAINT_OPTIONS = hardening=+all
9 ifneq ($(DEB_BUILD_ARCH),$(DEB_HOST_ARCH))
10 export _PYTHON_SYSCONFIGDATA_NAME=_sysconfigdata__$(DEB_HOST_MULTIARCH)
11 endif
12
13 %:
14 dh $@
15
16 override_dh_auto_clean:
17 set -e ; for pyver in $(PY3VERS); do \
18 rm -fr build-$$pyver ; \
19 done
20 dh_auto_clean
21
22 override_dh_auto_configure:
23 set -e ; for pyver in $(PY3VERS); do \
24 mkdir -p build-$$pyver; \
25 PYTHON=/usr/bin/$$pyver dh_auto_configure -B build-$$pyver -- --includedir=\$${prefix}/include/$(DEB_HOST_MULTIARCH) ; \
26 done
27
28 override_dh_auto_build:
29 set -e ; for pyver in $(PY3VERS); do \
30 dh_auto_build -B build-$$pyver ; \
31 done
32
33 override_dh_auto_test:
34 set -e ; for pyver in $(PY3VERS); do \
35 dh_auto_test -B build-$$pyver ; \
36 done
37
38 override_dh_auto_install:
39 set -e ; for pyver in $(PY3VERS); do \
40 dh_auto_install -B build-$$pyver ; \
41 done
42 for file in $$(find debian/tmp/usr/lib/ -name "*.la" -o -name _sphinxbase.a); do \
43 rm $$file ; \
44 done
45 # sphinx_config.h is installed alongside the other header files. Make sure
46 # it can be found.
47 # https://bugs.launchpad.net/ubuntu/+bug/1648877
48 sed --in-place s#sphinx_config\.h#sphinxbase/sphinx_config.h# \
49 debian/tmp/usr/include/*/sphinxbase/ad.h \
50 debian/tmp/usr/include/*/sphinxbase/prim_type.h \
51 debian/tmp/usr/include/*/sphinxbase/sbthread.h