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 33 34 35 36 37 38 39 40
|
#!/usr/bin/make -f
include /usr/share/dpkg/pkg-info.mk # DEB_VERSION
export DH_GOLANG_EXCLUDES := docs/cli docs/sandbox
%:
dh $@ --builddirectory=_build --buildsystem=golang
# For some reason Go's testing.Tempdir() doesn't find a suitable
# temporary directory in some debci/autopkgtest environments, and
# instead default to /tmp which doesn't always exists.
# === RUN TestRemoveRule
# targets_test.go:379: failed to run command /usr/bin/ssh-keygen -m rfc4716 -e -f /tmp/TestRemoveRule-1dfa01853253dae5bd29526a195910359a81799f6d3a66a3606d6e7d0642cd6c: exit status 255 ssh-keygen: /tmp/TestRemoveRule-1dfa01853253dae5bd29526a195910359a81799f6d3a66a3606d6e7d0642cd6c: No such file or directory
# --- FAIL: TestRemoveRule (0.00s)
override_dh_auto_test:
mkdir -pv $(CURDIR)/debian/gotmp
env GOTMPDIR=$(CURDIR)/debian/gotmp TMPDIR=$(CURDIR)/debian/gotmp \
dh_auto_test
rm -rfv $(CURDIR)/debian/gotmp
B = $(CURDIR)/debian/tmp/usr/bin
M = $(CURDIR)/debian/tmp/usr/share/man/man1
ifeq (,$(filter nodoc,$(DEB_BUILD_PROFILES)))
execute_before_dh_installman-arch:
mkdir -pv $(M)
env PATH=$(PATH):$(B) \
help2man --version-string="$(DEB_VERSION)" \
--no-info \
--name="security layer for git(1) repositories" \
--output $(M)/gittuf.1 \
gittuf
env PATH=$(PATH):$(B) \
help2man --version-string="$(DEB_VERSION)" \
--no-info --no-discard-stderr \
--name="gittuf remote plugin for git" \
--output $(M)/git-remote-gittuf.1 \
git-remote-gittuf
endif
|