File: rules

package info (click to toggle)
nsd3 3.2.5-1.squeeze2
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 3,160 kB
  • ctags: 3,534
  • sloc: ansic: 21,814; python: 2,085; yacc: 1,368; makefile: 583; sh: 278
file content (44 lines) | stat: -rwxr-xr-x 1,377 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
43
44
#!/usr/bin/make -f

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

export DEB_BUILD_HARDENING=1

CFLAGS=-Wall -Wextra -g $(if $(findstring noopt,$(DEB_BUILD_OPTIONS)),-O0,-O2)
CPPFLAGS=-D_XOPEN_SOURCE=600 

srcpkg = $(shell dpkg-parsechangelog | sed -ne 's/Source: *//p')
srcver = $(shell dpkg-parsechangelog | sed -ne 's/Version: *\(.*:\)\?\(.*\)-[0-9.]*$$/\2/p')
#{{{ generic rules

../$(srcpkg)_$(srcver).orig.tar.gz:
	@! git rev-parse --git-dir >/dev/null 2>&1 || pristine-tar checkout $@

check-tarball: ../$(srcpkg)_$(srcver).orig.tar.gz

.PHONY: check-tarball

#}}}

%:
	dh --with quilt $@

override_dh_auto_configure:
	CFLAGS="$(CFLAGS)" CPPFLAGS="$(CPPFLAGS)" dh_auto_configure -- \
	       --with-configdir=/etc/nsd3                     \
	       --with-nsd_conf_file=/etc/nsd3/nsd.conf        \
	       --with-pidfile=/var/run/nsd3/nsd.pid           \
	       --with-dbfile=/var/lib/nsd3/nsd.db             \
	       --with-zonesdir=/etc/nsd3                      \
	       --with-difffile=/var/lib/nsd3/ixfr.db          \
	       --with-xfrdfile=/var/lib/nsd3/xfrd.state       \
	       \
	       --disable-largefile                            \
	       --enable-root-server                           \
	       --enable-mmap

override_dh_auto_install:
	dh_auto_install
	rmdir $(CURDIR)/debian/nsd3/var/run/nsd3
	rmdir $(CURDIR)/debian/nsd3/var/run