File: rules

package info (click to toggle)
fssync 1.6-1.1
  • links: PTS
  • area: main
  • in suites: bookworm, bullseye, sid
  • size: 176 kB
  • sloc: python: 1,468; makefile: 27
file content (20 lines) | stat: -rwxr-xr-x 588 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
#!/usr/bin/make -f
# -*- makefile -*-
#export DH_VERBOSE=1

PKD  = $(abspath $(dir $(MAKEFILE_LIST)))
PKG  = $(word 2, $(shell dpkg-parsechangelog -l$(PKD)/changelog))
UVER = $(shell dpkg-parsechangelog -l$(PKD)/changelog | \
               sed -nr 's/^Version: (.*:)?(.*)-(.*)/\2/p')

.PHONY: get-orig-source
get-orig-source: $(PKG)_$(UVER).orig.tar.xz
$(PKG)_$(UVER).orig.tar.xz:
	set $(PKG)-$(UVER)/; (cd $(PKD)/.. && git archive --format=tar \
	--prefix=$$1 HEAD) | tar --delete $$1debian/ $$1.gitignore | xz > $@

%:
	dh $@

override_dh_auto_install:
	dh_auto_install -- PREFIX=/usr