In F39/rawhide, the /usr/lib/rpm/uncompress binary that rpmbuild invokes to extract source archives tries to call /usr/bin/7zip (rpm-build-4.18.92-1.fc39.x86_64 in F39) instead of /usr/bin/7a (rpm-build-4.18.1-3.fc38.x86_64 in F38) and fails, because it's not available in Fedora repositories. It looks like the binary to call is supplied via macro (%{__7zip})[1][2] and rpm's cmake script[3] fails to find 7zip[4]: INFO7zip got 7ZIP: __7ZIP-NOTFOUND but doesn't[5] fail the build so rpm gets built pointing to a non-existent binary. [1] https://github.com/rpm-software-management/rpm/blob/2043f2ac57ae2690cc1b11242f040085df8eed83/tools/rpmuncompress.c#L46 [2] https://github.com/rpm-software-management/rpm/blob/2043f2ac57ae2690cc1b11242f040085df8eed83/macros.in#L25 [3] https://github.com/rpm-software-management/rpm/blob/master/CMakeLists.txt#L76 [4] https://kojipkgs.fedoraproject.org//packages/rpm/4.18.92/1.fc39/data/logs/x86_64/build.log [5] https://github.com/rpm-software-management/rpm/blob/master/CMakeLists.txt#L93 Reproducible: Always Steps to Reproduce: 1. wget https://downloads.sourceforge.net/project/sevenzip/LZMA%20SDK/lzma2201.7z 2. /usr/lib/rpm/rpmuncompress -v -x lzma2201.7z Actual Results: /usr/bin/7zip x 'lzma2201.7z' sh: line 1: /usr/bin/7zip: No such file or directory Expected Results: /usr/bin/7za x 'lzma2201.7z' 7-Zip (a) [64] 16.02 : Copyright (c) 1999-2016 Igor Pavlov : 2016-05-21 p7zip Version 16.02 (locale=pl_PL.UTF-8,Utf16=on,HugeFiles=on,64 bits,8 CPUs 11th Gen Intel(R) Core(TM) i5-1145G7 @ 2.60GHz (806C1),ASM,AES-NI) Scanning the drive for archives: 1 file, 1261282 bytes (1232 KiB) Extracting archive: lzma2201.7z -- Path = lzma2201.7z Type = 7z Physical Size = 1261282 Headers Size = 11755 Method = LZMA:22 BCJ2 Solid = + Blocks = 3 Everything is Ok Files: 693 Size: 5921595 Compressed: 1261282 /usr/bin/7zip doesn't exist in Fedora repositories: # dnf install /usr/bin/7zip Last metadata expiration check: 3:29:05 ago on Tue 08 Aug 2023 09:55:55 CEST. No match for argument: /usr/bin/7zip Error: Unable to find a match: /usr/bin/7zip Before switching to cmake, rpm's configure script defaulted to /usr/bin/7za[1], so it worked out fine even if the binary wasn't around at configure time. [1] https://github.com/rpm-software-management/rpm/blob/c10e2310e4c41a626b524ae71b3c4f87a29134b2/configure.ac#L75
Thanks for reporting. This is an upstream issue though so moved there for better tracking wrt releases and such: https://github.com/rpm-software-management/rpm/issues/2608
Thanks for looking at this so quickly!
Thanks for fixing this upstream, please add the missing BuildRequires: p7zip to the spec file, too.
Yeah, although I'm now wondering if having "7zip" in the list of things to try is right at all. It's there in the initial commit, but then it defaults to /usr/bin/7za when it doesn't find a command named "7zip". Even on Windows the command seems to be either 7z or 7za. And if we just drop the apparently non-existent 7zip from the thing-to-try list, it'll use a working default even without the otherwise pointless buildrequire.
This bug appears to have been reported against 'rawhide' during the Fedora Linux 39 development cycle. Changing version to 39.
Fixed in rpm-4.18.92-3.fc40 but will need an update for f39 too.
FEDORA-2023-d1971fb6db has been submitted as an update to Fedora 39. https://bodhi.fedoraproject.org/updates/FEDORA-2023-d1971fb6db
FEDORA-2023-067d943f23 has been pushed to the Fedora 39 testing repository. Soon you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2023-067d943f23` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2023-067d943f23 See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.
FEDORA-2023-067d943f23 has been pushed to the Fedora 39 stable repository. If problem still persists, please make note of it in this bug report.