http://sourceware.org/bugzilla/show_bug.cgi?id=14590

--- Comment #2 from H.J. Lu <hjl.tools at gmail dot com> 2012-09-17 16:03:20 
UTC ---
[hjl@gnu-6 pr14590]$ cat x.c
int foo;
int
main ()
{
  return foo != 0;
}
[hjl@gnu-6 pr14590]$ cat y.c
void alt (void) { }

#pragma foo_ifunc weak
void foo (void);
void * foo_ifunc (void) __asm__ ("foo");
__asm__(".type foo, %gnu_indirect_function");

void *
foo_ifunc (void)
{
  return alt;
}
[hjl@gnu-6 pr14590]$ make
gcc -B./ -g   -c -o x.o x.c
gcc -B./ -g   -c -o y.o y.c
gcc -B./ -static -o x x.o y.o
./ld: Warning: alignment 2 of symbol `foo' in y.o is smaller than 4 in x.o
./ld: Warning: size of symbol `foo' changed from 4 in x.o to 11 in y.o
./ld: Warning: type of symbol `foo' changed from 1 to 10 in y.o
./ld: BFD (GNU Binutils) 2.23.51.20120917 internal error, aborting at
/export/gnu/import/git/binutils/bfd/elf64-x86-64.c line 3335 in
elf_x86_64_relocate_section

./ld: Please report this bug.

collect2: error: ld returned 1 exit status
make: *** [x] Error 1
[hjl@gnu-6 pr14590]$

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

_______________________________________________
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils

Reply via email to