0a36a439ee
2008-09-16 H.J. Lu <hongjiu.lu@intel.com> PR ld/6877 * elflink.c (_bfd_elf_merge_symbol): Allow a common symbol to override the function in a shared library. ld/testsuite/ 2008-09-16 H.J. Lu <hongjiu.lu@intel.com> PR ld/6877 * ld-elf/comm1.c: New. * ld-elf/func1.c: Likewise. * ld-elf/shared.exp: Add tests for libfunc1.so and comm1.
17 lines
190 B
C
17 lines
190 B
C
#include <stdio.h>
|
|
#include <stdlib.h>
|
|
|
|
int foo;
|
|
void bar (void);
|
|
|
|
int
|
|
main ()
|
|
{
|
|
if (foo != 0)
|
|
abort ();
|
|
foo = 200;
|
|
bar ();
|
|
if (foo == 200)
|
|
printf ("PASS\n");
|
|
return 0;
|
|
}
|