summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgregor herrmann <gregoa@debian.org>2022-09-14 20:29:23 +0200
committergregor herrmann <gregoa@debian.org>2022-09-14 20:29:23 +0200
commit0fa7411695d6015da65588ec57ba8f1f8006ee86 (patch)
tree4a6313717ec75b15f161be136428e2ade6f9ab26
parentb0afde5b530e4a568cd1f1eeaaa1661e3e85cde0 (diff)
debian/rules: make wxWidgets version calculations more simple and robust.
Use wx-config insted of dpkg to get the version; this should always give us a x.y.z version without a final .something, without a +dfsg and a -revision, and thus saves us some mangling and weird effects in the generated dependencies.
-rwxr-xr-xdebian/rules6
1 files changed, 2 insertions, 4 deletions
diff --git a/debian/rules b/debian/rules
index f658154..c7312b6 100755
--- a/debian/rules
+++ b/debian/rules
@@ -9,13 +9,11 @@ WXVER=3.2
# 3.2: libwxgtk3.2-dev
WXFLAVOUR=
-export V=`dpkg -s libwxgtk$(WXVER)$(WXFLAVOUR)-dev | grep ^Version |cut -f2 -d' '`
+V:=$(shell wx-config --version)
VMAJOR:=$(shell echo $(V) |cut -f 1 -d .)
VMINOR:=$(shell echo $(V) |cut -f 2 -d .)
VPATCH:=$(shell echo $(V) |cut -f 3 -d .)
-VPATCHU:=$(shell echo $(VPATCH) |cut -f 1 -d +)
-VPATCHD:=$(shell echo $(VPATCH) |cut -f 2 -d +)
-NEXTPATCH:=$(shell expr $(VPATCH) + 1 2>/dev/null || expr `echo $(VPATCH) | cut -f 1 -d - ` + 1 2>/dev/null || expr $(VPATCHU) + 1 2>/dev/null)
+NEXTPATCH:=$(shell expr $(VPATCH) + 1 2>/dev/null || expr `echo $(VPATCH) | cut -f 1 -d - ` + 1 2>/dev/null)
_DETECTION_CMD := PERL5LIB=$(CURDIR)/blib/lib:$(CURDIR)/blib/arch perl -MAlien::wxWidgets -e '$$key = Alien::wxWidgets->key; $$key =~ s/_/-/g; print "$$key";'