Source: u-boot Severity: wishlist Tags: patch A command line does not add the same value twice. This change prepares a full gencontrol command line built from a Make variable and visible in the logs.
The variable names have to change, else debian/rules would have to run dh_gencontrol on each package in turn, and for that check notools,-indep,subarch and so on. While editing this lines in debian/control, remove some new lines from the variable contents.
>From 85cd14a90b94a6a6e8012cbe8d0abd339da7a13a Mon Sep 17 00:00:00 2001 From: Nicolas Boulenguez <nico...@debian.org> Date: Sun, 17 Jan 2021 15:21:49 +0100 Subject: Pass distinct substvars to gencontrol on the command line A command line does not add the same value twice. This change prepares a full gencontrol command line built from a Make variable and visible in the logs. The variable names have to change, else debian/rules would have to run dh_gencontrol on each package in turn, and for that check notools,-indep,subarch and so on. While editing this lines in debian/control, remove some new lines from the variable contents. diff --git a/debian/bin/update-substvars b/debian/bin/update-substvars index 1412a74087..eaaaefcd1b 100755 --- a/debian/bin/update-substvars +++ b/debian/bin/update-substvars @@ -1,14 +1,12 @@ #!/bin/sh for file in debian/build/platforms.* ; do package=${file#debian/build/platforms.} - echo $(LC_ALL=C sort -u ${file}) | \ + echo -n $(LC_ALL=C sort -u ${file}) | \ sed -e 's, ,${Newline},g' \ - -e 's,^,uboot:platforms=${Newline}Included platforms:${Newline},g' \ - >> debian/${package}.substvars + -e 's,^,'-V$package':platforms=,' -e 's,$,\x0,' case $package in u-boot-rockchip|u-boot-sunxi) - printf "uboot:Built-Using=$(dpkg-query -f '${source:Package} (= ${source:Version}) [arm64]' -W arm-trusted-firmware)\n"\ - >> debian/${package}.substvars + printf -- "-V$package:Built-Using=$(dpkg-query -f '${source:Package} (= ${source:Version}) [arm64]' -W arm-trusted-firmware)\0"\ ;; esac done diff --git a/debian/control b/debian/control index 6f4cc17906..ff3e528e50 100644 --- a/debian/control +++ b/debian/control @@ -47,7 +47,9 @@ Description: A boot loader for embedded systems intended to be easy to port and to debug, and runs on many supported architectures, including PPC, ARM, MIPS, x86, m68k, NIOS, and Microblaze. - ${uboot:platforms} + . + Included platforms: + ${u-boot:platforms} Package: u-boot-amlogic Architecture: arm64 @@ -62,7 +64,9 @@ Description: A boot loader for amlogic systems NIOS, and Microblaze. . This package includes boot loaders for various amlogic platforms. - ${uboot:platforms} + . + Included platforms: + ${u-boot-amlogic:platforms} Package: u-boot-imx Architecture: armhf @@ -78,7 +82,9 @@ Description: A boot loader for imx systems NIOS, and Microblaze. . This package includes boot loaders for various imx platforms. - ${uboot:platforms} + . + Included platforms: + ${u-boot-imx:platforms} Package: u-boot-qemu Architecture: all @@ -94,7 +100,9 @@ Description: A boot loader for qemu NIOS, and Microblaze. . This package includes boot loaders for qemu/kvm. - ${uboot:platforms} + . + Included platforms: + ${u-boot-qemu:platforms} Package: u-boot-qcom Architecture: arm64 @@ -108,7 +116,9 @@ Description: A boot loader for qcom systems NIOS, and Microblaze. . This package includes boot loaders for various qcom platforms. - ${uboot:platforms} + . + Included platforms: + ${u-boot-qcom:platforms} Package: u-boot-tegra Architecture: armhf arm64 @@ -124,7 +134,9 @@ Description: A boot loader for NVIDIA Tegra systems NIOS, and Microblaze. . This package includes boot loaders for various NVIDIA Tegra platforms. - ${uboot:platforms} + . + Included platforms: + ${u-boot-tegra:platforms} Package: u-boot-omap Architecture: armhf @@ -141,12 +153,14 @@ Description: A boot loader for omap systems . This package includes boot loaders for various omap and related platforms. - ${uboot:platforms} + . + Included platforms: + ${u-boot-omap:platforms} Package: u-boot-sunxi Architecture: armhf arm64 Multi-Arch: same -Built-Using: ${uboot:Built-Using} +Built-Using: ${u-boot-sunxi:Built-Using} Depends: ${misc:Depends} Recommends: arm-trusted-firmware [arm64], u-boot-tools [arm64] Breaks: u-boot (<< 2014.10~rc2+dfsg1-2~) @@ -160,7 +174,9 @@ Description: A boot loader for sunxi systems . This package includes boot loaders for various Allwinner/sunxi platforms. - ${uboot:platforms} + . + Included platforms: + ${u-boot-sunxi:platforms} Package: u-boot-exynos Architecture: armhf @@ -174,7 +190,9 @@ Description: A boot loader for exynos systems NIOS, and Microblaze. . This package includes boot loaders for various Exynos platforms. - ${uboot:platforms} + . + Included platforms: + ${u-boot-exynos:platforms} Package: u-boot-mvebu Architecture: arm64 @@ -188,12 +206,14 @@ Description: A boot loader for marvell systems NIOS, and Microblaze. . This package includes boot loaders for various Marvell platforms. - ${uboot:platforms} + . + Included platforms: + ${u-boot-mvebu:platforms} Package: u-boot-rockchip Architecture: armhf arm64 Multi-Arch: same -Built-Using: ${uboot:Built-Using} +Built-Using: ${u-boot-rockchip:Built-Using} Depends: ${misc:Depends} Recommends: python3, arm-trusted-firmware [arm64], u-boot-tools [arm64] Description: A boot loader for rockchip systems @@ -204,7 +224,9 @@ Description: A boot loader for rockchip systems NIOS, and Microblaze. . This package includes boot loaders for various Rockchip platforms. - ${uboot:platforms} + . + Included platforms: + ${u-boot-rockchip:platforms} Package: u-boot-rpi Architecture: armel armhf arm64 @@ -219,7 +241,9 @@ Description: A boot loader for Raspberry PI systems . This package includes boot loaders for various Raspberry PI platforms. - ${uboot:platforms} + . + Included platforms: + ${u-boot-rpi:platforms} Package: u-boot-sifive Architecture: riscv64 @@ -234,7 +258,9 @@ Description: A boot loader for SiFive systems . This package includes boot loaders for various SiFive platforms. - ${uboot:platforms} + . + Included platforms: + ${u-boot-sifive:platforms} Package: u-boot-tools Architecture: linux-any diff --git a/debian/rules b/debian/rules index f1e8a0d2a5..df9871234f 100755 --- a/debian/rules +++ b/debian/rules @@ -144,5 +144,4 @@ override_dh_clean: find . -type d -name __pycache__ -delete override_dh_gencontrol: - debian/bin/update-substvars - dh_gencontrol + debian/bin/update-substvars | xargs -0 dh_gencontrol --