File: rules

package info (click to toggle)
device-tree-compiler 1.4.7-4
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 1,892 kB
  • sloc: ansic: 11,942; sh: 1,010; asm: 681; lex: 523; yacc: 457; python: 440; makefile: 292; perl: 74
file content (39 lines) | stat: -rwxr-xr-x 1,066 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
#!/usr/bin/make -f
# -*- makefile -*-

# reproducible builds: texlive needs FORCE_SOURCE_DATE set in order to
# respect SOURCE_DATE_EPOCH.
export FORCE_SOURCE_DATE=1

export DEB_BUILD_MAINT_OPTIONS=hardening=+all

# python library builds with warnings, temporarily disabled.
export NO_PYTHON = 1

include /usr/share/dpkg/architecture.mk
ifeq ($(origin CC),default)
export CC = $(DEB_HOST_GNU_TYPE)-gcc
endif

include /usr/share/dpkg/buildflags.mk
CFLAGS += -fPIC -Werror -Wall -Wpointer-arith -Wcast-qual	\
	-Wnested-externs -Wstrict-prototypes -Wmissing-prototypes	\
	-Wredundant-decls -Wshadow
CPPFLAGS += -I libfdt -I .

%:
	dh $@

override_dh_auto_build:
	dh_auto_build -- V=1 CFLAGS="$(CFLAGS)" CPPFLAGS="$(CPPFLAGS)"
ifeq (,$(findstring nodoc,$(DEB_BUILD_OPTIONS)))
	$(MAKE) -C Documentation
endif

override_dh_auto_install:
	$(MAKE) install DESTDIR=$(CURDIR)/debian/tmp PREFIX=/usr LIBDIR=/usr/lib/$(DEB_HOST_MULTIARCH)

override_dh_auto_clean:
	dh_auto_clean
	[ ! -f Documentation/Makefile ] || $(MAKE) -C Documentation clean
	[ ! -d build ] || rm -rf build