File: rules

package info (click to toggle)
meson 0.49.2-1
  • links: PTS
  • area: main
  • in suites: buster
  • size: 11,976 kB
  • sloc: python: 37,917; ansic: 5,005; cpp: 870; f90: 173; asm: 120; sh: 90; java: 69; cs: 54; xml: 48; makefile: 23; objc: 21; lisp: 20; lex: 8; fortran: 5; yacc: 5
file content (40 lines) | stat: -rwxr-xr-x 1,207 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
#!/usr/bin/make -f

# Print all logging info to stdout so it
# shows up in build logs.
export MESON_PRINT_TEST_OUTPUT=1

export QT_SELECT=qt5

# We're not in 1963 anymore, Toto!
export LC_ALL=C.UTF-8

export PYBUILD_NAME=meson

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

ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
override_dh_auto_test:
	./run_tests.py
endif

override_dh_clean:
	dh_clean
	rm -f meson-test-run.txt meson-test-run.xml
	rm -rf __pycache__
	rm -rf mesonbuild/__pycache__
	rm -rf mesonbuild/*/__pycache__

override_dh_install:
# Helper script to autogenerate cross files.
	dh_install
	mkdir -p $$(pwd)/debian/meson/usr/share/meson
	cp debian/debcrossgen $$(pwd)/debian/meson/usr/share/meson
	rm -rf $$(pwd)/debian/meson/usr/lib/python*/dist-packages/mesonbuild/__pycache__
	rm -rf $$(pwd)/debian/meson/usr/lib/python*/dist-packages/mesonbuild/*/__pycache__
# For some reason Debian helpers install the files in the wrong directory,
# i.e. /usr/lib/python3.6 instead of /usr/lib/python3. I don't know why
# or how to fix it, since we just call to the default tools with default
# parameters. Fix manually.
	mv $$(pwd)/debian/meson/usr/lib/python3.* $$(pwd)/debian/meson/usr/lib/python3