File: rules

package info (click to toggle)
daemontools 1%3A0.76-14
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 1,296 kB
  • sloc: ansic: 3,800; sh: 464; makefile: 391
file content (32 lines) | stat: -rwxr-xr-x 921 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
#!/usr/bin/make -f

#export DH_VERBOSE=1

export DEB_BUILD_MAINT_OPTIONS = hardening=+all

DIR=daemontools-0.76

override_dh_auto_build:
	# create compile directory
	mkdir -p '$(DIR)/compile/debian'
	# svscanboot.sh: /command/svc -> svc, /service -> /etc/service
	sed -e 's}/command/svc}svc};s}/service}/etc/service}g' < '$(DIR)/src/svscanboot.sh' > '$(DIR)/compile/debian/svscanboot.sh'
	cd '$(DIR)/compile' && ln -s debian/svscanboot.sh svscanboot.sh
	# debian CFLAGS + CPPFLAGS
	echo '$(CC) $(CFLAGS) $(CPPFLAGS)' > '$(DIR)/compile/debian/conf-cc'
	cd '$(DIR)/compile' && ln -s debian/conf-cc conf-cc
	# debian LDFLAGS
	echo '$(CC) $(LDFLAGS)' > '$(DIR)/compile/debian/conf-ld'
	cd '$(DIR)/compile' && ln -s debian/conf-ld conf-ld
	# build
	cd '$(DIR)' && package/compile
	# print sysdeps
	cat $(DIR)/compile/sysdeps

override_dh_auto_clean:
	dh_auto_clean
	rm -rf '$(DIR)/compile'
	rm -rf '$(DIR)/command'

%:
	dh $@