mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2025-01-12 12:16:04 +08:00
59e31fd742
A following patch will add visibility support in ld for XCOFF. Thus, ld-elfvsb is renamed ld-vsb and a suffix is added to files targeting only ELF format. ld/ChangeLog: * testsuite/ld-elfvsb: rename as ld-vsb. * testsuite/ld-elfvsb/hidden0.d: move to ld-vsb and rename with suffix -elf.d. * testsuite/ld-elfvsb/hidden1.d: Likewise. * testsuite/ld-elfvsb/hidden2.d: Likewise. * testsuite/ld-elfvsb/internal0.d: Likewise. * testsuite/ld-elfvsb/internal1.d: Likewise. * testsuite/ld-elfvsb/protected0.d: Likewise. * testsuite/ld-elfvsb/protected1.d: Likewise.
27 lines
382 B
C
27 lines
382 B
C
#pragma weak main_hidden_data
|
|
extern int main_hidden_data;
|
|
__asm__ (".hidden main_hidden_data");
|
|
|
|
#pragma weak main_hidden_func
|
|
extern int main_hidden_func ();
|
|
__asm__ (".hidden main_hidden_func");
|
|
|
|
int
|
|
_start (void)
|
|
{
|
|
int ret = 0;
|
|
|
|
if (&main_hidden_data != 0)
|
|
ret = 1;
|
|
if (main_hidden_func != 0)
|
|
ret = 1;
|
|
|
|
return ret;
|
|
}
|
|
|
|
int
|
|
__start (void)
|
|
{
|
|
return _start ();
|
|
}
|