Debian Codegraph @

debian/rules

raw
1 #!/usr/bin/make -f
2
3 export DH_VERBOSE = 1
4 include /usr/share/dpkg/pkg-info.mk
5
6 # The tarball source does not include the upstream version, so let's
7 # get it from the source package and inject it at build time
8 # (see packages gdu and golang-github-micromdm-scep for similar)
9 #
10 export CGO_ENABLED := 0
11
12 VERSION = $(DEB_VERSION_UPSTREAM)
13 GO_LDFLAGS := -ldflags '-X "main.gVersion=$(VERSION)"'
14
15 export DH_GOLANG_INSTALL_EXTRA := doc.txt etc/ruler.default
16
17 %:
18 dh $@
19
20 override_dh_auto_build:
21 dh_auto_build -- $(GO_LDFLAGS)
22
23 override_dh_auto_install:
24 dh_auto_install -- --no-source
25 # Install completions
26 install -D -m644 $(CURDIR)/etc/lf.bash \
27 $(CURDIR)/debian/lf/usr/share/bash-completion/completions/lf
28 install -D -m644 $(CURDIR)/etc/lf.zsh \
29 $(CURDIR)/debian/lf/usr/share/zsh/vendor-completions/_lf
30 install -D -m644 $(CURDIR)/etc/lf.fish \
31 $(CURDIR)/debian/lf/usr/share/fish/vendor_completions.d/lf.fish