1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
|
#!/usr/bin/make -f
export CGO_ENABLED := 0
DH_GOPKG := github.com/micromdm/scep
include /usr/share/dpkg/pkg-info.mk
VERSION = $(shell echo $(DEB_VERSION) | cut -d- -f1)
LDFLAGS := -ldflags '-X "main.version=$(VERSION)"'
%:
dh $@ --builddirectory=_build --buildsystem=golang --with=golang
override_dh_auto_build:
dh_auto_build -- $(LDFLAGS)
override_dh_install-indep:
find debian/tmp/usr/share/gocode/src/$(DH_GOPKG)/scep/testdata/ \
-type f -exec chmod -x \{\} \;
rm -rf debian/tmp/usr/share/gocode/src/$(DH_GOPKG)/cmd
dh_install -i
|