File: rules

package info (click to toggle)
attr 1:2.4.48-4
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, experimental, sid
  • size: 2,688 kB
  • sloc: sh: 5,090; ansic: 2,406; perl: 272; makefile: 94; sed: 16
file content (85 lines) | stat: -rwxr-xr-x 1,564 bytes parent folder | download | duplicates (2)
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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
#!/usr/bin/make -f

#export DH_VERBOSE=1

include /usr/share/dpkg/architecture.mk

DEB_BUILD_MAINT_OPTIONS = hardening=+all
DPKG_EXPORT_BUILDFLAGS = 1
include /usr/share/dpkg/buildflags.mk

ifeq ($(DEB_BUILD_GNU_TYPE), $(DEB_HOST_GNU_TYPE))
  confflags += --build=$(DEB_HOST_GNU_TYPE)
else
  confflags += --build=$(DEB_BUILD_GNU_TYPE) --host=$(DEB_HOST_GNU_TYPE)
endif

ifeq (,$(filter terse,$(DEB_BUILD_OPTIONS)))
  confflags += --disable-silent-rules
endif

config.status: configure
	dh_testdir
	dh_update_autotools_config
	dh_autoreconf
	
	./configure \
	  CPPFLAGS="$(CPPFLAGS)" \
	  CFLAGS="$(CFLAGS)" \
	  LDFLAGS="$(LDFLAGS)" \
	  $(confflags) \
	  --prefix=/usr \
	  --libdir=\$${prefix}/lib/$(DEB_HOST_MULTIARCH)

build-indep:
build-arch: config.status
	dh_testdir
	
	$(MAKE)
	
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
	$(MAKE) check VERBOSE=1 || true
endif

build: build-indep build-arch

clean:
	dh_testdir
	dh_testroot
	
	[ ! -f Makefile ] || $(MAKE) distclean
	
	dh_autoreconf_clean
	dh_clean

binary-indep:

binary-arch: build-arch
	dh_testdir
	dh_testroot
	
	dh_prep
	dh_installdirs
	
	$(MAKE) install DESTDIR=$(CURDIR)/debian/tmp
	
	dh_install
	dh_installdocs
	dh_installchangelogs doc/CHANGES
	dh_installman
	dh_link
	dh_strip
	dh_compress
	dh_fixperms
	dh_makeshlibs -N libattr1
	dh_makeshlibs -p libattr1 -V 'libattr1 (>= 1:2.4.48)' --add-udeb libattr1-udeb
	dh_installdeb
	dh_shlibdeps
	dh_gencontrol
	
	dh_md5sums
	dh_builddeb

binary: binary-indep binary-arch

.PHONY: build-arch build-indep build binary-arch binary-indep binary clean