File: rules

package info (click to toggle)
game-data-packager 87
  • links: PTS, VCS
  • area: contrib
  • in suites: sid
  • size: 33,392 kB
  • sloc: python: 15,387; sh: 704; ansic: 95; makefile: 50
file content (67 lines) | stat: -rwxr-xr-x 2,149 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
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
#!/usr/bin/make -f
# GNU copyright 1997 to 1999 by Joey Hess.

#export DH_VERBOSE=1
export DEB_BUILD_MAINT_OPTIONS = hardening=+all
export DH_OPTIONS

include /usr/share/dpkg/pkg-info.mk

%:
	mkdir -p $(HOME)
	dh $@ --with bash-completion --buildsystem=meson

# Redirect Inkscape log files, etc. to a temporary directory
export HOME = $(CURDIR)/debian/temp-home
export XDG_CACHE_HOME = $(CURDIR)/debian/temp-home/.cache
export XDG_CONFIG_HOME = $(CURDIR)/debian/temp-home/.config
export XDG_DATA_HOME = $(CURDIR)/debian/temp-home/.local/share
# Disable tests that are not appropriate at build-time
export DEB_BUILD_TIME_TESTS = 1

override_dh_auto_configure:
	dh_auto_configure \
		-- \
		--bindir=games \
		-Dgamedatadir=share/games \
		$(NULL)

# Inkscape expects an X11 or Wayland display
override_dh_auto_build:
	xvfb-run -a -s "-screen 0 1024x768x24" dh_auto_build

execute_after_dh_auto_clean:
	@if [ "`echo *.deb`" != "*.deb" ]; then \
		echo; \
		echo "*************************************************"; \
		echo "Cannot create source package with these here:"; \
		ls *.deb; \
		echo "*************************************************"; \
		echo; \
		exit 1; \
	fi
	debian/copyright.py

execute_after_dh_install:
	if dpkg-vendor --derives-from Ubuntu; then \
		install -d debian/game-data-packager/usr/share/games/game-data-packager; \
		touch debian/game-data-packager/usr/share/games/game-data-packager/is-ubuntu-derived; \
	fi
	dh_apparmor -pgame-data-packager-runtime --profile-name=usr.lib.unreal
	dh_apparmor -pquake4 --profile-name=usr.lib.quake4.quake4.x86
	dh_apparmor -pquake4-server --profile-name=usr.lib.quake4.q4ded.x86

override_dh_installdocs:
	dh_installdocs -XTODO

override_dh_installsystemd:
	dh_installsystemd -pquake4-server --no-enable --no-start
	dh_installsystemd -petqw-server --no-enable --no-start
	dh_installsystemd --remaining-packages

execute_after_dh_python3:
	dh_python3 -pquake-server /usr/share/games/quake
	dh_python3 -pquake2-server /usr/share/games/quake2
	dh_python3 -pquake3-server /usr/share/games/quake3
	dh_python3 -pquake4-server /usr/share/games/quake4
	dh_python3 -petqw-server /usr/lib/etqw