File: rules

package info (click to toggle)
gb 0.4.2-2
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 936 kB
  • ctags: 903
  • sloc: makefile: 12; cpp: 12; sh: 3
file content (21 lines) | stat: -rwxr-xr-x 766 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
#!/usr/bin/make -f

pristine-testdata:
	rsync -a --delete testdata/ '$(CURDIR)/obj-$(DEB_BUILD_GNU_TYPE)/src/github.com/constabulary/gb/testdata/'
	rsync -a --delete fileutils/_testdata/ '$(CURDIR)/obj-$(DEB_BUILD_GNU_TYPE)/src/github.com/constabulary/gb/fileutils/_testdata/'
	rsync -a --delete vendor/_testdata/ '$(CURDIR)/obj-$(DEB_BUILD_GNU_TYPE)/src/github.com/constabulary/gb/vendor/_testdata/'

override_dh_auto_test:
	./debian/rules pristine-testdata
	
	# some tests need network access (gated by -short), so we run those only via DEP8
	dh_auto_test -- -short

override_dh_auto_install:
	# re-copy pristine testdata so we delete garbage created by build/test
	./debian/rules pristine-testdata
	
	dh_auto_install

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