This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
Re: [Bug dynamic-link/17711] New: copy relocations against protected symbols don't work
- From: OndÅej BÃlka <neleai at seznam dot cz>
- To: "hjl.tools at gmail dot com" <sourceware-bugzilla at sourceware dot org>
- Cc: glibc-bugs at sourceware dot org
- Date: Sun, 14 Dec 2014 16:05:20 +0100
- Subject: Re: [Bug dynamic-link/17711] New: copy relocations against protected symbols don't work
- Authentication-results: sourceware.org; auth=none
- References: <bug-17711-131 at http dot sourceware dot org/bugzilla/>
On Sun, Dec 14, 2014 at 12:43:50PM +0000, hjl.tools at gmail dot com wrote:
> https://sourceware.org/bugzilla/show_bug.cgi?id=17711
>
> Bug ID: 17711
> Summary: copy relocations against protected symbols don't work
> Product: glibc
> Version: 2.21
> Status: NEW
> Severity: normal
> Priority: P2
> Component: dynamic-link
> Assignee: unassigned at sourceware dot org
> Reporter: hjl.tools at gmail dot com
>
> On Linux/x86-64, I got
>
> [hjl@gnu-tools-1 pr15228]$ cat x.c
> extern int a;
>
> extern void bar (void);
>
> int main()
> {
> bar ();
> if (a != 30)
> __builtin_abort();
> return 0;
> }
> [hjl@gnu-tools-1 pr15228]$ cat bar.c
> int a;
>
> __attribute__((visibility("protected"))) int a;
>
> void
> bar ()
> {
> a = 30;
> }
> [hjl@gnu-tools-1 pr15228]$ make all
> gcc -B/bin/ -c -o x.o x.c
> gcc -B/bin/ -fPIC -c -o bar.o bar.c
> ./ld -shared -o libbar.so bar.o
> gcc -B/bin/ -o x x.o libbar.so -Wl,-rpath,.
> ./x
> make: *** [all] Aborted (core dumped)
> [hjl@gnu-tools-1 pr15228]$
>
What commit does git bisect report?