[request-tracker-maintainers] Bug#881985: request-tracker4: Correctly set RT version in configure if a Debian epoch is used

Andrew Ruthven andrew.ruthven at catalyst.net.nz
Fri Nov 17 09:29:35 UTC 2017


Source: request-tracker4
Severity: minor
Tags: patch

Dear Maintainer,

I need to build a custom RT package to include some custom patches that
haven't been accepted upstream yet. When I do that, I set an epoch on
the Debian version to ensure that we don't accidentally upgrade to a
newer version from Debian. With the 4.4.x packages this has caused
RT to think the version is 0.0.0, which causes a bunch of issues.

The attached patch modifies debian/patches/debian_version.diff to strip
off an epoch, if present, and the Debian patch level from the version
presented by RT. If you want to keep the Debian patch level, then
remove
the first call to sed.

I also note that the same diff currently sets the date to 2016 in the
footer.

Cheers,
Andrew

-- System Information:
Debian Release: 9.1
  APT prefers common
  APT policy: (500, 'common'), (500, 'stable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.9.0-4-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_NZ.UTF-8, LC_CTYPE=en_NZ.UTF-8 (charmap=UTF-8),
LANGUAGE=en_NZ.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
-- 
Andrew Ruthven, Wellington, New Zealand
MIITP

At work: andrew.ruthven at catalyst.net.nz
At home: andrew at etc.gen.nz
Cloud  : NZs only real cloud - https://catalyst.net.nz/cloud
GPG fpr: C603 FC4E 600F 1CEC D1C8  D97C 4B53 D931 E4D3 E863
LCA2018: Just a little bit of history repeating - http://linux.conf.au
-------------- next part --------------
--- debian/patches/debianize_version.diff	2017-08-29 19:05:39.000000000 +0000
+++ ../rt-patches/debianize_version.diff	2017-11-14 23:42:45.762257327 +0000
@@ -6,6 +6,9 @@
 Also make clear in the web interface that this version number is from
 Debian.
 
+Updated to strip the epoch and Debian patch off the version. Commands
+taken from /usr/share/dpkg/pkg-info.mk .
+
 Patch-Name: debianize_version.diff
 ---
  configure.ac               | 8 ++++----
@@ -21,7 +24,7 @@
  dnl Setup autoconf
  AC_PREREQ([2.53])
 -AC_INIT(RT, m4_esyscmd([( git describe --tags || cat ./.tag 2> /dev/null || echo "rt-3.9.EXPORTED" )| tr -d "\n"]), [rt-bugs at bestpractical.com])
-+AC_INIT(RT, m4_esyscmd([( dpkg-parsechangelog -SVersion )| tr -d "\n"]), [https://www.debian.org/Bugs/Reporting])
++AC_INIT(RT, m4_esyscmd([( dpkg-parsechangelog -SVersion | sed -e 's/-[^-]*$//' | sed -e 's/^[0-9]*://' )| tr -d "\n"]), [https://www.debian.org/Bugs/Reporting])
  AC_CONFIG_SRCDIR([lib/RT.pm])
  
  dnl Save our incant early since $@ gets overwritten by some macros.


More information about the pkg-request-tracker-maintainers mailing list