https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69357

--- Comment #2 from Richard Biener <rguenth at gcc dot gnu.org> ---
Btw, my thought was that it ends up like

> cat t2.c
int x = 1;
> gcc t2.c -o libt2.so -shared -lisl -fPIC
> cat t.c
extern char _end[];
char *endp = _end;
int main()
{
}
> gcc -Wl,--as-needed -Wl,--no-add-needed -L. -lt2 -Bstatic t.o -Bdynamic 

where libt2.so might provide _end (but is not needed and not linked in the
end),
referenced from t.o (simulating -static-libgo).

It doesn't error this way though (maybe because libt2.so itself provides _end).

Reply via email to