diff --git a/0001-Add-support-for-compressing-firmware-in-copy-firmwar.patch b/0001-Add-support-for-compressing-firmware-in-copy-firmwar.patch index f8f95b8..d707bbf 100644 --- a/0001-Add-support-for-compressing-firmware-in-copy-firmwar.patch +++ b/0001-Add-support-for-compressing-firmware-in-copy-firmwar.patch @@ -32,7 +32,7 @@ index 83a0ec6..1edf4a6 100644 + +installcompress: + install -d $(DESTDIR)$(FIRMWAREDIR) -+ ./copy-firmware.sh -C $(DESTDIR)$(FIRMWAREDIR) ++ ./copy-firmware.sh -v -C $(DESTDIR)$(FIRMWAREDIR) diff --git a/copy-firmware.sh b/copy-firmware.sh index bbacb92..fc419a3 100755 --- a/copy-firmware.sh diff --git a/0001-copy-firmware.sh-don-t-add-cmpxtn-to-directory-links.patch b/0001-copy-firmware.sh-don-t-add-cmpxtn-to-directory-links.patch new file mode 100644 index 0000000..12da311 --- /dev/null +++ b/0001-copy-firmware.sh-don-t-add-cmpxtn-to-directory-links.patch @@ -0,0 +1,40 @@ +From 6208866dbef0b336e2b63695b27d61d95ace5721 Mon Sep 17 00:00:00 2001 +Message-Id: <6208866dbef0b336e2b63695b27d61d95ace5721.1686643559.git.jstancek@redhat.com> +From: Jan Stancek +Date: Tue, 13 Jun 2023 09:26:08 +0200 +Subject: [PATCH] copy-firmware.sh: don't add cmpxtn to directory links +Content-type: text/plain + +Signed-off-by: Jan Stancek +--- + copy-firmware.sh | 14 +++++++++++--- + 1 file changed, 11 insertions(+), 3 deletions(-) + +diff --git a/copy-firmware.sh b/copy-firmware.sh +index fc419a340c48..acd095ac8952 100755 +--- a/copy-firmware.sh ++++ b/copy-firmware.sh +@@ -77,9 +77,17 @@ grep -E '^Link:' WHENCE | sed -e's/^Link: *//g' -e's/-> //g' | while read f d; d + $verbose "WARNING: missing target for symlink $f$cmpxtn" + fi + else +- $verbose "creating link $f$cmpxtn -> $d$cmpxtn" +- install -d $destdir/$(dirname "$f$cmpxtn") +- ln -sf "$d$cmpxtn" "$destdir/$f$cmpxtn" ++ mkdir -p $(dirname "$f") ++ if test -d $(dirname "$f")/"$d"; then ++ # don't add compression extension to directory symlinks ++ $verbose "creating dir link $f -> $d" ++ install -d $destdir/$(dirname "$f") ++ ln -sf "$d" "$destdir/$f" ++ else ++ $verbose "creating link $f$cmpxtn -> $d$cmpxtn" ++ install -d $destdir/$(dirname "$f$cmpxtn") ++ ln -sf "$d$cmpxtn" "$destdir/$f$cmpxtn" ++ fi + fi + done + +-- +2.31.1 + diff --git a/linux-firmware.spec b/linux-firmware.spec index 1ad858a..5972836 100644 --- a/linux-firmware.spec +++ b/linux-firmware.spec @@ -14,6 +14,7 @@ BuildArch: noarch Source0: https://www.kernel.org/pub/linux/kernel/firmware/%{name}-%{version}.tar.xz Patch1: 0001-Add-support-for-compressing-firmware-in-copy-firmwar.patch +Patch2: 0001-copy-firmware.sh-don-t-add-cmpxtn-to-directory-links.patch BuildRequires: git-core BuildRequires: make