diff --git a/debian/control b/debian/control index 160372d..71c48fe 100644 --- a/debian/control +++ b/debian/control @@ -8,6 +8,7 @@ Build-Depends: debhelper-compat (= 12), dh-golang, + help2man Build-Depends-Indep: golang-any, golang-github-miekg-dns-dev, diff --git a/debian/golang-github-dnstap-golang-dnstap-cli.manpages b/debian/golang-github-dnstap-golang-dnstap-cli.manpages new file mode 100644 index 0000000..fb3026c --- /dev/null +++ b/debian/golang-github-dnstap-golang-dnstap-cli.manpages @@ -0,0 +1 @@ +debian/dnstap.1 diff --git a/debian/rules b/debian/rules index 4983eac..71b43bc 100755 --- a/debian/rules +++ b/debian/rules @@ -1,8 +1,24 @@ #!/usr/bin/make -f + +include /usr/share/dpkg/pkg-info.mk %: dh $@ --builddirectory=_build --buildsystem=golang --with=golang +override_dh_auto_clean: + rm -f debian/dnstap.1 + dh_auto_clean + +override_dh_installman: + ls -AlR debian + help2man --version-string="$(DEB_VERSION_UPSTREAM)" \ + -n 'dnstap tool' \ + --no-discard-stderr \ + -h '-h' \ + -N \ + $(CURDIR)/debian/tmp/usr/bin/dnstap > debian/dnstap.1 + dh_installman + override_dh_auto_install: find . -name dnstap.sock -delete dh_auto_install