From 114088708f0ff1387a494c4e05682e17f2685f28 Mon Sep 17 00:00:00 2001 From: Ben Hutchings Date: Sun, 29 Apr 2018 18:36:20 +0100 Subject: [PATCH] Fix linux-doc, linux-manual, linux-source, linux-support package names We don't want to include "-4.9" in them twice. Add a "source_basename" template variable that excludes any version suffix in the source package name. (cherry picked from commit f3c51efdd6e9d0ce32ee5a0f998fdcda930a715c) For master, nothing is immediately broken without this. Also we have no longer build a linux-manual package. Change the changelog text accordingly. --- debian/bin/gencontrol.py | 1 + debian/changelog | 1 + debian/templates/control.docs.in | 3 +-- debian/templates/control.main.in | 4 ++-- 4 files changed, 5 insertions(+), 4 deletions(-) diff --git a/debian/bin/gencontrol.py b/debian/bin/gencontrol.py index 597926c55..7c9ab412f 100755 --- a/debian/bin/gencontrol.py +++ b/debian/bin/gencontrol.py @@ -552,6 +552,7 @@ class Gencontrol(Base): self.vars = { 'upstreamversion': self.version.linux_upstream, 'version': self.version.linux_version, + 'source_basename': re.sub(r'-[\d.]+$', '', self.changelog[0].source), 'source_upstream': self.version.upstream, 'source_package': self.changelog[0].source, 'abiname': self.abiname_version + self.abiname_part, diff --git a/debian/changelog b/debian/changelog index eeb360bcd..1dd27283c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -13,6 +13,7 @@ linux (4.17~rc2-1~exp1) UNRELEASED; urgency=medium * [armhf] Enable MTD_NAND_MARVELL as module, replacing MTD_NAND_PXA3xx * linux-kbuild: Update genksyms makefile to run flex and bison * Add support for building only versioned tools packages + * Change generation of linux-doc, linux-source, linux-support package names [ Luca Boccassi ] * Build-Dep on libelf-dev even for nopython/notools builds to fix FTBFS, diff --git a/debian/templates/control.docs.in b/debian/templates/control.docs.in index 30e55def9..827b1eccc 100644 --- a/debian/templates/control.docs.in +++ b/debian/templates/control.docs.in @@ -1,4 +1,4 @@ -Package: @source_package@-doc-@version@ +Package: @source_basename@-doc-@version@ Build-Profiles: Architecture: all Depends: ${misc:Depends} @@ -11,4 +11,3 @@ Description: Linux kernel specific documentation for version @version@ notes and the like. Consult the file /usr/share/doc/linux-doc-@version@/Documentation/00-INDEX for the detailed description of the contents. - diff --git a/debian/templates/control.main.in b/debian/templates/control.main.in index 80794db64..2372cdde4 100644 --- a/debian/templates/control.main.in +++ b/debian/templates/control.main.in @@ -1,4 +1,4 @@ -Package: @source_package@-source-@version@ +Package: @source_basename@-source-@version@ Build-Profiles: Architecture: all Section: kernel @@ -13,7 +13,7 @@ Description: Linux kernel source for version @version@ with Debian patches features that have already been (or are believed to be) accepted by the upstream maintainers. -Package: @source_package@-support-@abiname@ +Package: @source_basename@-support-@abiname@ Build-Profiles: Architecture: all Section: devel