From: Nick Clifton Date: Mon, 6 Jul 2020 10:22:39 +0000 (+0100) Subject: Fix failures in the GOLD testsuite when run on systems that have been built with... X-Git-Tag: binutils-2_35~43 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=afbc6db00e4d1a4a6a81ac5927a475fbfd66b630;p=thirdparty%2Fbinutils-gdb.git Fix failures in the GOLD testsuite when run on systems that have been built with annobin. * target-reloc.h (Default_comdat_behaviour:get): Ignore discarded relocs that refer to the .gnu.build.attributes section. * testsuite/script_test_7.sh: Adjust expected address of the .bss section. * testsuite/script_test_9.sh: Do not expect the .init section to immediately follow the .text section in the mapping of sections to segments. --- diff --git a/gold/ChangeLog b/gold/ChangeLog index aa53175322c..8540332d26f 100644 --- a/gold/ChangeLog +++ b/gold/ChangeLog @@ -1,3 +1,13 @@ +2020-07-06 Nick Clifton + + * target-reloc.h (Default_comdat_behaviour:get): Ignore discarded + relocs that refer to the .gnu.build.attributes section. + * testsuite/script_test_7.sh: Adjust expected address of the .bss + section. + * testsuite/script_test_9.sh: Do not expect the .init section to + immediately follow the .text section in the mapping of sections to + segments. + 2020-07-06 Nick Clifton * po/fr.po: Updated French translation. diff --git a/gold/target-reloc.h b/gold/target-reloc.h index e9e3e5b0027..d1d0e135894 100644 --- a/gold/target-reloc.h +++ b/gold/target-reloc.h @@ -136,6 +136,7 @@ class Default_comdat_behavior if (Layout::is_debug_info_section(name)) return CB_PRETEND; if (strcmp(name, ".eh_frame") == 0 + || strncmp(name, ".gnu.build.attributes", 21) == 0 || strcmp(name, ".gcc_except_table") == 0) return CB_IGNORE; return CB_ERROR; diff --git a/gold/testsuite/script_test_7.sh b/gold/testsuite/script_test_7.sh index adddf6c34b1..091875e384a 100755 --- a/gold/testsuite/script_test_7.sh +++ b/gold/testsuite/script_test_7.sh @@ -40,4 +40,4 @@ check() check script_test_7.stdout "\\.interp[ ]*PROGBITS[ ]*0*10000100" check script_test_7.stdout "\\.data[ ]*PROGBITS[ ]*0*10200000" -check script_test_7.stdout "\\.bss[ ]*NOBITS[ ]*0*10400..." +check script_test_7.stdout "\\.bss[ ]*NOBITS[ ]*0*1040...." diff --git a/gold/testsuite/script_test_9.sh b/gold/testsuite/script_test_9.sh index 3dcd3c49f3c..da75b65c93a 100755 --- a/gold/testsuite/script_test_9.sh +++ b/gold/testsuite/script_test_9.sh @@ -38,5 +38,6 @@ check() check script_test_9.stdout "LOAD .*R E " check script_test_9.stdout "LOAD .*RW " -check script_test_9.stdout "00 .*\.text .init" +check script_test_9.stdout "00 .*\.text" +check script_test_9.stdout "00 .*\.init" check script_test_9.stdout "01 .*\.data "