File: rules

package info (click to toggle)
minidjvu 0.8.svn.2010.05.06+dfsg-5
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd, stretch
  • size: 2,372 kB
  • ctags: 1,082
  • sloc: sh: 9,230; ansic: 5,788; cpp: 2,400; makefile: 259; python: 42
file content (21 lines) | stat: -rwxr-xr-x 902 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

%:
	dh $@ --parallel --with autoreconf

# Snippet from http://wiki.debian.org/UnpackWaf with +dfsg1 changed to +dfsg
# get-orig-source to drop waf
upstream_version ?= $(shell dpkg-parsechangelog | sed -rne 's/^Version: ([0-9.]+)(\+dfsg\d+)?.*$$/\1/p')
dfsg_version = $(upstream_version)+dfsg
pkg = $(shell dpkg-parsechangelog | sed -ne 's/^Source: //p')

get-orig-source:
	uscan --noconf --force-download --rename --repack --download-current-version --destdir=.
	tar -xzf $(pkg)_$(upstream_version).orig.tar.gz
	mv $(pkg)-$(upstream_version) $(pkg)-$(dfsg_version)
	cd $(pkg)-$(dfsg_version) ; python waf --help > /dev/null
	mv $(pkg)-$(dfsg_version)/.waf-*/* $(pkg)-$(dfsg_version)
	sed -i '/^#==>$$/,$$d' $(pkg)-$(dfsg_version)/waf
	rmdir $(pkg)-$(dfsg_version)/.waf-*
	GZIP="-9fn" tar -czf $(pkg)_$(dfsg_version).orig.tar.gz $(pkg)-$(dfsg_version)
	rm -rf $(pkg)-$(dfsg_version)