[liblinear] 04/26: d/rules: Simplify upstream version extraction/utilization

Christian Kastner ckk at moszumanska.debian.org
Sun Sep 6 13:33:09 UTC 2015


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

ckk pushed a commit to branch master
in repository liblinear.

commit 277e0aa89708fdef21ab743610650263c8f55975
Author: Christian Kastner <ckk at kvr.at>
Date:   Fri Sep 4 16:52:26 2015 +0200

    d/rules: Simplify upstream version extraction/utilization
---
 debian/rules | 13 +++----------
 1 file changed, 3 insertions(+), 10 deletions(-)

diff --git a/debian/rules b/debian/rules
index 35bf653..b8738ab 100755
--- a/debian/rules
+++ b/debian/rules
@@ -7,16 +7,9 @@
 
 # Path to package source directory 
 PKGDIR := $(dir $(firstword $(MAKEFILE_LIST)))..
-
 # Get version numbers for SONAME from changelog
-DVER := $(shell cd $(PKGDIR) && dpkg-parsechangelog | grep '^Version')
-UPVER := $(shell echo $(DVER) | sed -rne 's/Version: ([^+]+).*/\1/p')
-LVER := $(shell echo $(UPVER) | sed -rne 's/([0-9]+)\..*/\1/p')
-LSUBVER := $(shell echo $(UPVER) | sed -rne 's/[0-9]+\.([0-9]+)/\1/p')
-# Export for upstream's Makefile
-export LVER
-export LSUBVER
-
+UPVER := $(shell cd $(PKGDIR) && dpkg-parsechangelog -SVersion | \
+		sed -rne 's/([0-9]+\.[0-9]+).*/\1/p')
 # Get Dpkg version (needed for override_dh_makeshlibs)
 DPKGVER := $(shell dpkg -l dpkg-dev | grep '^i' | awk '{print $$3}')
 
@@ -54,7 +47,7 @@ override_dh_strip:
 get-orig-source:
 	test -x /usr/bin/unzip || { echo "Package 'unzip' required"; exit 1; }
 	
-	uscan --noconf --force-download --download-version $(LVER).$(LSUBVER) \
+	uscan --noconf --force-download --download-version $(UPVER) \
 		--check-dirname-level=0 --destdir=$(CURDIR) $(PKGDIR)
 	
 	tar -xzf liblinear-$(UPVER).tar.gz

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/liblinear.git



More information about the debian-science-commits mailing list