Do not export any windows tools (if they were built).

Resolves: #2057638
This commit is contained in:
Nick Clifton 2022-03-07 12:40:19 +00:00
parent ec0d868ca5
commit 72fcf6564e
2 changed files with 39 additions and 1 deletions

View File

@ -39,7 +39,7 @@
Summary: A GNU collection of binary utilities
Name: binutils%{?name_cross}%{?_with_debug:-debug}
Version: 2.35.2
Release: 17%{?dist}
Release: 18%{?dist}
License: GPLv3+
URL: https://sourceware.org/binutils
@ -402,6 +402,10 @@ Patch51: binutils-x86-AMX-insns.patch
# Lifetime: Fixed in 2.38.
Patch52: binutils-gas-Use-the-directory-name-in-.file-0.patch
# Purpose: Stop libtool from inserting useless runpaths into binaries.
# Lifetime: Who knows.
Patch53: gcc12-libtool-no-rpath.patch
#----------------------------------------------------------------------------
Provides: bundled(libiberty)
@ -952,6 +956,9 @@ exit 0
# Strictly speaking ld is a symlink not a ghost file, but %%verify does not support symlinks
%ghost %{_bindir}/%{?cross}ld
%{_bindir}/%{?cross}ld.bfd
# Do not export any Windows tools (if they were built)
%exclude %{_bindir}/%{?cross}dll*
%exclude %{_bindir}/%{?cross}wind*
%if %{with docs}
%{_mandir}/man1/
@ -990,6 +997,9 @@ exit 0
#----------------------------------------------------------------------------
%changelog
* Mon Mar 07 2022 Nick Clifton <nickc@redhat.com> - 2.35.2-18
- Do not export any windows tools (if they were built). (#2057638)
* Mon Jan 24 2022 Nick Clifton <nickc@redhat.com> - 2.35.2-17
- Add upstream patch to use the directory name in .file 0, fixes ccache FTBFS (#2043970)

View File

@ -0,0 +1,28 @@
diff -rup binutils.orig/ltmain.sh binutils-2.37/ltmain.sh
--- binutils.orig/ltmain.sh 2022-01-27 16:23:09.304207432 +0000
+++ binutils-2.37/ltmain.sh 2022-01-27 16:23:18.380143759 +0000
@@ -7103,6 +7103,7 @@ EOF
rpath="$finalize_rpath"
test "$mode" != relink && rpath="$compile_rpath$rpath"
for libdir in $rpath; do
+ case "$libdir" in /usr/lib|/usr/lib64|/usr/lib/../lib|/usr/lib/../lib64) continue;; esac
if test -n "$hardcode_libdir_flag_spec"; then
if test -n "$hardcode_libdir_separator"; then
if test -z "$hardcode_libdirs"; then
@@ -7798,6 +7799,7 @@ EOF
rpath=
hardcode_libdirs=
for libdir in $compile_rpath $finalize_rpath; do
+ case "$libdir" in /usr/lib|/usr/lib64|/usr/lib/../lib|/usr/lib/../lib64) continue;; esac
if test -n "$hardcode_libdir_flag_spec"; then
if test -n "$hardcode_libdir_separator"; then
if test -z "$hardcode_libdirs"; then
@@ -7849,6 +7851,7 @@ EOF
rpath=
hardcode_libdirs=
for libdir in $finalize_rpath; do
+ case "$libdir" in /usr/lib|/usr/lib64|/usr/lib/../lib|/usr/lib/../lib64) continue;; esac
if test -n "$hardcode_libdir_flag_spec"; then
if test -n "$hardcode_libdir_separator"; then
if test -z "$hardcode_libdirs"; then
Only in binutils-2.37: ltmain.sh.orig