File: rules

package info (click to toggle)
ioquake3 1.36+u20190529.350b8f9~dfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, sid
  • size: 14,704 kB
  • sloc: ansic: 205,858; makefile: 2,565; sh: 1,250; asm: 702; objc: 131; xml: 31
file content (93 lines) | stat: -rwxr-xr-x 2,539 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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
#!/usr/bin/make -f
#export DH_VERBOSE=1

export DEB_BUILD_MAINT_OPTIONS=hardening=+all
export LC_ALL=C.UTF-8
export TZ=UTC

DEB_CPPFLAGS_MAINT_APPEND := \
	-DWITH_OPENARENA \
	$(NULL)

DEB_CFLAGS_MAINT_APPEND := \
	-fsigned-char \
	$(NULL)

include /usr/share/dpkg/default.mk

%:
	dh $@

ifeq (,$(filter noopt,$(DEB_BUILD_OPTIONS)))
TARGET = release
else
TARGET = debug
endif

OPTIONS = \
	BUILD_DIR=debian/build \
	USE_CODEC_OPUS=1 \
	USE_CODEC_VORBIS=1 \
	USE_CURL=1 \
	USE_CURL_DLOPEN=0 \
	USE_INTERNAL_LIBS=0 \
	USE_LOCAL_HEADERS=0 \
	USE_OPENAL=1 \
	USE_OPENAL_DLOPEN=0 \
	USE_VOIP=1 \
	$(shell $(CURDIR)/debian/q3arch make ${DEB_HOST_GNU_CPU} ${DEB_HOST_GNU_SYSTEM}) \
	$(shell $(CURDIR)/debian/q3arch make-build ${DEB_BUILD_GNU_CPU} ${DEB_BUILD_GNU_SYSTEM}) \
	BUILD_CLIENT_SMP=1 \
	BUILD_GAME_SO=1 \
	BUILD_GAME_QVM=0 \
	VERSION=$(DEB_VERSION)/$(DEB_VENDOR) \
	CFLAGS='$(filter-out -fPIE -pie,$(CFLAGS)) $(CPPFLAGS)' \
	NOTSHLIBCFLAGS='$(filter -fPIE -pie,$(CFLAGS))' \
	LDFLAGS='$(filter-out -fPIE -pie,$(LDFLAGS))' \
	NOTSHLIBLDFLAGS='$(filter -fPIE -pie,$(LDFLAGS))' \
	FULLBINEXT="" \
	NO_STRIP=1 \
	PKG_CONFIG=${DEB_HOST_GNU_TYPE}-pkg-config \
	$(NULL)

ifeq ($(DH_QUIET),1)
	OPTIONS += V=0
else
	OPTIONS += V=1
endif

ifeq ($(DEB_HOST_ARCH),powerpcspe)
OPTIONS += ALTIVEC_CFLAGS=
endif

override_dh_auto_clean:
	dh_auto_clean -- $(OPTIONS)

override_dh_auto_build:
	dh_auto_build -- $(OPTIONS) $(TARGET)

override_dh_auto_install: DESTDIR = debian/tmp
override_dh_auto_install:
	install -d $(DESTDIR)/usr/lib/ioquake3/baseq3/
	$(MAKE) copyfiles $(OPTIONS) COPYDIR=$(DESTDIR)/usr/lib/ioquake3
	install -m644 README.md debian/build/README
	install -d $(DESTDIR)/usr/lib/quake3/base/baseq3/
	install -d $(DESTDIR)/usr/lib/quake3/demo/demoq3/
	install -d $(DESTDIR)/usr/lib/quake3/ta/baseq3/
	install -d $(DESTDIR)/usr/lib/quake3/ta/missionpack/
	cd $(DESTDIR)/usr/lib/quake3/base/baseq3 && ln -s ../../../ioquake3/baseq3/*.so .
	cd $(DESTDIR)/usr/lib/quake3/demo/demoq3 && ln -s ../../../ioquake3/baseq3/*.so .
	cd $(DESTDIR)/usr/lib/quake3/ta/baseq3 && ln -s ../../../ioquake3/baseq3/*.so .
	cd $(DESTDIR)/usr/lib/quake3/ta/missionpack && ln -s ../../../ioquake3/missionpack/*.so .

ifeq ($(filter pkg.flatpak.app,$(DEB_BUILD_PROFILES)),)
ifeq ($(DEB_HOST_ARCH_OS),linux)
override_dh_install-arch:
	dh_install -a
	dh_apparmor -pioquake3 --profile-name=usr.lib.ioquake3.ioquake3
	dh_apparmor -pioquake3-server --profile-name=usr.lib.ioquake3.ioq3ded
endif
endif

override_dh_installchangelogs:
	dh_installchangelogs -XChangeLog