[P/U] [PATCH RESEND 3/4] UBUNTU: [packaging] remove DESC and =HUMAN= substitution
Masahiro Yamada
masahiro.yamada at canonical.com
Tue Feb 18 14:50:48 UTC 2025
The sign/unsigned distortion in debian/control has been fixed, but the
Description fields still depend on the build machine's architecture, as
DESC and =HUMAN= are replaced with the build machine's information.
If you generate debian/control on an x86 machine, the unsigned linux-image
entry will look like this:
Package: linux-image-6.14.0-2-generic
Build-Profiles: <!stage1>
Architecture: armhf ppc64el
[ snip ]
Description: Linux kernel image for version 6.14.0 on 64 bit x86 SMP
This package contains the Linux kernel image for version 6.14.0 on
64 bit x86 SMP.
.
Supports Generic processors.
.
Here, the Architecture field contains "armhf ppc64el", while the
Description field mentions "64 bit x86" because the definition of
'human_arch' for the build arch is included by this line:
-include $(DEBIAN)/rules.d/$(arch).mk
This commit removes arch-specific information from Description fields.
In Debian kernel, every linux-image entry has arch-specific description,
but that is because the flavour names are arch-specific, such as "amd64",
"cloud-amd64", "arm64", "cloud-arm64", etc.
However, in Ubuntu kernel, some of the flavour names are shared across
multiple architectures, like "generic", "aws", "gcp", etc.
If this information is desired, the substvars feature could be used to
differentiate the Description field in binary package control files
(DEBIAN/control), but I do not believe it is worth the effort.
Signed-off-by: Masahiro Yamada <masahiro.yamada at canonical.com>
---
debian.master/control.d/flavour-control.stub | 21 +++++++------------
.../control.d/flavour-signed-control.stub | 10 ++++-----
debian.master/control.d/vars.generic | 1 -
debian.master/control.d/vars.generic-64k | 1 -
debian.master/control.stub.in | 6 ++----
debian.master/rules.d/amd64.mk | 1 -
debian.master/rules.d/arm64.mk | 1 -
debian.master/rules.d/armhf.mk | 1 -
debian.master/rules.d/i386.mk | 1 -
debian.master/rules.d/ppc64el.mk | 1 -
debian.master/rules.d/riscv64.mk | 1 -
debian.master/rules.d/s390x.mk | 1 -
debian.master/rules.d/x32.mk | 1 -
debian/control.d/flavour-buildinfo.stub | 5 ++---
debian/rules | 1 -
debian/scripts/control-create | 3 +--
16 files changed, 17 insertions(+), 39 deletions(-)
diff --git a/debian.master/control.d/flavour-control.stub b/debian.master/control.d/flavour-control.stub
index e1e1afc01859..4bd22c6f2c61 100644
--- a/debian.master/control.d/flavour-control.stub
+++ b/debian.master/control.d/flavour-control.stub
@@ -1,6 +1,5 @@
# Items that get replaced:
# FLAVOUR
-# DESC
# ARCH
# SUPPORTED
# TARGET
@@ -16,7 +15,7 @@
# debian/rules. PGGVER, ABINUM, and SRCPKGNAME are all converted in the
# process of creating debian/control.
#
-# The flavour specific strings (ARCH, DESC, etc) are converted using values from the various
+# The flavour specific strings (ARCH, etc) are converted using values from the various
# flavour files in debian/control.d/vars.*
#
# XXX: Leave the blank line before the first package!!
@@ -28,7 +27,7 @@ Section: kernel
Priority: optional
Depends: ${misc:Depends}, ${shlibs:Depends}
Built-Using: ${linux:BuiltUsing}
-Description: Linux kernel extra modules for version PKGVER on DESC
+Description: Linux kernel extra modules for version PKGVER
Contains the corresponding System.map file, the modules built by the
packager, and scripts that try to ensure that the system is not left in an
unbootable state after an update.
@@ -47,9 +46,8 @@ Architecture: ARCH
Section: kernel
Priority: optional
Depends: ${misc:Depends}, ${shlibs:Depends}, linux-modules-PKGVER-ABINUM-FLAVOUR, wireless-regdb
-Description: Linux kernel extra modules for version PKGVER on DESC
- This package contains the Linux kernel extra modules for version PKGVER on
- DESC.
+Description: Linux kernel extra modules for version PKGVER
+ This package contains the Linux kernel extra modules for version PKGVER.
.
Also includes the corresponding System.map file, the modules built by the
packager, and scripts that try to ensure that the system is not left in an
@@ -70,9 +68,8 @@ Section: devel
Priority: optional
Depends: ${misc:Depends}, SRCPKGNAME-headers-PKGVER-ABINUM, ${shlibs:Depends}
Provides: linux-headers, linux-headers-3.0
-Description: Linux kernel headers for version PKGVER on DESC
- This package provides kernel header files for version PKGVER on
- DESC.
+Description: Linux kernel headers for version PKGVER
+ This package provides kernel header files for version PKGVER.
.
This is for sites that want the latest kernel headers. Please read
/usr/share/doc/linux-headers-PKGVER-ABINUM/debian.README.gz for details.
@@ -97,8 +94,7 @@ Depends: ${misc:Depends}, SRCPKGNAME-tools-PKGVER-ABINUM
Description: Linux kernel version specific tools for version PKGVER-ABINUM
This package provides the architecture dependant parts for kernel
version locked tools (such as perf and x86_energy_perf_policy) for
- version PKGVER-ABINUM on
- =HUMAN=.
+ version PKGVER-ABINUM.
Package: linux-cloud-tools-PKGVER-ABINUM-FLAVOUR
Build-Profiles: <!stage1>
@@ -108,6 +104,5 @@ Priority: optional
Depends: ${misc:Depends}, SRCPKGNAME-cloud-tools-PKGVER-ABINUM
Description: Linux kernel version specific cloud tools for version PKGVER-ABINUM
This package provides the architecture dependant parts for kernel
- version locked tools for cloud for version PKGVER-ABINUM on
- =HUMAN=.
+ version locked tools for cloud for version PKGVER-ABINUM.
diff --git a/debian.master/control.d/flavour-signed-control.stub b/debian.master/control.d/flavour-signed-control.stub
index 175a771894c0..f4818b72e370 100644
--- a/debian.master/control.d/flavour-signed-control.stub
+++ b/debian.master/control.d/flavour-signed-control.stub
@@ -9,9 +9,8 @@ Recommends: BOOTLOADER, initramfs-tools | linux-initramfs-tool
Breaks: flash-kernel (<< 3.90ubuntu2) [arm64 armhf], s390-tools (<< 2.3.0-0ubuntu3) [s390x]
Conflicts: linux-image=SIGN-PEER-PKG=-PKGVER-ABINUM-FLAVOUR
Suggests: fdutils, SRCPKGNAME-tools, linux-headers-PKGVER-ABINUM-FLAVOUR, linux-modules-extra-PKGVER-ABINUM-FLAVOUR
-Description: Linux kernel image for version PKGVER on DESC
- This package contains the=SIGN-ME-TXT= Linux kernel image for version PKGVER on
- DESC.
+Description: Linux kernel image for version PKGVER
+ This package contains the=SIGN-ME-TXT= Linux kernel image for version PKGVER.
.
Supports SUPPORTED processors.
.
@@ -28,9 +27,8 @@ Section: devel
Priority: optional
Depends: ${misc:Depends}
Provides: linux-debug
-Description: Linux kernel debug image for version PKGVER on DESC
- This package provides the=SIGN-ME-TXT= kernel debug image for version PKGVER on
- DESC.
+Description: Linux kernel debug image for version PKGVER
+ This package provides the=SIGN-ME-TXT= kernel debug image for version PKGVER.
.
This is for sites that wish to debug the kernel.
.
diff --git a/debian.master/control.d/vars.generic b/debian.master/control.d/vars.generic
index ca144cfac896..3fd9beb0a776 100644
--- a/debian.master/control.d/vars.generic
+++ b/debian.master/control.d/vars.generic
@@ -1,6 +1,5 @@
arch="amd64 armhf arm64 ppc64el s390x"
supported="Generic"
target="Geared toward desktop and server systems."
-desc="=HUMAN= SMP"
bootloader="grub-pc [amd64] | grub-efi-amd64 [amd64] | grub-efi-ia32 [amd64] | grub [amd64] | lilo [amd64] | flash-kernel [armhf arm64] | grub-efi-arm64 [arm64] | grub-efi-arm [armhf] | grub-ieee1275 [ppc64el]"
provides="kvm-api-4, redhat-cluster-modules, ivtv-modules, virtualbox-guest-modules [amd64]"
diff --git a/debian.master/control.d/vars.generic-64k b/debian.master/control.d/vars.generic-64k
index 82213f4803fc..cd772b42f9d7 100644
--- a/debian.master/control.d/vars.generic-64k
+++ b/debian.master/control.d/vars.generic-64k
@@ -1,6 +1,5 @@
arch="arm64"
supported="Generic 64K pages"
target="Geared toward desktop and server systems."
-desc="=HUMAN= SMP"
bootloader="grub-efi-arm64 [arm64] | flash-kernel [arm64]"
provides="kvm-api-4, redhat-cluster-modules, ivtv-modules"
diff --git a/debian.master/control.stub.in b/debian.master/control.stub.in
index b1fcf2800c26..4c79faa603dd 100644
--- a/debian.master/control.stub.in
+++ b/debian.master/control.stub.in
@@ -82,8 +82,7 @@ Depends: ${misc:Depends}, ${shlibs:Depends}, linux-tools-common
Description: Linux kernel version specific tools for version PKGVER-ABINUM
This package provides the architecture dependant parts for kernel
version locked tools (such as perf and x86_energy_perf_policy) for
- version PKGVER-ABINUM on
- =HUMAN=.
+ version PKGVER-ABINUM.
You probably want to install linux-tools-PKGVER-ABINUM-<flavour>.
Package: SRCPKGNAME-cloud-tools-PKGVER-ABINUM
@@ -94,6 +93,5 @@ Priority: optional
Depends: ${misc:Depends}, ${shlibs:Depends}, linux-cloud-tools-common
Description: Linux kernel version specific cloud tools for version PKGVER-ABINUM
This package provides the architecture dependant parts for kernel
- version locked tools for cloud tools for version PKGVER-ABINUM on
- =HUMAN=.
+ version locked tools for cloud tools for version PKGVER-ABINUM.
You probably want to install linux-cloud-tools-PKGVER-ABINUM-<flavour>.
diff --git a/debian.master/rules.d/amd64.mk b/debian.master/rules.d/amd64.mk
index 668da4e33b9c..fbb0805c52b2 100644
--- a/debian.master/rules.d/amd64.mk
+++ b/debian.master/rules.d/amd64.mk
@@ -1,4 +1,3 @@
-human_arch = 64 bit x86
build_arch = x86
defconfig = defconfig
flavours = generic
diff --git a/debian.master/rules.d/arm64.mk b/debian.master/rules.d/arm64.mk
index 2f23ecddcea0..734e6ac18dc8 100644
--- a/debian.master/rules.d/arm64.mk
+++ b/debian.master/rules.d/arm64.mk
@@ -1,4 +1,3 @@
-human_arch = ARMv8
build_arch = arm64
defconfig = defconfig
flavours = generic generic-64k
diff --git a/debian.master/rules.d/armhf.mk b/debian.master/rules.d/armhf.mk
index d2e36075bb2d..492b11501cda 100644
--- a/debian.master/rules.d/armhf.mk
+++ b/debian.master/rules.d/armhf.mk
@@ -1,4 +1,3 @@
-human_arch = ARM (hard float)
build_arch = arm
defconfig = defconfig
flavours = generic
diff --git a/debian.master/rules.d/i386.mk b/debian.master/rules.d/i386.mk
index 45e7e48aeaa1..82502044be4f 100644
--- a/debian.master/rules.d/i386.mk
+++ b/debian.master/rules.d/i386.mk
@@ -1,4 +1,3 @@
-human_arch = 32 bit x86
build_arch = i386
defconfig = defconfig
flavours = generic
diff --git a/debian.master/rules.d/ppc64el.mk b/debian.master/rules.d/ppc64el.mk
index c49edccfb4e4..ec5f386aa839 100644
--- a/debian.master/rules.d/ppc64el.mk
+++ b/debian.master/rules.d/ppc64el.mk
@@ -1,4 +1,3 @@
-human_arch = PowerPC 64el
build_arch = powerpc
defconfig = pseries_le_defconfig
flavours = generic
diff --git a/debian.master/rules.d/riscv64.mk b/debian.master/rules.d/riscv64.mk
index 111da7fb2b5d..c8d3969e520d 100644
--- a/debian.master/rules.d/riscv64.mk
+++ b/debian.master/rules.d/riscv64.mk
@@ -1,4 +1,3 @@
-human_arch = RISC-V
build_arch = riscv
defconfig = defconfig
flavours = generic
diff --git a/debian.master/rules.d/s390x.mk b/debian.master/rules.d/s390x.mk
index e679eaa83cad..937e84ecfd7c 100644
--- a/debian.master/rules.d/s390x.mk
+++ b/debian.master/rules.d/s390x.mk
@@ -1,4 +1,3 @@
-human_arch = System 390x
build_arch = s390
defconfig = defconfig
flavours = generic
diff --git a/debian.master/rules.d/x32.mk b/debian.master/rules.d/x32.mk
index fc6c4179a67e..b847a3ba0b17 100644
--- a/debian.master/rules.d/x32.mk
+++ b/debian.master/rules.d/x32.mk
@@ -1,4 +1,3 @@
-human_arch = 64 bit x86 (32 bit userspace)
build_arch = x86
defconfig = defconfig
flavours =
diff --git a/debian/control.d/flavour-buildinfo.stub b/debian/control.d/flavour-buildinfo.stub
index dd08a6715f6b..4c7e89d206c1 100644
--- a/debian/control.d/flavour-buildinfo.stub
+++ b/debian/control.d/flavour-buildinfo.stub
@@ -6,9 +6,8 @@ Section: kernel
Priority: optional
Depends: ${misc:Depends}, ${shlibs:Depends}
Built-Using: ${linux:BuiltUsing}
-Description: Linux kernel buildinfo for version PKGVER on DESC
- This package contains the Linux kernel buildinfo for version PKGVER on
- DESC.
+Description: Linux kernel buildinfo for version PKGVER
+ This package contains the Linux kernel buildinfo for version PKGVER.
.
You likely do not want to install this package.
diff --git a/debian/rules b/debian/rules
index 965773d5dc80..d3a36195dc15 100755
--- a/debian/rules
+++ b/debian/rules
@@ -188,7 +188,6 @@ $(DEBIAN)/control.stub: \
sed -e 's/PKGVER/$(DEB_VERSION_UPSTREAM)/g' \
-e 's/ABINUM/$(abinum)/g' \
-e 's/SRCPKGNAME/$(DEB_SOURCE)/g' \
- -e 's/=HUMAN=/$(human_arch)/g' \
-e 's/=SERIES=/$(DEB_DISTRIBUTION)/g' \
-e 's|\(^Maintainer:.*\)|\1\nXSC-Ubuntu-Compatible-Signing: $(UBUNTU_COMPATIBLE_SIGNING)|g' \
-e 's/\(^Build-Depends:$$\)/\1\n$(GCC_BUILD_DEPENDS)/g' \
diff --git a/debian/scripts/control-create b/debian/scripts/control-create
index 527471d85b72..bd3256933679 100755
--- a/debian/scripts/control-create
+++ b/debian/scripts/control-create
@@ -23,7 +23,7 @@ gen_common () {
}
gen_per_flavour () {
- local arch bootloader conflicts desc flavour provides supported target
+ local arch bootloader conflicts flavour provides supported target
local sed_common_patterns signed_arch unsigned_arch
var=$1
@@ -50,7 +50,6 @@ gen_per_flavour () {
-e "/^#/d"
-e "s/BOOTLOADER/${bootloader}/g"
-e "s/=CONFLICTS=/${conflicts}/g"
- -e "s/DESC/${desc}/g"
-e "s/FLAVOUR/${flavour}/g"
-e "s/=PROVIDES=/${provides}/g"
-e "s/SUPPORTED/${supported}/g"
--
2.43.0
More information about the kernel-team
mailing list