Given:
$ gcc -c -xc <(echo '_start(){}') -o start.o
$ ar cq libstart.a start.o
$ ./gold/ld-new -o foo libstart.a
The output file foo is an empty ELF file.
With:
$ ./gold/ld-new -o foo -e _start libstart.a
./gold/ld-new: warning: cannot find entry symbol '_start'
The results are the same, plus the extra warning.
BFD ld does not have this bug.
I tested with today's trunk builds of gold and BFD ld.
Thanks,
Roland
_______________________________________________
bug-binutils mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/bug-binutils