File: rules

package info (click to toggle)
nebula 1.10.3%2Bdfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 1,884 kB
  • sloc: makefile: 190; sh: 100
file content (22 lines) | stat: -rwxr-xr-x 615 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/usr/bin/make -f

export DEB_BUILD_MAINT_OPTIONS = hardening=+all

# Include version number
include /usr/share/dpkg/pkg-info.mk
VERSION = $(shell echo $(DEB_VERSION) | cut -d+ -f1)
LDFLAGS := '-X main.Build=$(VERSION)'

# gvisor based service library is somewhat experimental,
# see https://github.com/slackhq/nebula/pull/965
# Also, it fails on s390x
SKIP_TESTS += TestService

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

override_dh_auto_build:
	dh_auto_build --buildsystem=golang -- -ldflags $(LDFLAGS)

override_dh_auto_test:
	dh_auto_test --buildsystem=golang -- -skip "$(subst $(eval ) ,|,$(SKIP_TESTS))"