From 79170ad8583966d3904879515d9348af459f2cba Mon Sep 17 00:00:00 2001 From: Todd Zullinger Date: Mon, 1 Aug 2022 19:50:49 -0400 Subject: set path to linker script in %_package_note_file MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The package-notes feature¹ creates a linker script in %{buildsubdir}. Unfortunately, %{buildsubdir} is not set in %prep, leaving us with an incorrect path to the linker script. The build then fails with: /usr/bin/ld: cannot open linker script file /builddir/build/BUILD/.package_note-git-2.35.0-0.2.rc2.fc36.3.x86_64.ld: No such file or directory Set the path to the linker script via %_package_note_file, per suggestion by Zbigniew Jędrzejewski-Szmek². References: ¹ https://fedoraproject.org/wiki/Changes/Package_information_on_ELF_objects ² https://bugzilla.redhat.com/2044028#c10 --- cgit.spec | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/cgit.spec b/cgit.spec index a016828..7720a5e 100644 --- a/cgit.spec +++ b/cgit.spec @@ -29,6 +29,9 @@ %bcond_without highlight %endif +# Set path to the package-notes linker script +%global _package_note_file %{_builddir}/%{name}-%{version}/.package_note-%{name}-%{version}-%{release}.%{_arch}.ld + Name: cgit Version: 1.2.3 Release: 11%{?dist} @@ -229,6 +232,8 @@ install -Dp -m0644 httpd.conf %{buildroot}%{httpdconfd}/%{name}.conf %changelog * Mon Aug 01 2022 Todd Zullinger - 1.2.3-11 - update cgit homepage +- set path to linker script in %%_package_note_file +- Resolves: rhbz#2113144 * Wed Jul 20 2022 Fedora Release Engineering - 1.2.3-10 - Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild -- cgit