File: rules

package info (click to toggle)
libdeflate 1.23-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,072 kB
  • sloc: ansic: 11,716; sh: 1,388; python: 169; makefile: 31
file content (42 lines) | stat: -rwxr-xr-x 1,201 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
#!/usr/bin/make -f

export LC_ALL=C.UTF-8

export DEB_BUILD_MAINT_OPTIONS=hardening=+all

ifeq (alpha,$(DEB_HOST_ARCH))
	export DEB_CFLAGS_MAINT_APPEND=-O1
endif


%:
	dh $@

ifneq ($(filter nocheck,$(DEB_BUILD_OPTIONS)),)
 test := OFF
else
 test := ON
endif

# -DCMAKE_BUILD_RPATH_USE_ORIGIN=ON can be dropped with debhelper compat 14+
override_dh_auto_configure:
	dh_auto_configure -- \
		-DLIBDEFLATE_USE_SHARED_LIB=ON \
		-DLIBDEFLATE_BUILD_TESTS=$(test) \
		-DCMAKE_BUILD_RPATH_USE_ORIGIN=ON

execute_after_dh_auto_test:
	scripts/run_tests.sh regular

override_dh_installman:
ifeq ($(filter nodoc cross,$(DEB_BUILD_OPTIONS) $(DEB_BUILD_PROFILES)),)
	LD_LIBRARY_PATH=$(CURDIR)/debian/libdeflate0/usr/lib/$(DEB_HOST_MULTIARCH) \
		help2man --no-info --help-option=-h --version-option=-V \
		-n "Compress the specified FILEs" \
		debian/libdeflate-tools/usr/bin/libdeflate-gzip --output debian/libdeflate-gzip.1
	LD_LIBRARY_PATH=$(CURDIR)/debian/libdeflate0/usr/lib/$(DEB_HOST_MULTIARCH) \
		help2man --no-info --help-option=-h --version-option=-V \
		-n "Decompress the specified FILEs" \
		debian/libdeflate-tools/usr/bin/libdeflate-gunzip --output debian/libdeflate-gunzip.1
	dh_installman
endif