summaryrefslogtreecommitdiffstats
path: root/debian/rules
blob: 60e62166b14ea2b616f2ff8e7a260e5cdb47da7a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#!/usr/bin/make -f

export DH_GOLANG_INSTALL_ALL := 1
export DH_GOLANG_EXCLUDES := kms/hashivault kms/gcp kms/azure test/fuzz

%:
	dh $@ --builddirectory=_build --buildsystem=golang --with=golang

override_dh_auto_test:
# disable tests for now
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
	# make test binaries available where the tests expect them
	mkdir -p -m700 $(CURDIR)/debian/tmp-home/
	env \
	  HOME=$(CURDIR)/debian/tmp-home/.cache \
	  DH_GOLANG_EXCLUDES="$${DH_GOLANG_EXCLUDES}" \
	dh_auto_test -v --max-parallel=2 -- -tags "$(BUILDTAGS)"
	rm -rf $(CURDIR)/debian/tmp-home
endif