-
- dh_clean
-
-install: build
- dh_testdir
- dh_testroot
- dh_clean -k
- dh_installdirs
- $(INSTALL) -d $(PREFIX)/usr/sbin/
- $(INSTALL) -t $(PREFIX)/usr/sbin/ nscd
- $(INSTALL) -d $(PREFIX)/etc/
- $(INSTALL) -m644 -t $(PREFIX)/etc/ debian/nscd.conf
-
-binary-indep:
-
-binary-arch: build install
- dh_testdir
- dh_testroot
- dh_installchangelogs
- dh_installdocs
- dh_installman debian/nscd.8
- dh_installinit
- dh_link
- dh_strip
- dh_compress
- dh_fixperms
- dh_installdeb
- dh_shlibdeps
- dh_gencontrol
- dh_md5sums
- dh_builddeb
-
-binary: binary-arch
-.PHONY: build clean binary-arch binary-indep binary install
+ dh_auto_clean
+
+override_dh_auto_build:
+ gcc $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -o nscd nscd.c -lsystemd
+ help2man --name 'nscd which does not hang' \
+ --include debian/help2man \
+ --no-info \
+ ./nscd > debian/unscd.man
+ ln -fs unscd.man debian/nscd.man
+
+override_dh_auto_install:
+ install -d debian/unscd/usr/sbin/
+ install -t debian/unscd/usr/sbin/ nscd
+ install -d debian/unscd/etc/
+ install -m644 -t debian/unscd/etc/ debian/nscd.conf
+
+override_dh_systemd_start:
+ dh_systemd_start --restart-after-upgrade --no-stop-on-upgrade