summaryrefslogtreecommitdiff
path: root/debian/rules
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff-webhosting.net>2015-11-07 08:49:05 +0100
committerJörg Frings-Fürst <debian@jff-webhosting.net>2015-11-07 08:49:05 +0100
commit27285bf3f1b21d53d9b086fd94da02ac11c66a67 (patch)
treec1d1249d45e6e96e6a3c258e8c3d14e8bd64bb94 /debian/rules
parent449bb3420bd6225876951dc8a76c5a2bd5139b5f (diff)
d/rules: Remove UPSTREAM_VERSION and use VERSION instead
Diffstat (limited to 'debian/rules')
-rwxr-xr-xdebian/rules8
1 files changed, 3 insertions, 5 deletions
diff --git a/debian/rules b/debian/rules
index 9a38cfb..7a0e1b5 100755
--- a/debian/rules
+++ b/debian/rules
@@ -10,6 +10,8 @@ DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH)
DEB_HOST_ARCH_OS ?= $(shell dpkg-architecture -qDEB_HOST_ARCH_OS)
+VERSION = $(shell head -n1 debian/changelog | sed -e 's/.*(//;s/-.*).*//;s/\+/\-/')
+
ifeq ($(DEB_HOST_ARCH_OS),)
DEB_HOST_ARCH_OS := $(subst -gnu,,$(shell dpkg-architecture -qDEB_HOST_GNU_SYSTEM))
ifeq ($(DEB_HOST_ARCH_OS),gnu)
@@ -26,8 +28,6 @@ ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
STRIP = ""
endif
-VERSION = $(shell head -n1 debian/changelog | sed -e 's/.*(//;s/-.*).*//;s/\+/\-/')
-
%:
dh $@ --parallel --with autotools_dev,systemd
@@ -136,7 +136,5 @@ override_dh_systemd_enable:
override_dh_strip:
dh_strip --dbg-package=libsane-dbg
-UPSTREAM_VERSION=$(shell dpkg-parsechangelog | sed -n '/\(Version:\)/{s/^Version:[[:space:]]\+\([0-9]\+:\)\?\(.*\)/\2/p}' | rev | cut -d- -f 2- | rev)
-
override_dh_makeshlibs:
- dh_makeshlibs -- -v$(UPSTREAM_VERSION) -Pdebian/libsane -plibsane
+ dh_makeshlibs -- -v$(VERSION) -Pdebian/libsane -plibsane