With GCC 5 there might be a .rela.plt section with SHF_INFO_LINK set. Buggy binutils objdump might strip it from the section in the debug file. Ignore such differences for relocation sections and put the flag back if necessary.
Also improve the error message a little by only discarding the already matched sections if there is an prelink undo section. Otherwise we will report all sections as not matching if the file wasn't prelinked instead of just the non-matching sections.
New testfiles generated by gcc5 and binutils objdump added.
Signed-off-by: Mark Wielaard mjw@redhat.com --- src/ChangeLog | 9 +++++++++ src/unstrip.c | 34 ++++++++++++++++++++++++++++----- tests/ChangeLog | 10 ++++++++++ tests/Makefile.am | 8 ++++++-- tests/run-unstrip-test3.sh | 17 +++++++++++++++++ tests/testfile-info-link.bz2 | Bin 0 -> 2768 bytes tests/testfile-info-link.debuginfo.bz2 | Bin 0 -> 1844 bytes tests/testfile-info-link.stripped.bz2 | Bin 0 -> 2422 bytes 8 files changed, 71 insertions(+), 7 deletions(-) create mode 100755 tests/run-unstrip-test3.sh create mode 100755 tests/testfile-info-link.bz2 create mode 100755 tests/testfile-info-link.debuginfo.bz2 create mode 100755 tests/testfile-info-link.stripped.bz2
diff --git a/src/ChangeLog b/src/ChangeLog index 632330c..a0c32fa 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,12 @@ +2015-07-29 Mark Wielaard mjw@redhat.com + + * unstrip.c (sections_flags_match): New function. + (sections_match): Use sections_flags_match. + (find_alloc_sections_prelink): Only clear matched sections if there + is an undo section. + (copy_elided_sections): Add SHF_INFO_LINK to shdr_mem.sh_flags if + necessary. + 2015-06-27 Pino Toscano toscano.pino@tiscali.it
* src/strings.c: Define MAP_POPULATE if not defined already. diff --git a/src/unstrip.c b/src/unstrip.c index 4a8e5fa..8833094 100644 --- a/src/unstrip.c +++ b/src/unstrip.c @@ -867,12 +867,28 @@ compare_symbols_output (const void *a, const void *b)
#undef CMP
+/* Return true if the flags of the sections match, ignoring the SHF_INFO_LINK + flag if the section contains relocation information. */ +static bool +sections_flags_match (Elf64_Xword sh_flags1, Elf64_Xword sh_flags2, + Elf64_Word sh_type) +{ + if (sh_type == SHT_REL || sh_type == SHT_RELA) + { + sh_flags1 &= ~SHF_INFO_LINK; + sh_flags2 &= ~SHF_INFO_LINK; + } + + return sh_flags1 == sh_flags2; +} + /* Return true iff the flags, size, and name match. */ static bool sections_match (const struct section *sections, size_t i, const GElf_Shdr *shdr, const char *name) { - return (sections[i].shdr.sh_flags == shdr->sh_flags + return (sections_flags_match (sections[i].shdr.sh_flags, shdr->sh_flags, + sections[i].shdr.sh_type) && (sections[i].shdr.sh_size == shdr->sh_size || (sections[i].shdr.sh_size < shdr->sh_size && section_can_shrink (§ions[i].shdr))) @@ -930,10 +946,6 @@ find_alloc_sections_prelink (Elf *debug, Elf_Data *debug_shstrtab, struct section *sections, size_t nalloc, size_t nsections) { - /* Clear assignments that might have been bogus. */ - for (size_t i = 0; i < nalloc; ++i) - sections[i].outscn = NULL; - Elf_Scn *undo = NULL; for (size_t i = nalloc; i < nsections; ++i) { @@ -952,6 +964,10 @@ find_alloc_sections_prelink (Elf *debug, Elf_Data *debug_shstrtab, size_t undo_nalloc = 0; if (undo != NULL) { + /* Clear assignments that might have been bogus. */ + for (size_t i = 0; i < nalloc; ++i) + sections[i].outscn = NULL; + Elf_Data *undodata = elf_rawdata (undo, NULL); ELF_CHECK (undodata != NULL, _("cannot read '.gnu.prelink_undo' section: %s")); @@ -1500,6 +1516,14 @@ more sections in stripped file than debug file -- arguments reversed?")); shdr_mem.sh_size = sec->shdr.sh_size; shdr_mem.sh_info = sec->shdr.sh_info; shdr_mem.sh_link = sec->shdr.sh_link; + + /* Buggy binutils objdump might have stripped the SHF_INFO_LINK + put it back if necessary. */ + if ((sec->shdr.sh_type == SHT_REL || sec->shdr.sh_type == SHT_RELA) + && sec->shdr.sh_flags != shdr_mem.sh_flags + && (sec->shdr.sh_flags & SHF_INFO_LINK) != 0) + shdr_mem.sh_flags |= SHF_INFO_LINK; + if (sec->shdr.sh_link != SHN_UNDEF) shdr_mem.sh_link = ndx_section[sec->shdr.sh_link - 1]; if (shdr_mem.sh_flags & SHF_INFO_LINK) diff --git a/tests/ChangeLog b/tests/ChangeLog index 90b9a0a..109a305 100644 --- a/tests/ChangeLog +++ b/tests/ChangeLog @@ -1,3 +1,13 @@ +2015-07-29 Mark Wielaard mjw@redhat.com + + * run-unstrip-test3.sh: New test. + * testfile-info-link.bz2: New file. + * testfile-info-link.debuginfo.bz2: Likewise. + * testfile-info-link.stripped.bz2: Likewise. + * Makefile.am (TESTS): Add run-unstrip-test3.sh. + (EXTRA_DIST): Add run-unstrip-test3.sh, testfile-info-link.bz2, + testfile-info-link.debuginfo.bz2, testfile-info-link.stripped.bz2. + 2015-06-27 Pino Toscano toscano.pino@tiscali.it
* tests/run-deleted.sh: Skip when detecting a not implemented diff --git a/tests/Makefile.am b/tests/Makefile.am index 55241c7..62e7b7c 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -78,7 +78,8 @@ TESTS = run-arextract.sh run-arsymtest.sh newfile test-nlist \ run-strip-test6.sh run-strip-test7.sh run-strip-test8.sh \ run-strip-test9.sh run-strip-test10.sh \ run-strip-groups.sh run-strip-reloc.sh \ - run-unstrip-test.sh run-unstrip-test2.sh run-unstrip-M.sh \ + run-unstrip-test.sh run-unstrip-test2.sh \ + run-unstrip-test3.sh run-unstrip-M.sh \ run-ecp-test.sh run-ecp-test2.sh run-alldts.sh \ run-elflint-test.sh run-elflint-self.sh run-ranlib-test.sh \ run-ranlib-test2.sh run-ranlib-test3.sh run-ranlib-test4.sh \ @@ -161,7 +162,10 @@ EXTRA_DIST = run-arextract.sh run-arsymtest.sh \ run-strip-test9.sh run-strip-test10.sh \ run-strip-reloc.sh hello_i386.ko.bz2 hello_x86_64.ko.bz2 \ hello_ppc64.ko.bz2 hello_s390.ko.bz2 hello_aarch64.ko.bz2 \ - run-unstrip-test.sh run-unstrip-test2.sh run-unstrip-M.sh\ + run-unstrip-test.sh run-unstrip-test2.sh \ + testfile-info-link.bz2 testfile-info-link.debuginfo.bz2 \ + testfile-info-link.stripped.bz2 run-unstrip-test3.sh \ + run-unstrip-M.sh \ run-elflint-self.sh run-ranlib-test.sh run-ranlib-test2.sh \ run-ranlib-test3.sh run-ranlib-test4.sh \ run-addrscopes.sh run-strings-test.sh run-funcscopes.sh \ diff --git a/tests/run-unstrip-test3.sh b/tests/run-unstrip-test3.sh new file mode 100755 index 0000000..5459e72 --- /dev/null +++ b/tests/run-unstrip-test3.sh @@ -0,0 +1,17 @@ +# Buggy binutils objdump might strip SHF_INFO_LINK from relocation sections. +# With gcc5 we might have a .rela.plt section with that flag set. +# +# int main() +# { +# return 0; +# } +# +# gcc -o testfile-info-link -g testprog.c +# objcopy --only-keep-debug testfile-info-link testfile-info-link.debuginfo +# eu-strip --strip-debug -o testfile-info-link.stripped testfile-info-link + +original=testfile-info-link +stripped=testfile-info-link.stripped +debugfile=testfile-info-link.debuginfo + +. $srcdir/run-unstrip-test.sh diff --git a/tests/testfile-info-link.bz2 b/tests/testfile-info-link.bz2 new file mode 100755 index 0000000000000000000000000000000000000000..073b761433550d72635dfd6462e23faf76e294d6 GIT binary patch literal 2768 zcmV;>3NQ6ST4*^jL0KkKSs}d3dH@OyfB*mg|Ns8~|NH;{|L_0*-|+u$%=FnzNy+WZ zYTjReZ{OevBs)HkCt9yGZ!x^nw{pC80j8YjX{1dB88J^GJx%JT`jZs&o>A&~Pe{|$ z^l3Io$)iJPO_F+so~Nm_n@vHZYCT438f`(RsPRuo^&U_F(Deh#8fXm~0f;mrXk<+o z5E5+$l>I5>MnD=e8X6h^$OBA+5C(u`05lI!+JFE601X2`dYWmV874v^YI!k2Y2`mi z8k#XSra`8LG|&Lh07sDwnE{Z(FaQ$>FeZaW8cfgu7!xLjm_ZX1QZcC7WGAVnnqZg{ zOd*09Fqjhn1i&VmWMX7sMutrpGHHk~03!i0FcU^55WqkNng&BghJXfuX`sXmhJXV= z05WI*831I{BTX3^4FCWd0Ad<6(+Q!10z{EC)TgJWsp+ZY(WGegHc^0>6HJd$pbU)$ z&?cA@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ile-info-link.debuginfo.bz2 b/tests/testfile-info-link.debuginfo.bz2 new file mode 100755 index 0000000000000000000000000000000000000000..3225d19fef5123667089b509e1f91882bba852e2 GIT binary patch literal 1844 zcmV-42g~?ET4*^jL0KkKS<gigRsaXP|NsC0|Ns8~_xu0<|E2%`-}2leMD*B9Nk~jg zXu=CkW!&HfT-!_GZtWTcR?XG`RvINTX_OjjJ*s+oL)1?~dJRklP{KV!OpO{cVln{H zlT8L_5roL~9wf-n%}pCori`AW0F*!?dJ(3Yn3*VgCQndk01W^D27mwnG6sME0iXZ? z8UWga4GkJ;p_3y<Lqkji&<qnMjSQJGG|0rr&;SM#2x4L~G{^%9pu!jc(<nsMJfrlH zpgkb;Kmnnq5C8x)02%-QVrUu}01XBpGy^~bL=6oZX`z!NMngkP1kel<CXEc4GBn7< z$j|@=69{5rGBn5o382Cl0Fe?AGH5hU(x#0DjF~+qng-Hh27}bl)6@+EAOJFGXaSHm zpay_FKmdAxGmh?#gzZ#vARriiz7BB=7|Nuj6A(Zx`9OxARVhp-kWAtgB4^A-ptNqA zsjf{5dJdZO0+fL<kTR%?WU^FcYR4$me{|kC&#GkI1}ie)!_#G>B4SZXlt42E42;P| zOf*&eD%V|THeAV(DZz09o`IG*49rYT$!bYU6uE-rN^}#;kPjEYRpFQch+ru(aU(-4 z=Lf76RQ%;#8z~*aaJ$IyFe)T}d<qK~C?G(oSttf(MB)vfRvogS07?KkPq}FT03FAZ z^pV?!ppBGD0MY1a&*`ALiHa-;S&;r5-;<dBU0ENljeqy;`1D-d-Qn4QVUjGtg%OMh zG9elQ!Sr9ThBgAnK=2}L2HOE{SOPn?fi0s-`vi{Vwjl_t8mNT`dlrZYg$?mq7K;GK zYR6khK`atYi2&LYXy)36n?g@T!UWi~A`%vh5TS&_tZZ_Sob&Eb4&*8(uTlnNi9sR= zCQT|f5g0k-hKZXrYMO4j+u>f?EFvSX6^Mq6{?)8VXl$m3wJ6uAg?-9r&$ew9s9jZ% zC!D$QB{FQ<piNVz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kB!=o*h)F3D z&7+4oay|%6GFx2BY)p~CY70`Tr#i}vh*pWL>+G3n#Az&%yM19YCFG!O@tMhAmb~hj zm6?j!Okg#$MheRbHcuR*T%eZ_81+(s%Z${_Rd{P;DKNk;Fd2zth7tiqOv!}|A#EZn zol4MUW80{WXqg5KM5LORI5A9Z>l$2HG1Y;M3Q?BbMOBV$Sz7F2YpVrb3s&n0z5uO3 zOY+=_vWpWN5U!c6m)u@O5+zKjpu+3XATl{|74wxGjd?J)gLGtJ#4#ASO9N^B?4jSk z803`K%b0I{YE>~&l!B^KxT?xm*Z;NGLsEuP_Pxr}yZ0vdzHwD+hHx9R20n(valqM+ i<fmbxHC-@dC38LSDe#2nzW4`!#oUoj6eKgzL{)(K&sHe_
literal 0 HcmV?d00001
diff --git a/tests/testfile-info-link.stripped.bz2 b/tests/testfile-info-link.stripped.bz2 new file mode 100755 index 0000000000000000000000000000000000000000..dcbc9a2b6be7d017751c4234cf45346faaea9d16 GIT binary patch literal 2422 zcmV-+35oVXT4*^jL0KkKS)k8^_5cXxfB*mg|Nqwi|NH;<|L_0z-|+u$%wX9}Ny+W) zYR+GOZ_nTe9PZ95<2CDcbv6$Z+L(H!wcMTX(Gy9K&_+q>Y=pp!CWon@GH7T638T_I zOpKZh0i!_EKmgN5Y6B*K1JnkZ8Z-k#O*9Qn2$-5^X^>O&NtrQB)X}v8pfmu`G-v<- z007Vdri}mq^#B0S0001J4G<<lCTdU8OrEBIWYM4i8UO$d00003KmY?k00000X`lem zG#Uv_5(t<Go*^<!(^Jw9B-7N;0}yGUpu}Vi1|g#$0iZGf05kwJ00Tg1XwU);83QJO zGBjzR1574E5YtA3KmZyvU`Ck$Gz^1H0LU5|14AZ228{p#rUFGMgaFZ?^#B0S4FQnQ z&;SM?02u%P4Gcihrhpm%(Vzwp#LzU*2G#R2AhFc$!Zwuj`B)FA=w$5)2s^iL<LP-J zCK5nN2?HePPUEXc#x6r+V>V6dR1;2EFT1r(4DTW1Sx}|sG$iSaPCH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Xm&HsuqIs#J*M@ znS}QlGJFz=1c9)LiJ=q&;$$;lFAEIMm_-GGL2#;K6kyL}VonF=^76<|0q{yoO~pWo z0Z0%KKtdof8j0|UrpF`@YDi1~VBv!8%~_ZMC{@}iIw3Rx%5_Vhqf)VLb%Nj`7)B<3 z^9Hq*265Q6UggsHFic=Qto=LXgFsGS#Ht^*sawO(LJdlg(1LJ>Nyp+VpyoM55WrY{ zt{_z5+L2s);<gJ}EC^VTa{MqBAw#uVoGc2M%^BKdrmCqd7*@5)pNDSU9MTe$7+m_2 zYOy3oC3;a~dElbto9aZR-m5uFrfXgb2Le;6AAmoCX-Lzn|5Y7ph1AqX4W;n}*+L-7 z8D<eM)V+DVO3L^i*d-W^(9N@05={j(-KiG$3svlJ(gl9ev|g$u-9j*$MrgT=yeM!c z-%|2_kftSFV!hGGfS|mplC;|a4K`ELY!m=-4;$${pZmd!lZ$=kX{_CtT@F%1w$AY2 obO>yzhagMmcMz9o?zaiUY1n1g!@W!!Zt&n;$rRy2LW4dN*q&QO82|tP
literal 0 HcmV?d00001
On Wed, 2015-07-29 at 18:05 +0200, Mark Wielaard wrote:
With GCC 5 there might be a .rela.plt section with SHF_INFO_LINK set. Buggy binutils objdump might strip it from the section in the debug file. Ignore such differences for relocation sections and put the flag back if necessary.
Also improve the error message a little by only discarding the already matched sections if there is an prelink undo section. Otherwise we will report all sections as not matching if the file wasn't prelinked instead of just the non-matching sections.
New testfiles generated by gcc5 and binutils objdump added.
I pushed this to master.
elfutils-devel@lists.fedorahosted.org