[med-svn] [conservation-code] 04/05: d/rules: do not parse d/changelog

Andreas Tille tille at debian.org
Fri Oct 6 13:53:20 UTC 2017


This is an automated email from the git hooks/post-receive script.

tille pushed a commit to branch master
in repository conservation-code.

commit b26b19e75a887406f445a3a29c59b4595b5675cb
Author: Andreas Tille <tille at debian.org>
Date:   Fri Oct 6 15:29:57 2017 +0200

    d/rules: do not parse d/changelog
---
 debian/rules | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/debian/rules b/debian/rules
index a8b0d40..0b34c8f 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,8 +1,8 @@
 #!/usr/bin/make -f
 #export DH_VERBOSE=1
 
-PACKAGE:=$(shell dpkg-parsechangelog --format rfc822|sed --posix -n -e 's/^Source: \(.*\)/\1/p;')
-VERSION:=$(shell dpkg-parsechangelog --format rfc822|sed --posix -n -e 's/^Version: \([0-9.]*\).*/\1/p;')
+include /usr/share/dpkg/default.mk
+# DEB_SOURCE: the source package name
 
 export DEB_BUILD_MAINT_OPTIONS = hardening=+all
 
@@ -10,8 +10,8 @@ MANS=debian/score_conservation.1
 prefix?=/usr
 
 datarootdir:=${prefix}/share
-docdir:=${datarootdir}/doc/${PACKAGE}
-pkgdatadir:=${datarootdir}/${PACKAGE}
+docdir:=${datarootdir}/doc/$(DEB_SOURCE)
+pkgdatadir:=${datarootdir}/$(DEB_SOURCE)
 
 
 %:
@@ -27,8 +27,8 @@ override_dh_installchangelogs: ChangeLog
 	dh_installchangelogs
 
 %.1:	%.1.pod
-	sed -e 's|__docdir__|$(docdir)|g;s|__pkgdatadir__|$(pkgdatadir)|g;s|__VERSION__|$(VERSION)|g;' "$<" | \
-	pod2man -c 'User Commands' -r "$(VERSION)" -name $(shell echo "$(basename $@)" | tr '[:lower:]' '[:upper:]') > "$@"
+	sed -e 's|__docdir__|$(docdir)|g;s|__pkgdatadir__|$(pkgdatadir)|g;s|__VERSION__|$(DEB_VERSION_UPSTREAM)|g;' "$<" | \
+	pod2man -c 'User Commands' -r "$(DEB_VERSION_UPSTREAM)" -name $(shell echo "$(basename $@)" | tr '[:lower:]' '[:upper:]') > "$@"
 
 override_dh_install:
 	dh_install -X._

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-med/conservation-code.git



More information about the debian-med-commit mailing list