File: rules

package info (click to toggle)
policykit-1 126-2
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 2,584 kB
  • sloc: ansic: 19,434; xml: 3,606; sh: 534; python: 111; javascript: 83; makefile: 48; exp: 37; perl: 11
file content (66 lines) | stat: -rwxr-xr-x 1,600 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
#!/usr/bin/make -f
# -*- makefile -*-

export DEB_BUILD_MAINT_OPTIONS = hardening=+bindnow

include /usr/share/dpkg/default.mk
include /usr/share/debhelper/dh_package_notes/package-notes.mk

built_binaries := $(shell dh_listpackages)

%:
	dh $@ --with xml-core

DPKG_GENSYMBOLS_CHECK_LEVEL=4
export DPKG_GENSYMBOLS_CHECK_LEVEL

configure_flags =
compat_configure_flags =

ifeq ($(filter %-doc,$(built_binaries)),)
configure_flags += -Dgtk_doc=false
else
configure_flags += -Dgtk_doc=true
endif

ifeq (linux,$(DEB_HOST_ARCH_OS))
configure_flags += -Dsession_tracking=logind
else
configure_flags += -Dsession_tracking=ConsoleKit
endif

ifneq ($(DEB_BUILD_ARCH),$(DEB_HOST_ARCH))
configure_flags += --cross-file=$(DEB_HOST_GNU_TYPE)-gobject-introspection.ini
endif

override_dh_auto_configure:
	dh_auto_configure -- \
		-Dexamples=false \
		-Dintrospection=true \
		-Dman=true \
		-Dtests=true \
		-Dgettext=true \
		-Dos_type=debian \
		-Dprivileged_group=sudo \
		$(configure_flags)

override_dh_auto_test:
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
	# on buildds we can't rely on actually having a system bus
	dbus-run-session -- \
		sh -euc 'export DBUS_SYSTEM_BUS_ADDRESS="$$DBUS_SESSION_BUS_ADDRESS"; exec "$$@"' \
		sh \
		dh_auto_test \
		-- \
		$(NULL)
endif

execute_before_dh_install:
	# on Debian use sudo group; on Ubuntu, also allow the admin group for
	# historical reasons
	if dpkg-vendor --is ubuntu; then \
		install -m644 debian/49-ubuntu-admin.rules debian/tmp/usr/share/polkit-1/rules.d/; \
	fi

override_dh_installsystemd:
	dh_installsystemd --no-start --restart-after-upgrade