File: rules

package info (click to toggle)
mumble 1.5.735-6
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 90,008 kB
  • sloc: cpp: 556,921; ansic: 81,662; python: 3,606; sh: 659; makefile: 506; asm: 371; cs: 306; sql: 228; javascript: 143; perl: 80; xml: 13
file content (57 lines) | stat: -rwxr-xr-x 1,848 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
#!/usr/bin/make -f

export DH_VERBOSE=1
# Attempt to harden the build
export DEB_BUILD_MAINT_OPTIONS = hardening=+all
# Remove remove "-z,now" LDFLAGS because mumble-overlay (libmumble.so)
# needs to be able to resolve OpenGL symbols at runtime rather than linking
# to a specific libGL implementation
export DEB_LDFLAGS_MAINT_STRIP = -r,now
# NOTE: there seems to be difficulties with build hardening for packages using
#       CMake; see: https://wiki.debian.org/Hardening#Notes_for_packages_using_CMake
DEB_BUILD_NUMBER := $(shell dpkg-parsechangelog -S Version | cut -d'.' -f 3 | cut -d'-' -f 1)
# Try to set Debian hardening build flags
CMAKE_C_FLAGS := $(CFLAGS)
CMAKE_XX_FLAGS := $(CXXFLAGS)
CMAKE_SHARED_LINKER_FLAGS := $(LDFLAGS)

# qtchooser will try to use qmake from qt4 even if it's not installed
export QT_SELECT=qt5

ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
	NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
	MAKEFLAGS += -j$(NUMJOBS)
endif

export DH_OPTIONS

%:
	dh  $@ --buildsystem=cmake

override_dh_auto_configure:
	dh_auto_configure -- \
	-DBUILD_NUMBER=$(DEB_BUILD_NUMBER) \
	-DCMAKE_BUILD_TYPE=Release \
	-Dbundle-qt-translations=OFF \
	-Dbundled-gsl=OFF \
	-Dbundled-json=OFF \
	-Dbundled-renamenoise=ON \
	-Dbundled-speex=OFF \
	-Doverlay=ON \
	-Doverlay-xcompile=OFF \
	-Dsymbols=ON \
	-Dupdate=OFF \
	-Duse-pkgconf-install-paths=ON \
	-Dwarnings-as-errors=OFF

override_dh_clean:
	rm -rfv Ice
	# logratate and init file have both been removed
	#rm -fv $(CURDIR)/debian/mumble-server.logrotate $(CURDIR)/mumble-server.init
	debconf-updatepo
	dh_clean

override_dh_auto_build:
	# Create Ice HTML files and place in Ice/ directory to be installed with mumble-server.docs
	slice2html -I/usr/share/ice/slice -I/usr/share/slice src/murmur/MumbleServer.ice --output-dir Ice
	dh_auto_build