ACK/Cmnt: [PATCH v2 1/1] UBUNTU: [Packaging] add a new migrate autogenerate option
Andrei Gherzan
andrei.gherzan at canonical.com
Thu Mar 30 13:45:20 UTC 2023
On 23/03/30 03:57PM, Timo Aaltonen wrote:
> From: Kleber Sacilotto de Souza <kleber.souza at canonical.com>
>
> BugLink: https://bugs.launchpad.net/bugs/1991130
>
> Add a new "migrate" command to be used by 'debian/package.config' which
> contrary to "transitional" doesn't have the autogenerated contents
> filtered out by 'debian/rules.in' depending on the source's variants.
>
> v2: rebased, and added Provides which is needed to replace the old driver
I would drop this when applying (it should have resided in the cover
letter).
>
> Signed-off-by: Kleber Sacilotto de Souza <kleber.souza at canonical.com>
> Signed-off-by: Timo Aaltonen <timo.aaltonen at canonical.com>
> ---
> debian/scripts/generate-rules | 22 ++++++++++++++++++++++
> 1 file changed, 22 insertions(+)
>
> diff --git a/debian/scripts/generate-rules b/debian/scripts/generate-rules
> index d9a2a10..90dc570 100755
> --- a/debian/scripts/generate-rules
> +++ b/debian/scripts/generate-rules
> @@ -38,6 +38,7 @@ mkdir -p "debian/control.d"
> : >"debian/control.d/nvidia"
> : >"debian/control.d/migrate-nvidia"
> : >"debian/control.d/transitionals-local"
> +: >"debian/control.d/migrate-local"
> : >"debian/control.d/signatures"
>
> cat - "debian/rules.in" >"debian/rules.gen" <<EOL
> @@ -279,3 +280,24 @@ Description: Extra drivers for nvidia-${from} (dummy transitional package)
> Transitional package for upgrades of ${from} to ${to}.
> EOL
> done <"debian/package.config"
> +
> +while read command from to archs
> +do
> + case "$command" in
> + migrate) from_minus=$(echo "$from" | sed -e 's/-.*//');;
> + *) continue ;;
> + esac
> +
> + # debian/control.d/migrate-local
> + echo "II: manual migrate linux-modules-nvidia-$from -> linux-modules-nvidia-$to"
> + cat - >>"debian/control.d/migrate-local" <<EOL
> +
> +Package: linux-modules-nvidia-${from}
> +Architecture: ${archs}
> +Section: oldlibs
> +Provides: \${dkms:nvidia-${from_minus}-modules}, nvidia-prebuilt-kernel
> +Depends: linux-modules-nvidia-${to}
> +Description: Extra drivers for nvidia-${from} (dummy transitional package)
> + Transitional package for upgrades of ${from} to ${to}.
> +EOL
> +done <"debian/package.config"
> --
> 2.39.2
Acked-by: Andrei Gherzan <andrei.gherzan at canonical.com>
--
Andrei Gherzan
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://lists.ubuntu.com/archives/kernel-team/attachments/20230330/ed8a1ba3/attachment.sig>
More information about the kernel-team
mailing list