File: rules

package info (click to toggle)
golang-github-containers-buildah 1.39.3%2Bds1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 7,724 kB
  • sloc: sh: 2,398; makefile: 236; perl: 187; asm: 16; awk: 12; ansic: 1
file content (36 lines) | stat: -rwxr-xr-x 1,263 bytes parent folder | download
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
#!/usr/bin/make -f

# probably not suitable tests for running as part of package build
DH_GOLANG_EXCLUDES := \
	github.com/containers/buildah/tests/e2e \
	github.com/containers/buildah/tests/conformance

# TODO: fails finding some Containerfiles, not sure what's going wrong
DH_GOLANG_EXCLUDES += github.com/containers/buildah/pkg/util

# TOOD: builds and runs a helper utility during the tests, find out how
# to make this work during the package build
DH_GOLANG_EXCLUDES += github.com/containers/buildah/chroot

# cf. https://github.com/containers/buildah/issues/5713
ifneq (,$(filter $(DEB_HOST_ARCH), s390x))
DH_GOLANG_EXCLUDES += github.com/containers/buildah/internal/mkcw
endif

export DH_GOLANG_EXCLUDES
export DH_GOLANG_INSTALL_EXTRA := $(wildcard internal/mkcw/embed/*) $(wildcard tests/*.json)

override_dh_auto_build: $(MANPAGES) $(MANPAGES5)
	dh_auto_build -- -tags "seccomp selinux apparmor libsubid"
	make -C docs docs GOMD2MAN=go-md2man
	make -C docs install PREFIX=/usr DESTDIR=$(CURDIR)/debian/tmp

override_dh_auto_test:
	mkdir -p -m700 $(CURDIR)/debian/tmp-home/.cache
	env \
		HOME=$(CURDIR)/debian/tmp-home/.cache \
	dh_auto_test
	rm -rfv debian/tmp-home

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