[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#491682: twin: Hard codes package version information in four places

Package: twin
Version: 0.5.1-3
Severity: serious
Tags: patch

Twin currently requires versioning information be replaced in four
different places in its packaging. This is unacceptable, and it should
get the information from one place (the changelog). Attached is a patch
that achieves that.

-- System Information:
Debian Release: lenny/sid
  APT prefers hardy-updates
  APT policy: (500, 'hardy-updates'), (500, 'hardy-security'), (500, 'hardy')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.24-19-generic (SMP w/1 CPU core)
Locale: LANG=en_AU.UTF-8, LC_CTYPE=en_AU.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
diff -u twin-0.5.1/debian/control twin-0.5.1/debian/control
--- twin-0.5.1/debian/control
+++ twin-0.5.1/debian/control
@@ -36,7 +36,7 @@
 Package: libtw0-dev
 Section: devel
 Architecture: any
-Depends: libtw0(=4.5.1-3), libc6-dev
+Depends: libtw0(= ${binary:Version}), libc6-dev
 Conflicts: libtw-dev
 Replaces: libtw-dev
 Description: a Text mode WINdow environment library, development
diff -u twin-0.5.1/debian/rules twin-0.5.1/debian/rules
--- twin-0.5.1/debian/rules
+++ twin-0.5.1/debian/rules
@@ -13,8 +13,8 @@
 #export DH_COMPAT=4
 #Version of twin
+TWIN_VERSION:=$(shell dpkg-parsechangelog | grep Version | cut -d\  -f2)
+LIBTW_VERSION:=$(shell echo $(TWIN_VERSION) | sed 's/^0/4/')
 include /usr/share/dpatch/dpatch.make

Reply to: