This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
PIE and --(no-)export-dynamic
- From: Peter Hjalmarsson <xake at rymdraket dot net>
- To: binutils <binutils at sourceware dot org>
- Date: Sat, 20 Mar 2010 14:32:59 +0100
- Subject: PIE and --(no-)export-dynamic
Should the -export-dynamic/--no-export-dynamic do any difference on a
PIE file?
As an example lets take ld/testsuite/ld-elfvers/vers4.c.
compile it:
$ gcc -o test1 -Wl,--no-export-dynamic vers4.c
$ gcc -o test2 -fPIE -pie -Wl,--no-export-dynamic vers4.c
If you objdump -T the resulting files you will see that test2 still
exports foo@@VERS_2.0 along other things (like main).
Is this a expected behaviour or is it a bug?
(this on a F13-box running ld 2.20.51.0.2, can reproduce on a Gentoo box
running 2.20.1)
Regards
Peter