File: rules

package info (click to toggle)
gpaste 45.3-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 3,368 kB
  • sloc: ansic: 15,702; javascript: 826; sh: 75; makefile: 22
file content (29 lines) | stat: -rwxr-xr-x 895 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
#!/usr/bin/make -f
# -*- makefile -*-

export DEB_BUILD_MAINT_OPTIONS = hardening=+all
export DEB_LDFLAGS_MAINT_APPEND = -Wl,-O1 -Wl,-z,defs

CONFFLAGS := \
	-Dsystemd-user-unit-dir=/usr/lib/systemd/user \
	-Dintrospection=true \
	-Dvapi=false

%:
	dh $@

override_dh_auto_configure:
ifeq (gnome-shell-extension-gpaste,$(filter gnome-shell-extension-gpaste,$(shell dh_listpackages)))
	dh_auto_configure -- $(CONFFLAGS) \
		-Dgnome-shell=true
else
	dh_auto_configure -- $(CONFFLAGS) \
		-Dgnome-shell=false
endif

override_dh_gencontrol:
	dh_gencontrol -- \
		-Vgnome:MinimumVersion=$(shell python3 -c "import json; \
		print(min(int(x) for x in json.load(open('src/gnome-shell/metadata.json.in', 'rt'))['shell-version']))") \
		-Vgnome:MaximumVersion=$(shell python3 -c "import json; \
		print(1+max(int(x) for x in json.load(open('src/gnome-shell/metadata.json.in', 'rt'))['shell-version']))")