From f95079889e0b4a4902db77ef2c8f04311e14e8bc Mon Sep 17 00:00:00 2001 From: Stefan Bader Date: Fri, 16 Dec 2022 10:53:26 +0100 Subject: [PATCH] UBUNTU: [Packaging] dkms: increase directory prefix max length to 140 characters With longer kernel names (such as linux-lowlatency-hwe-5.15) we may exceed the dkms directory prefix limit of 100 characters, used when we build zfs for example. Simply increse this limit to 140 to prevent dkms from multiple flavours clashing on each other. Ignore: yes (backported from focal:linux-lowlatency-hwe-5.15) Signed-off-by: Stefan Bader Signed-off-by: Andrea Righi --- debian/rules.d/2-binary-arch.mk | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/debian/rules.d/2-binary-arch.mk b/debian/rules.d/2-binary-arch.mk index c720cc88041c..b90e26df1e8d 100644 --- a/debian/rules.d/2-binary-arch.mk +++ b/debian/rules.d/2-binary-arch.mk @@ -87,15 +87,15 @@ define install_control = done endef -# Ensure the directory prefix is exactly 100 characters long so pathnames are the +# Ensure the directory prefix is exactly 140 characters long so pathnames are the # exact same length in any binary files produced by the builds. These will be # commonised later. dkms_20d=.................... -dkms_100d=$(dkms_20d)$(dkms_20d)$(dkms_20d)$(dkms_20d)$(dkms_20d) -dkms_100c=$(shell echo '$(dkms_100d)' | sed -e 's/\./_/g') +dkms_140d=$(dkms_20d)$(dkms_20d)$(dkms_20d)$(dkms_20d)$(dkms_20d)$(dkms_20d)$(dkms_20d) +dkms_140c=$(shell echo '$(dkms_140d)' | sed -e 's/\./_/g') define dkms_dir_prefix = -$(shell echo $(1)/$(dkms_100c) | \ - sed -e 's/\($(dkms_100d)\).*/\1/' -e 's/^\(.*\)....$$/\1dkms/') +$(shell echo $(1)/$(dkms_140c) | \ + sed -e 's/\($(dkms_140d)\).*/\1/' -e 's/^\(.*\)....$$/\1dkms/') endef # Install the finished build