summaryrefslogtreecommitdiffstats
path: root/debian/rules
blob: 0178d2fe531c840fcab5c985a4e929fb5702533b (plain)
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
#!/usr/bin/make -f

export DEB_BUILD_MAINT_OPTIONS = hardening=+all

%:
	dh $@

override_dh_auto_configure:
	dh_auto_configure --builddir=build-deb
	dh_auto_configure --builddir=build-udeb -- --disable-gssapi

override_dh_auto_build:
	dh_auto_build --builddir=build-deb
	dh_auto_build --builddir=build-udeb

override_dh_auto_install:
	dh_auto_install --builddir=build-deb
	dh_auto_install --builddir=build-udeb

override_dh_auto_install:
	dh_auto_install --builddir=build-deb
	dh_auto_install --builddir=build-udeb --destdir=debian/tmp-udeb

DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
override_dh_install:
	# Move libtirpc.so.* to /lib
	mkdir -p debian/tmp/lib/$(DEB_HOST_MULTIARCH)
	mv debian/tmp/usr/lib/*/libtirpc.so.* debian/tmp/lib/$(DEB_HOST_MULTIARCH)

	# Fix up the -dev symlink
	LINKTARGET=`readlink debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH)/libtirpc.so`; \
	ln -sf /lib/$(DEB_HOST_MULTIARCH)/$$LINKTARGET debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH)/libtirpc.so

	dh_install -Nlibtirpc3-udeb
	dh_install -plibtirpc3-udeb --sourcedir=debian/tmp-udeb

override_dh_auto_clean:
	rm -rf build-deb build-udeb
	rm -rf debian/tmp-udeb