diff options
author | 2022-01-15 23:19:42 +0100 | |
---|---|---|
committer | 2022-01-15 23:26:47 +0100 | |
commit | 09d59da43630e66d4f7ae7145e121d06c81a2fdc (patch) | |
tree | d38afa2403f2c8feae725a979615de30ab76d4a9 | |
parent | Allow for empty patchsets (diff) | |
download | binutils-patches-09d59da43630e66d4f7ae7145e121d06c81a2fdc.tar.gz binutils-patches-09d59da43630e66d4f7ae7145e121d06c81a2fdc.tar.bz2 binutils-patches-09d59da43630e66d4f7ae7145e121d06c81a2fdc.zip |
Update patches for binutils 2.38
Signed-off-by: Andreas K. Hüttel <dilfridge@gentoo.org>
-rw-r--r-- | 9999/0001-Gentoo-gold-ld-add-support-for-poisoned-system-direc.patch | 42 | ||||
-rw-r--r-- | 9999/0002-Gentoo-libiberty-install-PIC-version-of-libiberty.a.patch | 8 | ||||
-rw-r--r-- | 9999/0003-Gentoo-add-with-extra-soversion-suffix-option.patch (renamed from 9999/0004-Gentoo-add-with-extra-soversion-suffix-option.patch) | 34 | ||||
-rw-r--r-- | 9999/0003-Gentoo-opcodes-link-against-libbfd.la-for-rpath-deps.patch | 49 | ||||
-rw-r--r-- | 9999/0004-Gentoo-Pass-hash-style-sysv-to-ld-in-the-testsuite.patch (renamed from 9999/0006-Gentoo-Pass-hash-style-sysv.patch) | 16 | ||||
-rw-r--r-- | 9999/0005-Gentoo-Give-also-libctf-optionally-a-gentoo-specific.patch (renamed from 9999/0007-Give-also-libctf-optionally-a-gentoo-specific-sovers.patch) | 94 | ||||
-rw-r--r-- | 9999/0006-Gentoo-XFAIL-15-broken-ld.gold-tests.patch (renamed from 9999/0020-XFAIL-15-broken-ld.gold-tests.patch) | 6 | ||||
-rw-r--r-- | 9999/0008-If-we-use-a-soversion-suffix-then-we-also-use-the-bd.patch | 111 |
8 files changed, 108 insertions, 252 deletions
diff --git a/9999/0001-Gentoo-gold-ld-add-support-for-poisoned-system-direc.patch b/9999/0001-Gentoo-gold-ld-add-support-for-poisoned-system-direc.patch index f7443bf..0dc4cf1 100644 --- a/9999/0001-Gentoo-gold-ld-add-support-for-poisoned-system-direc.patch +++ b/9999/0001-Gentoo-gold-ld-add-support-for-poisoned-system-direc.patch @@ -1,7 +1,7 @@ -From 8a82f64de912f26e840b20eec9d8a463fd0e242b Mon Sep 17 00:00:00 2001 +From 322deede0713506f899ee7f284a7c82ba1ec1cf7 Mon Sep 17 00:00:00 2001 From: Mike Frysinger <vapier@gentoo.org> Date: Tue, 20 Jul 2021 21:08:31 +0200 -Subject: [PATCH 1/6] Gentoo: gold/ld: add support for poisoned system +Subject: [PATCH 1/6] Gentoo: gold/ld: add support for poisoned system directories MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 @@ -43,7 +43,7 @@ Ported to binutils 2.37 Andreas K. Hütte <dilfridge@gentoo.org> 11 files changed, 146 insertions(+) diff --git a/gold/options.cc b/gold/options.cc -index 5a55bd8ba6d..f7940c75f5a 100644 +index 04be98a3e39..64439f8af7a 100644 --- a/gold/options.cc +++ b/gold/options.cc @@ -1355,6 +1355,39 @@ General_options::finalize() @@ -87,7 +87,7 @@ index 5a55bd8ba6d..f7940c75f5a 100644 if (this->shared() && this->is_static()) gold_fatal(_("-shared and -static are incompatible")); diff --git a/gold/options.h b/gold/options.h -index 757ebf18fec..490b4cbd7d4 100644 +index 9509a445e8e..a3d76b294cd 100644 --- a/gold/options.h +++ b/gold/options.h @@ -1394,6 +1394,13 @@ class General_options @@ -119,10 +119,10 @@ index 26d55a00d47..ffad464783c 100644 #undef EXTRA_SHLIB_EXTENSION diff --git a/ld/configure b/ld/configure -index c197aaef3cb..882263aa43f 100755 +index f5c329c1f12..41ec6ca73ac 100755 --- a/ld/configure +++ b/ld/configure -@@ -829,6 +829,7 @@ with_lib_path +@@ -831,6 +831,7 @@ with_lib_path enable_targets enable_64_bit_bfd with_sysroot @@ -130,7 +130,7 @@ index c197aaef3cb..882263aa43f 100755 enable_gold enable_got enable_compressed_debug_sections -@@ -1498,6 +1499,8 @@ Optional Features: +@@ -1500,6 +1501,8 @@ Optional Features: --enable-checking enable run-time checks --enable-targets alternative target configurations --enable-64-bit-bfd 64-bit support (on hosts with narrower word sizes) @@ -139,7 +139,7 @@ index c197aaef3cb..882263aa43f 100755 --enable-gold[=ARG] build gold [ARG={default,yes,no}] --enable-got=<type> GOT handling scheme (target, single, negative, multigot) -@@ -15236,7 +15239,18 @@ else +@@ -15333,7 +15336,18 @@ else fi @@ -159,10 +159,10 @@ index c197aaef3cb..882263aa43f 100755 # Check whether --enable-got was given. if test "${enable_got+set}" = set; then : diff --git a/ld/configure.ac b/ld/configure.ac -index 8ea97c43cd4..0f246db67d8 100644 +index 7f4cff079b7..57d1abff870 100644 --- a/ld/configure.ac +++ b/ld/configure.ac -@@ -106,6 +106,16 @@ AC_SUBST(use_sysroot) +@@ -102,6 +102,16 @@ AC_SUBST(use_sysroot) AC_SUBST(TARGET_SYSTEM_ROOT) AC_SUBST(TARGET_SYSTEM_ROOT_DEFINE) @@ -180,7 +180,7 @@ index 8ea97c43cd4..0f246db67d8 100644 dnl "install_as_default" is set to false if gold is the default linker. dnl "installed_linker" is the installed BFD linker name. diff --git a/ld/ld.h b/ld/ld.h -index 35fafebfaed..4152278b8f4 100644 +index f3086bf30de..90cf1ca51e5 100644 --- a/ld/ld.h +++ b/ld/ld.h @@ -162,6 +162,13 @@ typedef struct @@ -198,10 +198,10 @@ index 35fafebfaed..4152278b8f4 100644 enum endian_enum endian; diff --git a/ld/ld.texi b/ld/ld.texi -index dd8f571d4e4..0aee4a4e9f1 100644 +index fc75e9b3625..f7d46117bab 100644 --- a/ld/ld.texi +++ b/ld/ld.texi -@@ -2863,6 +2863,24 @@ string identifying the original linked file does not change. +@@ -2892,6 +2892,24 @@ string identifying the original linked file does not change. Passing @code{none} for @var{style} disables the setting from any @code{--build-id} options earlier on the command line. @@ -227,7 +227,7 @@ index dd8f571d4e4..0aee4a4e9f1 100644 @c man end diff --git a/ld/ldfile.c b/ld/ldfile.c -index 9d0af06f1f6..f4a83acca93 100644 +index 731ae5f7aed..6b67e29041b 100644 --- a/ld/ldfile.c +++ b/ld/ldfile.c @@ -117,6 +117,26 @@ ldfile_add_library_path (const char *name, bool cmdline) @@ -258,10 +258,10 @@ index 9d0af06f1f6..f4a83acca93 100644 /* Try to open a BFD for a lang_input_statement. */ diff --git a/ld/ldlex.h b/ld/ldlex.h -index 9e8bf5fb835..3baed822a22 100644 +index bc58fea73cc..cf1b015a420 100644 --- a/ld/ldlex.h +++ b/ld/ldlex.h -@@ -148,6 +148,9 @@ enum option_values +@@ -149,6 +149,9 @@ enum option_values OPTION_PRINT_OUTPUT_FORMAT, OPTION_PRINT_SYSROOT, OPTION_IGNORE_UNRESOLVED_SYMBOL, @@ -272,7 +272,7 @@ index 9e8bf5fb835..3baed822a22 100644 OPTION_POP_STATE, OPTION_DISABLE_MULTIPLE_DEFS_ABS, diff --git a/ld/ldmain.c b/ld/ldmain.c -index 42660eb9a3c..c78009b760c 100644 +index ea72b14a301..706ec9ce26e 100644 --- a/ld/ldmain.c +++ b/ld/ldmain.c @@ -321,6 +321,13 @@ main (int argc, char **argv) @@ -290,10 +290,10 @@ index 42660eb9a3c..c78009b760c 100644 /* We initialize DEMANGLING based on the environment variable COLLECT_NO_DEMANGLE. The gcc collect2 program will demangle the diff --git a/ld/lexsup.c b/ld/lexsup.c -index 00274c500d0..a19cce9967c 100644 +index 5acc47ed5a0..e78df2daf29 100644 --- a/ld/lexsup.c +++ b/ld/lexsup.c -@@ -566,6 +566,18 @@ static const struct ld_option ld_options[] = +@@ -571,6 +571,18 @@ static const struct ld_option ld_options[] = OPTION_IGNORE_UNRESOLVED_SYMBOL}, '\0', N_("SYMBOL"), N_("Unresolved SYMBOL will not cause an error or warning"), TWO_DASHES }, @@ -312,7 +312,7 @@ index 00274c500d0..a19cce9967c 100644 { {"push-state", no_argument, NULL, OPTION_PUSH_STATE}, '\0', NULL, N_("Push state of flags governing input file handling"), TWO_DASHES }, -@@ -1643,6 +1655,18 @@ parse_args (unsigned argc, char **argv) +@@ -1659,6 +1671,18 @@ parse_args (unsigned argc, char **argv) } break; @@ -332,5 +332,5 @@ index 00274c500d0..a19cce9967c 100644 input_flags.pushed = xmemdup (&input_flags, sizeof (input_flags), -- -2.31.1 +2.34.1 diff --git a/9999/0002-Gentoo-libiberty-install-PIC-version-of-libiberty.a.patch b/9999/0002-Gentoo-libiberty-install-PIC-version-of-libiberty.a.patch index 4d5ed11..72b99c0 100644 --- a/9999/0002-Gentoo-libiberty-install-PIC-version-of-libiberty.a.patch +++ b/9999/0002-Gentoo-libiberty-install-PIC-version-of-libiberty.a.patch @@ -1,4 +1,4 @@ -From 6536761c1e2756ec39fdc33c400757be3744510c Mon Sep 17 00:00:00 2001 +From 887d52771263fc6b8260b873e104bc57d54b3f5c Mon Sep 17 00:00:00 2001 From: Mike Frysinger <vapier@gentoo.org> Date: Fri, 7 Jan 2005 00:15:53 -0500 Subject: [PATCH 2/6] Gentoo: libiberty: install PIC version of libiberty.a @@ -18,10 +18,10 @@ general are fairly low, and we'd rather have things work for all of them. 1 file changed, 1 insertion(+) diff --git a/libiberty/Makefile.in b/libiberty/Makefile.in -index d19e14a2aca..cd02be1c2fb 100644 +index abef3c4601b..9dfb6b6d2b0 100644 --- a/libiberty/Makefile.in +++ b/libiberty/Makefile.in -@@ -257,6 +257,7 @@ $(TARGETLIB): $(REQUIRED_OFILES) $(EXTRA_OFILES) $(LIBOBJS) +@@ -258,6 +258,7 @@ $(TARGETLIB): $(REQUIRED_OFILES) $(EXTRA_OFILES) $(LIBOBJS) $(AR) $(AR_FLAGS) $(TARGETLIB) \ $(REQUIRED_OFILES) $(EXTRA_OFILES) $(LIBOBJS); \ $(RANLIB) $(TARGETLIB); \ @@ -30,5 +30,5 @@ index d19e14a2aca..cd02be1c2fb 100644 else true; fi; \ if [ x"$(NOASANFLAG)" != x ]; then \ -- -2.31.1 +2.34.1 diff --git a/9999/0004-Gentoo-add-with-extra-soversion-suffix-option.patch b/9999/0003-Gentoo-add-with-extra-soversion-suffix-option.patch index 1051543..b2b0bb5 100644 --- a/9999/0004-Gentoo-add-with-extra-soversion-suffix-option.patch +++ b/9999/0003-Gentoo-add-with-extra-soversion-suffix-option.patch @@ -1,7 +1,7 @@ -From 235f1f862fb9bf77e2b9f62c24db0ca801c4a057 Mon Sep 17 00:00:00 2001 +From 820a68dff1ec2eb3836727ced1b5b74bd31daa28 Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich <slyfox@gentoo.org> Date: Tue, 20 Jul 2021 21:12:38 +0200 -Subject: [PATCH 4/6] Gentoo: add --with-extra-soversion-suffix= option +Subject: [PATCH 3/6] Gentoo: add --with-extra-soversion-suffix= option MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit @@ -34,7 +34,7 @@ Ported to binutils 2.37 Andreas K. Hüttel <dilfridge@gentoo.org> 4 files changed, 29 insertions(+) diff --git a/bfd/Makefile.am b/bfd/Makefile.am -index ed2f701805d..dab3bfc8ed7 100644 +index 10dd765bec8..e3d97adfbb3 100644 --- a/bfd/Makefile.am +++ b/bfd/Makefile.am @@ -59,6 +59,8 @@ bfdinclude_HEADERS += $(INCDIR)/plugin-api.h @@ -46,7 +46,7 @@ index ed2f701805d..dab3bfc8ed7 100644 # bfd.h goes here, for now BFD_H = bfd.h -@@ -952,6 +954,9 @@ bfdver.h: $(srcdir)/version.h $(srcdir)/development.sh $(srcdir)/Makefile.in +@@ -987,6 +989,9 @@ bfdver.h: $(srcdir)/version.h $(srcdir)/development.sh $(srcdir)/Makefile.in bfd_version_string="\"$(VERSION).$${bfd_version_date}\"" ;\ bfd_soversion="$(VERSION).$${bfd_version_date}" ;\ fi ;\ @@ -57,10 +57,10 @@ index ed2f701805d..dab3bfc8ed7 100644 -e "s,@bfd_version_string@,$$bfd_version_string," \ -e "s,@bfd_version_package@,$$bfd_version_package," \ diff --git a/bfd/Makefile.in b/bfd/Makefile.in -index 12807d99760..572df143487 100644 +index f5313a2ad6f..c8cfc0474f2 100644 --- a/bfd/Makefile.in +++ b/bfd/Makefile.in -@@ -318,6 +318,7 @@ ECHO_T = @ECHO_T@ +@@ -319,6 +319,7 @@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ EXEEXT_FOR_BUILD = @EXEEXT_FOR_BUILD@ @@ -68,7 +68,7 @@ index 12807d99760..572df143487 100644 FGREP = @FGREP@ GENCAT = @GENCAT@ GMSGFMT = @GMSGFMT@ -@@ -2063,6 +2064,9 @@ bfdver.h: $(srcdir)/version.h $(srcdir)/development.sh $(srcdir)/Makefile.in +@@ -2104,6 +2105,9 @@ bfdver.h: $(srcdir)/version.h $(srcdir)/development.sh $(srcdir)/Makefile.in bfd_version_string="\"$(VERSION).$${bfd_version_date}\"" ;\ bfd_soversion="$(VERSION).$${bfd_version_date}" ;\ fi ;\ @@ -79,7 +79,7 @@ index 12807d99760..572df143487 100644 -e "s,@bfd_version_string@,$$bfd_version_string," \ -e "s,@bfd_version_package@,$$bfd_version_package," \ diff --git a/bfd/configure b/bfd/configure -index 41586f00f93..f0acf160913 100755 +index b09702f26e1..7a7c1229c99 100755 --- a/bfd/configure +++ b/bfd/configure @@ -696,6 +696,7 @@ WARN_CFLAGS @@ -88,9 +88,9 @@ index 41586f00f93..f0acf160913 100755 PKGVERSION +EXTRA_SOVERSION_SUFFIX DEBUGDIR - PLUGINS_FALSE - PLUGINS_TRUE -@@ -835,6 +836,7 @@ enable_secureplt + ENABLE_BFD_64_BIT_FALSE + ENABLE_BFD_64_BIT_TRUE +@@ -837,6 +838,7 @@ enable_secureplt enable_separate_code enable_leading_mingw64_underscores with_separate_debug_dir @@ -98,7 +98,7 @@ index 41586f00f93..f0acf160913 100755 with_pkgversion with_bugurl enable_werror -@@ -1511,6 +1513,8 @@ Optional Packages: +@@ -1513,6 +1515,8 @@ Optional Packages: --with-separate-debug-dir=DIR Look for global separate debug info in DIR [[default=LIBDIR/debug]] @@ -107,7 +107,7 @@ index 41586f00f93..f0acf160913 100755 --with-pkgversion=PKG Use PKG in the version string in place of "GNU Binutils" --with-bugurl=URL Direct users to URL to report a bug -@@ -11913,6 +11917,15 @@ fi +@@ -12013,6 +12017,15 @@ fi @@ -124,10 +124,10 @@ index 41586f00f93..f0acf160913 100755 # Check whether --with-pkgversion was given. diff --git a/bfd/configure.ac b/bfd/configure.ac -index fec067b2135..8c9ef9a04c0 100644 +index a9078965c40..3406c071fe7 100644 --- a/bfd/configure.ac +++ b/bfd/configure.ac -@@ -169,6 +169,13 @@ AC_ARG_WITH(separate-debug-dir, +@@ -168,6 +168,13 @@ AC_ARG_WITH(separate-debug-dir, [DEBUGDIR="${withval}"]) AC_SUBST(DEBUGDIR) @@ -139,8 +139,8 @@ index fec067b2135..8c9ef9a04c0 100644 +AC_SUBST(EXTRA_SOVERSION_SUFFIX) + ACX_PKGVERSION([GNU Binutils]) - ACX_BUGURL([https://www.sourceware.org/bugzilla/]) + ACX_BUGURL([https://sourceware.org/bugzilla/]) -- -2.31.1 +2.34.1 diff --git a/9999/0003-Gentoo-opcodes-link-against-libbfd.la-for-rpath-deps.patch b/9999/0003-Gentoo-opcodes-link-against-libbfd.la-for-rpath-deps.patch deleted file mode 100644 index f3c9f8e..0000000 --- a/9999/0003-Gentoo-opcodes-link-against-libbfd.la-for-rpath-deps.patch +++ /dev/null @@ -1,49 +0,0 @@ -From c55536c61ec7e4c2e983e15f51f56f7a7c340889 Mon Sep 17 00:00:00 2001 -From: Mike Frysinger <vapier@gentoo.org> -Date: Tue, 5 Jul 2016 20:24:00 +0545 -Subject: [PATCH 3/6] Gentoo: opcodes: link against libbfd.la for rpath deps - -The reason opcodes doesn't link against libbfd.la is to workaround a -libtool bug where it uses installed -L paths ahead of DESTDIR paths. -The downside is that the library itself lacks rpath tags to find the -right version of libbfd.so. - -Since Gentoo has patched the libtool bug for a while, we don't need -the workaround. Use the .la file so we get the rpath tags. - -URL: https://bugs.gentoo.org/563934 -(cherry picked from commit 662586237b0b00ee881e79b56f6234ff36e8bfe6) ---- - opcodes/configure | 2 +- - opcodes/configure.ac | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) - -diff --git a/opcodes/configure b/opcodes/configure -index a3da5987f1b..22a05245286 100755 ---- a/opcodes/configure -+++ b/opcodes/configure -@@ -12142,7 +12142,7 @@ if test "$enable_shared" = "yes"; then - SHARED_LIBADD="-Wl,`pwd`/../bfd/.libs/libbfd.sl ${SHARED_LIBADD}" - ;; - *) -- SHARED_LIBADD="-Wl,`pwd`/../bfd/.libs/libbfd.so ${SHARED_LIBADD}" -+ SHARED_LIBADD="../bfd/libbfd.la ${SHARED_LIBADD}" - ;; - esac - SHARED_DEPENDENCIES="../bfd/libbfd.la" -diff --git a/opcodes/configure.ac b/opcodes/configure.ac -index e564f067334..fb6254cd69d 100644 ---- a/opcodes/configure.ac -+++ b/opcodes/configure.ac -@@ -203,7 +203,7 @@ if test "$enable_shared" = "yes"; then - SHARED_LIBADD="-Wl,`pwd`/../bfd/.libs/libbfd.sl ${SHARED_LIBADD}" - ;; - *) -- SHARED_LIBADD="-Wl,`pwd`/../bfd/.libs/libbfd.so ${SHARED_LIBADD}" -+ SHARED_LIBADD="../bfd/libbfd.la ${SHARED_LIBADD}" - ;; - esac - SHARED_DEPENDENCIES="../bfd/libbfd.la" --- -2.31.1 - diff --git a/9999/0006-Gentoo-Pass-hash-style-sysv.patch b/9999/0004-Gentoo-Pass-hash-style-sysv-to-ld-in-the-testsuite.patch index 41b6a33..2ac5053 100644 --- a/9999/0006-Gentoo-Pass-hash-style-sysv.patch +++ b/9999/0004-Gentoo-Pass-hash-style-sysv-to-ld-in-the-testsuite.patch @@ -1,7 +1,7 @@ -From 905bf3c180f4f7fd07024eb9ff7851898593f3f8 Mon Sep 17 00:00:00 2001 +From 6e5bb8fa8e5f409e12098a922de72f6bdcc99603 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20K=2E=20H=C3=BCttel?= <dilfridge@gentoo.org> Date: Tue, 20 Jul 2021 21:15:24 +0200 -Subject: [PATCH 6/6] Gentoo: Pass --hash-style=sysv to ld in the testsuite +Subject: [PATCH 4/6] Gentoo: Pass --hash-style=sysv to ld in the testsuite --- binutils/testsuite/lib/binutils-common.exp | 2 +- @@ -9,10 +9,10 @@ Subject: [PATCH 6/6] Gentoo: Pass --hash-style=sysv to ld in the testsuite 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/binutils/testsuite/lib/binutils-common.exp b/binutils/testsuite/lib/binutils-common.exp -index 59e25df99b0..401a05b5c32 100644 +index 93603b0be68..83ae1307f2a 100644 --- a/binutils/testsuite/lib/binutils-common.exp +++ b/binutils/testsuite/lib/binutils-common.exp -@@ -1279,7 +1279,7 @@ proc run_dump_test { name {extra_options {}} } { +@@ -1303,7 +1303,7 @@ proc run_dump_test { name {extra_options {}} } { # Add -L$srcdir/$subdir so that the linker command can use # linker scripts in the source directory. @@ -22,10 +22,10 @@ index 59e25df99b0..401a05b5c32 100644 # If needed then check for, or add a -Map option. diff --git a/ld/testsuite/lib/ld-lib.exp b/ld/testsuite/lib/ld-lib.exp -index 8fd14afc63e..adbeaa3bd08 100644 +index 5c7771f7221..ff9ee6a425c 100644 --- a/ld/testsuite/lib/ld-lib.exp +++ b/ld/testsuite/lib/ld-lib.exp -@@ -167,7 +167,7 @@ proc default_ld_relocate { ld target objects } { +@@ -171,7 +171,7 @@ proc default_ld_relocate { ld target objects } { global HOSTING_EMU remote_file host delete $target @@ -34,7 +34,7 @@ index 8fd14afc63e..adbeaa3bd08 100644 } # Check to see if ld is being invoked with a non-endian output format -@@ -198,8 +198,20 @@ proc default_ld_link { ld target objects } { +@@ -202,8 +202,20 @@ proc default_ld_link { ld target objects } { set flags [big_or_little_endian] } @@ -57,5 +57,5 @@ index 8fd14afc63e..adbeaa3bd08 100644 # We don't care if we get a warning about a non-existent start -- -2.31.1 +2.34.1 diff --git a/9999/0007-Give-also-libctf-optionally-a-gentoo-specific-sovers.patch b/9999/0005-Gentoo-Give-also-libctf-optionally-a-gentoo-specific.patch index 6f1c6b3..871812a 100644 --- a/9999/0007-Give-also-libctf-optionally-a-gentoo-specific-sovers.patch +++ b/9999/0005-Gentoo-Give-also-libctf-optionally-a-gentoo-specific.patch @@ -1,29 +1,31 @@ -From d3cd41f5c7e405a8db5e85a7be9dfc42d44ef1b8 Mon Sep 17 00:00:00 2001 +From f4db43e58d2f3a6e66b15ff2b25ac6850199399b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20K=2E=20H=C3=BCttel?= <dilfridge@gentoo.org> Date: Sat, 24 Jul 2021 15:20:16 +0200 -Subject: [PATCH 1/2] Give also libctf optionally a gentoo-specific soversion +Subject: [PATCH 5/6] Gentoo: Give also libctf optionally a gentoo-specific + soversion --- - libctf/Makefile.am | 13 ++++++++++++- - libctf/Makefile.in | 8 +++++++- - libctf/configure | 31 +++++++++++++++++++++++++++++-- - libctf/configure.ac | 8 ++++++++ - 4 files changed, 56 insertions(+), 4 deletions(-) + libctf/Makefile.am | 14 +++++++++++++- + libctf/Makefile.in | 9 ++++++++- + libctf/configure | 35 +++++++++++++++++++++++++++++++++-- + libctf/configure.ac | 10 ++++++++++ + 4 files changed, 64 insertions(+), 4 deletions(-) diff --git a/libctf/Makefile.am b/libctf/Makefile.am -index e586d25fb37..eabc7fa8394 100644 +index 27e90f0ba36..4990a20efa3 100644 --- a/libctf/Makefile.am +++ b/libctf/Makefile.am -@@ -21,6 +21,8 @@ ACLOCAL_AMFLAGS = -I .. -I ../config -I ../bfd - - AUTOMAKE_OPTIONS = dejagnu foreign no-texinfo.tex +@@ -26,6 +26,9 @@ info_TEXINFOS = + DISTCLEANFILES = + MAINTAINERCLEANFILES = +EXTRA_SOVERSION_SUFFIX = @EXTRA_SOVERSION_SUFFIX@ ++BFD_VERSION = @BFD_VERSION@ + # This is where we get zlib from. zlibdir is -L../zlib and zlibinc is # -I../zlib, unless we were configured with --with-system-zlib, in which # case both are empty. -@@ -41,8 +43,17 @@ include_HEADERS = +@@ -46,8 +49,17 @@ include_HEADERS = noinst_LTLIBRARIES = libctf.la libctf-nobfd.la endif @@ -31,22 +33,30 @@ index e586d25fb37..eabc7fa8394 100644 +# a supplement to the soversion. So we need to switch tracks and be creative. + +if HAVE_EXTRA_SOVERSION_SUFFIX -+gentoo_ctf_soversion = 0.0.0.$(EXTRA_SOVERSION_SUFFIX) ++gentoo_ctf_soversion = "$(BFD_VERSION).$(EXTRA_SOVERSION_SUFFIX)" +else +gentoo_ctf_soversion = 0.0.0 +endif + libctf_nobfd_la_LIBADD = @CTF_LIBADD@ $(ZLIB) --libctf_nobfd_la_LDFLAGS = -version-info 0:0:0 @SHARED_LDFLAGS@ @VERSION_FLAGS@ -+libctf_nobfd_la_LDFLAGS = -release $(gentoo_ctf_soversion) @SHARED_LDFLAGS@ @VERSION_FLAGS@ +-libctf_ldflags_nover = -version-info 0:0:0 @SHARED_LDFLAGS@ ++libctf_ldflags_nover = -release $(gentoo_ctf_soversion) @SHARED_LDFLAGS@ + libctf_nobfd_la_LDFLAGS = $(libctf_ldflags_nover) @VERSION_FLAGS_NOBFD@ libctf_nobfd_la_CPPFLAGS = $(AM_CPPFLAGS) -DNOBFD=1 libctf_nobfd_la_SOURCES = ctf-archive.c ctf-dump.c ctf-create.c ctf-decl.c ctf-error.c \ - ctf-hash.c ctf-labels.c ctf-dedup.c ctf-link.c ctf-lookup.c \ diff --git a/libctf/Makefile.in b/libctf/Makefile.in -index 5cfa100f9cc..b528781af97 100644 +index 3b5ab73324e..10029107a05 100644 --- a/libctf/Makefile.in +++ b/libctf/Makefile.in -@@ -338,6 +338,7 @@ EXEEXT = @EXEEXT@ +@@ -381,6 +381,7 @@ AUTOCONF = @AUTOCONF@ + AUTOHEADER = @AUTOHEADER@ + AUTOMAKE = @AUTOMAKE@ + AWK = @AWK@ ++BFD_VERSION = @BFD_VERSION@ + CATALOGS = @CATALOGS@ + CATOBJEXT = @CATOBJEXT@ + CC = @CC@ +@@ -403,6 +404,7 @@ EXEEXT = @EXEEXT@ # Setup the testing framework, if you have one EXPECT = expect @@ -54,7 +64,7 @@ index 5cfa100f9cc..b528781af97 100644 FGREP = @FGREP@ GENCAT = @GENCAT@ GMSGFMT = @GMSGFMT@ -@@ -469,8 +470,13 @@ AM_CFLAGS = -std=gnu99 @ac_libctf_warn_cflags@ @warn@ @c_warn@ @WARN_PEDANTIC@ @ +@@ -540,8 +542,13 @@ AM_CFLAGS = -std=gnu99 @ac_libctf_warn_cflags@ @warn@ @c_warn@ @WARN_PEDANTIC@ @ @INSTALL_LIBBFD_FALSE@include_HEADERS = @INSTALL_LIBBFD_TRUE@include_HEADERS = $(INCDIR)/ctf.h $(INCDIR)/ctf-api.h @INSTALL_LIBBFD_FALSE@noinst_LTLIBRARIES = libctf.la libctf-nobfd.la @@ -62,28 +72,29 @@ index 5cfa100f9cc..b528781af97 100644 + +# libctf by default uses libtool versioning. Unfortunately that keeps us from adding +# a supplement to the soversion. So we need to switch tracks and be creative. -+@HAVE_EXTRA_SOVERSION_SUFFIX_TRUE@gentoo_ctf_soversion = 0.0.0.$(EXTRA_SOVERSION_SUFFIX) ++@HAVE_EXTRA_SOVERSION_SUFFIX_TRUE@gentoo_ctf_soversion = "$(BFD_VERSION).$(EXTRA_SOVERSION_SUFFIX)" libctf_nobfd_la_LIBADD = @CTF_LIBADD@ $(ZLIB) --libctf_nobfd_la_LDFLAGS = -version-info 0:0:0 @SHARED_LDFLAGS@ @VERSION_FLAGS@ -+libctf_nobfd_la_LDFLAGS = -release $(gentoo_ctf_soversion) @SHARED_LDFLAGS@ @VERSION_FLAGS@ +-libctf_ldflags_nover = -version-info 0:0:0 @SHARED_LDFLAGS@ ++libctf_ldflags_nover = -release $(gentoo_ctf_soversion) @SHARED_LDFLAGS@ + libctf_nobfd_la_LDFLAGS = $(libctf_ldflags_nover) @VERSION_FLAGS_NOBFD@ libctf_nobfd_la_CPPFLAGS = $(AM_CPPFLAGS) -DNOBFD=1 libctf_nobfd_la_SOURCES = ctf-archive.c ctf-dump.c ctf-create.c \ - ctf-decl.c ctf-error.c ctf-hash.c ctf-labels.c ctf-dedup.c \ diff --git a/libctf/configure b/libctf/configure -index 82bcf13a606..e961f637a69 100755 +index c56ac218213..623e71477b3 100755 --- a/libctf/configure +++ b/libctf/configure -@@ -643,6 +643,9 @@ CTF_LIBADD - SHARED_LDFLAGS +@@ -646,6 +646,10 @@ BUILD_INFO_FALSE + BUILD_INFO_TRUE NEED_CTF_QSORT_R_FALSE NEED_CTF_QSORT_R_TRUE ++BFD_VERSION +HAVE_EXTRA_SOVERSION_SUFFIX_FALSE +HAVE_EXTRA_SOVERSION_SUFFIX_TRUE +EXTRA_SOVERSION_SUFFIX ENABLE_LIBCTF_HASH_DEBUGGING_FALSE ENABLE_LIBCTF_HASH_DEBUGGING_TRUE zlibinc -@@ -804,6 +807,7 @@ enable_maintainer_mode +@@ -807,6 +811,7 @@ enable_maintainer_mode enable_install_libbfd with_system_zlib enable_libctf_hash_debugging @@ -91,7 +102,7 @@ index 82bcf13a606..e961f637a69 100755 ' ac_precious_vars='build_alias host_alias -@@ -1461,6 +1465,8 @@ Optional Packages: +@@ -1464,6 +1469,8 @@ Optional Packages: both] --with-gnu-ld assume the C compiler uses GNU ld [default=no] --with-system-zlib use installed libz @@ -100,25 +111,25 @@ index 82bcf13a606..e961f637a69 100755 Some influential environment variables: CC C compiler command -@@ -11586,7 +11592,7 @@ else +@@ -11629,7 +11636,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF --#line 11589 "configure" -+#line 11607 "configure" +-#line 11632 "configure" ++#line 11639 "configure" #include "confdefs.h" #if HAVE_DLFCN_H -@@ -11692,7 +11698,7 @@ else +@@ -11735,7 +11742,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF --#line 11695 "configure" -+#line 11713 "configure" +-#line 11738 "configure" ++#line 11745 "configure" #include "confdefs.h" #if HAVE_DLFCN_H -@@ -12899,6 +12905,23 @@ else +@@ -12942,6 +12949,26 @@ else fi @@ -139,10 +150,13 @@ index 82bcf13a606..e961f637a69 100755 +fi + + ++BFD_VERSION=$(${srcdir}/../bfd/configure --version | sed -n -e '1s,.* ,,p') ++ ++ # Similar to GDB_AC_CHECK_BFD. OLD_CFLAGS=$CFLAGS OLD_LDFLAGS=$LDFLAGS -@@ -13657,6 +13680,10 @@ if test -z "${ENABLE_LIBCTF_HASH_DEBUGGING_TRUE}" && test -z "${ENABLE_LIBCTF_HA +@@ -13834,6 +13861,10 @@ if test -z "${ENABLE_LIBCTF_HASH_DEBUGGING_TRUE}" && test -z "${ENABLE_LIBCTF_HA as_fn_error $? "conditional \"ENABLE_LIBCTF_HASH_DEBUGGING\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi @@ -154,10 +168,10 @@ index 82bcf13a606..e961f637a69 100755 if test -z "${NEED_CTF_QSORT_R_TRUE}" && test -z "${NEED_CTF_QSORT_R_FALSE}"; then as_fn_error $? "conditional \"NEED_CTF_QSORT_R\" was never defined. diff --git a/libctf/configure.ac b/libctf/configure.ac -index 80644b89d67..f7e6180afd8 100644 +index 4996edd5b70..103fc8b9d33 100644 --- a/libctf/configure.ac +++ b/libctf/configure.ac -@@ -77,6 +77,14 @@ if test "${enable_libctf_hash_debugging}" = yes; then +@@ -78,6 +78,16 @@ if test "${enable_libctf_hash_debugging}" = yes; then fi AM_CONDITIONAL(ENABLE_LIBCTF_HASH_DEBUGGING, test "${enable_libctf_hash_debugging}" = yes) @@ -169,9 +183,11 @@ index 80644b89d67..f7e6180afd8 100644 +AC_SUBST(EXTRA_SOVERSION_SUFFIX) +AM_CONDITIONAL([HAVE_EXTRA_SOVERSION_SUFFIX], [test -n "${with_extra_soversion_suffix}"]) + ++AC_SUBST(BFD_VERSION, $(${srcdir}/../bfd/configure --version | sed -n -e '1s,.* ,,p'), [Version of the accompanying bfd linker]) ++ # Similar to GDB_AC_CHECK_BFD. OLD_CFLAGS=$CFLAGS OLD_LDFLAGS=$LDFLAGS -- -2.31.1 +2.34.1 diff --git a/9999/0020-XFAIL-15-broken-ld.gold-tests.patch b/9999/0006-Gentoo-XFAIL-15-broken-ld.gold-tests.patch index 777390f..b9435e9 100644 --- a/9999/0020-XFAIL-15-broken-ld.gold-tests.patch +++ b/9999/0006-Gentoo-XFAIL-15-broken-ld.gold-tests.patch @@ -1,7 +1,7 @@ -From 6f9a3d6ffa2bcf91bc047055848591dab77c0f11 Mon Sep 17 00:00:00 2001 +From 66686e75515c742e573d25b74ce324e3d1acad08 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20K=2E=20H=C3=BCttel?= <dilfridge@gentoo.org> Date: Sat, 31 Jul 2021 01:18:18 +0200 -Subject: [PATCH] Gentoo: XFAIL 15 broken ld.gold tests +Subject: [PATCH 6/6] Gentoo: XFAIL 15 broken ld.gold tests It seems like either the tests or ld.gold in general cannot handle compilers built with --enable-default-pie. No fix yet, so let's ignore @@ -73,5 +73,5 @@ index 7b4b7832d38..765c2b73140 100644 AUTOMAKE_OPTIONS = foreign -Wno-portability -- -2.31.1 +2.34.1 diff --git a/9999/0008-If-we-use-a-soversion-suffix-then-we-also-use-the-bd.patch b/9999/0008-If-we-use-a-soversion-suffix-then-we-also-use-the-bd.patch deleted file mode 100644 index b88f50e..0000000 --- a/9999/0008-If-we-use-a-soversion-suffix-then-we-also-use-the-bd.patch +++ /dev/null @@ -1,111 +0,0 @@ -From 235448cc5c53641417e17fd39ced95a21053c8ca Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Andreas=20K=2E=20H=C3=BCttel?= <dilfridge@gentoo.org> -Date: Sat, 24 Jul 2021 19:25:32 +0200 -Subject: [PATCH 2/2] If we use a soversion suffix, then we also use the bdf - version as soversion - ---- - libctf/Makefile.am | 3 ++- - libctf/Makefile.in | 3 ++- - libctf/configure | 8 ++++++-- - libctf/configure.ac | 2 ++ - 4 files changed, 12 insertions(+), 4 deletions(-) - -diff --git a/libctf/Makefile.am b/libctf/Makefile.am -index eabc7fa8394..e1304e8e89b 100644 ---- a/libctf/Makefile.am -+++ b/libctf/Makefile.am -@@ -22,6 +22,7 @@ ACLOCAL_AMFLAGS = -I .. -I ../config -I ../bfd - AUTOMAKE_OPTIONS = dejagnu foreign no-texinfo.tex - - EXTRA_SOVERSION_SUFFIX = @EXTRA_SOVERSION_SUFFIX@ -+BFD_VERSION = @BFD_VERSION@ - - # This is where we get zlib from. zlibdir is -L../zlib and zlibinc is - # -I../zlib, unless we were configured with --with-system-zlib, in which -@@ -47,7 +48,7 @@ endif - # a supplement to the soversion. So we need to switch tracks and be creative. - - if HAVE_EXTRA_SOVERSION_SUFFIX --gentoo_ctf_soversion = 0.0.0.$(EXTRA_SOVERSION_SUFFIX) -+gentoo_ctf_soversion = "$(BFD_VERSION).$(EXTRA_SOVERSION_SUFFIX)" - else - gentoo_ctf_soversion = 0.0.0 - endif -diff --git a/libctf/Makefile.in b/libctf/Makefile.in -index b528781af97..18d482411e8 100644 ---- a/libctf/Makefile.in -+++ b/libctf/Makefile.in -@@ -316,6 +316,7 @@ AUTOCONF = @AUTOCONF@ - AUTOHEADER = @AUTOHEADER@ - AUTOMAKE = @AUTOMAKE@ - AWK = @AWK@ -+BFD_VERSION = @BFD_VERSION@ - CATALOGS = @CATALOGS@ - CATOBJEXT = @CATOBJEXT@ - CC = @CC@ -@@ -474,7 +475,7 @@ AM_CFLAGS = -std=gnu99 @ac_libctf_warn_cflags@ @warn@ @c_warn@ @WARN_PEDANTIC@ @ - - # libctf by default uses libtool versioning. Unfortunately that keeps us from adding - # a supplement to the soversion. So we need to switch tracks and be creative. --@HAVE_EXTRA_SOVERSION_SUFFIX_TRUE@gentoo_ctf_soversion = 0.0.0.$(EXTRA_SOVERSION_SUFFIX) -+@HAVE_EXTRA_SOVERSION_SUFFIX_TRUE@gentoo_ctf_soversion = "$(BFD_VERSION).$(EXTRA_SOVERSION_SUFFIX)" - libctf_nobfd_la_LIBADD = @CTF_LIBADD@ $(ZLIB) - libctf_nobfd_la_LDFLAGS = -release $(gentoo_ctf_soversion) @SHARED_LDFLAGS@ @VERSION_FLAGS@ - libctf_nobfd_la_CPPFLAGS = $(AM_CPPFLAGS) -DNOBFD=1 -diff --git a/libctf/configure b/libctf/configure -index e961f637a69..520d3a5cb3e 100755 ---- a/libctf/configure -+++ b/libctf/configure -@@ -643,6 +643,7 @@ CTF_LIBADD - SHARED_LDFLAGS - NEED_CTF_QSORT_R_FALSE - NEED_CTF_QSORT_R_TRUE -+BFD_VERSION - HAVE_EXTRA_SOVERSION_SUFFIX_FALSE - HAVE_EXTRA_SOVERSION_SUFFIX_TRUE - EXTRA_SOVERSION_SUFFIX -@@ -11592,7 +11593,7 @@ else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF --#line 11607 "configure" -+#line 11608 "configure" - #include "confdefs.h" - - #if HAVE_DLFCN_H -@@ -11698,7 +11699,7 @@ else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF --#line 11713 "configure" -+#line 11714 "configure" - #include "confdefs.h" - - #if HAVE_DLFCN_H -@@ -12922,6 +12923,9 @@ else - fi - - -+BFD_VERSION=$(${srcdir}/../bfd/configure --version | sed -n -e '1s,.* ,,p') -+ -+ - # Similar to GDB_AC_CHECK_BFD. - OLD_CFLAGS=$CFLAGS - OLD_LDFLAGS=$LDFLAGS -diff --git a/libctf/configure.ac b/libctf/configure.ac -index f7e6180afd8..5306e5499ec 100644 ---- a/libctf/configure.ac -+++ b/libctf/configure.ac -@@ -85,6 +85,8 @@ AC_ARG_WITH(extra-soversion-suffix, - AC_SUBST(EXTRA_SOVERSION_SUFFIX) - AM_CONDITIONAL([HAVE_EXTRA_SOVERSION_SUFFIX], [test -n "${with_extra_soversion_suffix}"]) - -+AC_SUBST(BFD_VERSION, $(${srcdir}/../bfd/configure --version | sed -n -e '1s,.* ,,p'), [Version of the accompanying bfd linker]) -+ - # Similar to GDB_AC_CHECK_BFD. - OLD_CFLAGS=$CFLAGS - OLD_LDFLAGS=$LDFLAGS --- -2.31.1 - |