rules 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. #!/usr/bin/make -f
  2. ifeq ($(SOURCE_DATE_EPOCH),)
  3. # workaround until SOURCE_DATE_EPOCH is available
  4. $(info SOURCE_DATE_EPOCH is not set, using changelog date instead)
  5. export CFLAGS += -DBIRTHDATE=$(shell date --date="$$(dpkg-parsechangelog --count 1 --show-field Date)" +%s)
  6. else
  7. export CFLAGS += -DBIRTHDATE=$(SOURCE_DATE_EPOCH)
  8. endif
  9. override_dh_auto_configure:
  10. dh_auto_configure -- \
  11. --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) \
  12. --prefix=/usr \
  13. --mandir=\$${prefix}/share/man \
  14. --infodir=\$${prefix}/share/info \
  15. --sysconfdir=/etc/ngircd \
  16. --with-gnutls \
  17. --with-ident \
  18. --with-pam \
  19. --enable-ipv6
  20. override_dh_auto_install:
  21. dh_auto_install
  22. # install config and sample motd file
  23. install -m 640 -D $(CURDIR)/debian/ngircd.conf \
  24. $(CURDIR)/debian/ngircd/etc/ngircd/ngircd.conf
  25. install -m 640 -D $(CURDIR)/debian/ngircd.motd \
  26. $(CURDIR)/debian/ngircd/etc/ngircd/ngircd.motd
  27. # make lintian happy
  28. rm $(CURDIR)/debian/ngircd/usr/share/doc/ngircd/COPYING
  29. mv $(CURDIR)/debian/ngircd/usr/share/doc/ngircd/ChangeLog \
  30. $(CURDIR)/debian/ngircd/usr/share/doc/ngircd/changelog
  31. override_dh_compress:
  32. dh_compress -XCommands.txt
  33. %:
  34. dh $@ --with systemd