File: rules

package info (click to toggle)
performous 1.3.1%2Bds-3
  • links: PTS, VCS
  • area: main
  • in suites: forky
  • size: 63,336 kB
  • sloc: cpp: 35,855; sh: 927; python: 631; xml: 480; makefile: 37
file content (49 lines) | stat: -rwxr-xr-x 1,487 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
#!/usr/bin/make -f

ifeq (,$(filter terse,${DEB_BUILD_OPTIONS}))
export DH_VERBOSE=1
export V=1
export VERBOSE=1
endif

LC_ALL:=C.UTF-8
export LC_ALL

include /usr/share/dpkg/architecture.mk

OUR_CPPFLAGS:=
OUR_CXXFLAGS:=
OUR_LDFLAGS:=	-Wl,--as-needed

# needed so top-level exceptions are displayed as fatal errors for users
OUR_CPPFLAGS+=	-DNDEBUG

ifneq (,$(filter ${DEB_HOST_ARCH},armel m68k mips mipsel powerpc powerpcspe sh4))
OUR_LDFLAGS+=	-Wl,--start-group -latomic
endif

export DEB_BUILD_MAINT_OPTIONS := hardening=+all
export DEB_CPPFLAGS_MAINT_APPEND := ${OUR_CPPFLAGS}
export DEB_CXXFLAGS_MAINT_APPEND := ${OUR_CXXFLAGS}
export DEB_LDFLAGS_MAINT_APPEND := ${OUR_LDFLAGS}

%:
	dh $@

override_dh_auto_configure:
	dh_auto_configure -- \
		-DCMAKE_VERBOSE_MAKEFILE=ON \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DBUILD_TESTS=$(if $(filter nocheck,$(DEB_BUILD_OPTIONS)),OFF,ON) \
		-DCMAKE_POLICY_VERSION_MINIMUM=3.5

execute_after_dh_install:
	mkdir -p debian/performous/usr/games
	mv debian/performous/usr/bin/performous debian/performous/usr/games/
	rmdir --ignore-fail-on-non-empty debian/performous/usr/bin
	mkdir -p debian/performous/usr/share/icons/hicolor/scalable/apps
	cp -a debian/performous/usr/share/games/performous/themes/default/icon.svg \
		debian/performous/usr/share/icons/hicolor/scalable/apps/performous.svg
	mkdir -p debian/performous/usr/share/man/man6
	mv debian/performous/usr/share/man/performous.6.gz \
		debian/performous/usr/share/man/man6/performous.6.gz