File: rules

package info (click to toggle)
golang-k8s-sigs-kustomize-cmd-config 0.19.0%2Bds-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 964 kB
  • sloc: makefile: 198; sh: 50
file content (28 lines) | stat: -rwxr-xr-x 1,255 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
#!/usr/bin/make -f

include /usr/share/dpkg/default.mk

# Uncomment this to turn on verbose mode.
# export DH_VERBOSE=1

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

execute_after_dh_auto_configure:
	# dh_auto_configure first copies source files to the build root, then
	# symlinks libraries from /usr/share/gocode/src.
	# The dependency symlink will NOT occur when the library package uses the
	# same XS-Go-Import-Path (DH_GOPKG) as the source package and ship files
	# under the same GOPATH, causing problems in dh_auto_build due to lack of
	# installed libraries.
	# dh_auto_configure: warning: "sigs.k8s.io/kustomize" is already installed.
	# https://salsa.debian.org/go-team/packages/dh-golang/-/blob/81892fe8d3a51a22c910a649052669dd9f18837e/lib/Debian/Debhelper/Buildsystem/golang.pm#L495
	ln -vs /usr/share/gocode/src/sigs.k8s.io/kustomize/kyaml $(CURDIR)/_build/src/sigs.k8s.io/kustomize/kyaml

execute_before_dh_auto_test:
	# Remove test files that depends on docker
	find _build/src/sigs.k8s.io/kustomize/cmd/config/internal/commands/e2e -name "e2e_test.go" -delete
	find _build/src/sigs.k8s.io/kustomize/cmd/config/internal/commands/e2e -name "test_util_test.go" -delete

override_dh_auto_install:
	dh_auto_install -- --no-binaries