b7381d643d
Thanks to this the file is (in the common case) created in the unpacked build directory, and not one level up. I.e. /builddir/build/BUILD/lirc-0.10.0/.package_note-lirc-0.10.0-34.fc36.x86_64 instead of /builddir/build/BUILD/.package_note-lirc-0.10.0-34.fc36.x86_64.ld. This is nicer esp. for 'fedpkg local' builds, where the dist-git directory is used as the build dir. When there are multiple %setup calls, the *last* extracted directory becomes %{buildsubdir}. This might be confusing, but it shouldn't cause problems for this use. Suggested in https://bugzilla.redhat.com/show_bug.cgi?id=2043092#c21.
9 lines
723 B
Plaintext
9 lines
723 B
Plaintext
# Add an ELF note with information about the package the code was compiled for.
|
|
# See https://fedoraproject.org/wiki/Changes/Package_information_on_ELF_objects
|
|
# for details.
|
|
%_package_note_file %{_builddir}%{?buildsubdir:/%{buildsubdir}}/.package_note-%{name}-%{version}-%{release}.%{_arch}.ld
|
|
|
|
%_package_note_flags %{?_package_note_file:%{?name:%["%_target_cpu" == "noarch"?"":"-Wl,-dT,%{_package_note_file}"]}}
|
|
|
|
%_generate_package_note_file %{?_package_note_file:%{?name:%["%_target_cpu" == "noarch"?"":"if [ -f %{_rpmconfigdir}/generate-rpm-note.sh ]; then %{_rpmconfigdir}/generate-rpm-note.sh ${RPM_PACKAGE_NAME:?} ${RPM_PACKAGE_VERSION:?}-${RPM_PACKAGE_RELEASE:?} ${RPM_ARCH:?} >%{_package_note_file}; fi"]}}
|