File: rules

package info (click to toggle)
herrie 2.2-2
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 640 kB
  • ctags: 550
  • sloc: ansic: 5,743; sh: 377; makefile: 14
file content (22 lines) | stat: -rwxr-xr-x 605 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
#!/usr/bin/make -f
# -*- makefile -*-

CFLAGS = -Wall -g

ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
	CFLAGS += -O0
else
	CFLAGS += -O2
endif

%:
	dh $@

override_dh_auto_configure:
	PREFIX="/usr" CONFDIR="/etc" MANDIR="/usr/share/man" CFLAGS="$(CFLAGS)" LDFLAGS="-Wl,-as-needed,-z,defs" ./configure

override_dh_auto_install:
	DESTDIR="$(CURDIR)/debian/herrie" $(MAKE) install
	# Transform config sample into commented out config file
	sed 's|^[^#]|#&|' $(CURDIR)/debian/herrie/etc/herrie.conf.sample > $(CURDIR)/debian/herrie/etc/herrie.conf
	rm -f $(CURDIR)/debian/herrie/etc/herrie.conf.sample