| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
DPKG_EXPORT_BUILDFLAGS = 1 |
| 8 |
include /usr/share/dpkg/buildflags.mk |
| 9 |
CFLAGS+=$(CPPFLAGS) |
| 10 |
CXXFLAGS+=$(CPPFLAGS) |
| 11 |
|
| 12 |
export DEB_BUILD_MAINT_OPTIONS = hardening=+all |
| 13 |
|
| 14 |
ifeq (linux,$(DEB_HOST_ARCH_OS)) |
| 15 |
|
| 16 |
CONFIGURE_EXTRA_FLAGS += --with-systemdsystemunitdir=/unused |
| 17 |
else |
| 18 |
CONFIGURE_EXTRA_FLAGS += --with-systemdsystemunitdir=no |
| 19 |
endif |
| 20 |
|
| 21 |
%: |
| 22 |
dh $@ |
| 23 |
|
| 24 |
override_dh_auto_configure: |
| 25 |
dh_auto_configure -- --enable-warmstarts --enable-libwrap --with-statedir=/run/rpcbind --with-rpcuser=_rpc --enable-debug $(CONFIGURE_EXTRA_FLAGS) |
| 26 |
|
| 27 |
execute_after_dh_auto_install: |
| 28 |
rm -Rf debian/rpcbind/unused |
| 29 |
|
| 30 |
override_dh_installinit: |
| 31 |
dh_installinit |
| 32 |
install -d debian/rpcbind/etc/insserv.conf.d |
| 33 |
cp debian/insserv.conf debian/rpcbind/etc/insserv.conf.d/rpcbind |
| 34 |
|
| 35 |
override_dh_installsystemd: |
| 36 |
dh_installsystemd --no-restart-after-upgrade |
| 37 |
|
| 38 |
ifeq (linux,$(DEB_HOST_ARCH_OS)) |
| 39 |
execute_before_dh_link: |
| 40 |
dh_link $$(test -d debian/rpcbind/usr/lib/systemd && echo usr/)lib/systemd/system/rpcbind.service $$(test -d debian/rpcbind/usr/lib/systemd && echo usr/)lib/systemd/system/portmap.service |
| 41 |
endif |