* Re: Bad crt files [not found] <m0quqzC-00034LC@neal.ctd.comsat.com> @ 1994-10-11 23:11 ` H.J. Lu 1994-10-12 7:34 ` Eric Youngdale 0 siblings, 1 reply; 3+ messages in thread From: H.J. Lu @ 1994-10-11 23:11 UTC (permalink / raw) To: Neal Becker; +Cc: Eric Youngdale, Ian Lance Taylor, Ken Raeburn, gas2 > > Better. But change the Makefile to use add -g to each compile and > link step, then it segfaults again. Can I use -g at the link step with the shared library since libg.a is not a shared library? Can a shared library be loaded in without libc.so? Maybe there is a bug the GNU ld that couldn't handle mixing a shared library with a static C library right. Or is that a dynamic linker bug? BTW, Ian, how compatible is the GNU ELF ld with SVR4/x86 ld? Can it be a dropin replacement? Has anyone tried to use the GNU ELF ld to build a shared ELF library under SVR4/x86? > > This simple example built fine with or without -g with the previous > tool releases. > -- H.J. Lu NYNEX Science and Technology, Inc. hjl@nynexst.com ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Bad crt files 1994-10-11 23:11 ` Bad crt files H.J. Lu @ 1994-10-12 7:34 ` Eric Youngdale 1994-10-12 22:18 ` GNU ld, ELF and C++ H.J. Lu 0 siblings, 1 reply; 3+ messages in thread From: Eric Youngdale @ 1994-10-12 7:34 UTC (permalink / raw) To: hjl; +Cc: neal, ian, raeburn, gas2 >BTW, Ian, how compatible is the GNU ELF ld with SVR4/x86 ld? Can it >be a dropin replacement? Has anyone tried to use the GNU ELF ld to >build a shared ELF library under SVR4/x86? Yes, I used to do this all the time at my old job. I intended it to be a drop in replacement, but the handling of the SHT_DYNSYM sections in our version of SVr4 was a bit weird, and Solaris treated things more logically. That being said, a little work might be needed on some flavors of SVr4 to support a unified symbol table which the Dell SVr4 seemed to want. This could be a linker option, I think. -Eric ^ permalink raw reply [flat|nested] 3+ messages in thread
* GNU ld, ELF and C++ 1994-10-12 7:34 ` Eric Youngdale @ 1994-10-12 22:18 ` H.J. Lu 0 siblings, 0 replies; 3+ messages in thread From: H.J. Lu @ 1994-10-12 22:18 UTC (permalink / raw) To: Eric Youngdale; +Cc: Ken Raeburn, Ian Lance Taylor, gas2 > > > >BTW, Ian, how compatible is the GNU ELF ld with SVR4/x86 ld? Can it > >be a dropin replacement? Has anyone tried to use the GNU ELF ld to > >build a shared ELF library under SVR4/x86? > > Yes, I used to do this all the time at my old job. I intended it Have you tried gcc -shared -o libfoo.so *.o with the GNU ld under SVR4/x86? First, GNU ld doesn't take the flags for SVR4/x86 ld. Do you use a special specs for GNU ld under SVR4/x86? I had to edit specs a little bit. I changed "%{shared:-G -dy}" to "%{shared:-shared}". My test case is little bit tricky since I am working on the ELF support for the C++ shared library. My stuff works with the GNU as and SVR4/x86 ld, but not the GNU ld. If I create the shared C++ ELF library under SVR4/x86 with the GNU as and SVR4 ld, the global ctors and dtors in the shared C++ ELF library are called in the right order. But the shared C++ ELF library created with the GNU as and GNU ld won't call those global ctors and dtors at all. It looks that there are bugs with creating the shared ELF library in the GNU ld. If anyone is interested, I can send my test case. > to be a drop in replacement, but the handling of the SHT_DYNSYM sections > in our version of SVr4 was a bit weird, and Solaris treated things more > logically. That being said, a little work might be needed on some flavors of > SVr4 to support a unified symbol table which the Dell SVr4 seemed to want. > This could be a linker option, I think. > > Eric, there is a bug in the Linux d-linker. It has something to do with mixing the shared/static libraries. I will send you a test case later this week. -- H.J. Lu NYNEX Science and Technology, Inc. hjl@nynexst.com ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~1994-10-12 22:18 UTC | newest] Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- [not found] <m0quqzC-00034LC@neal.ctd.comsat.com> 1994-10-11 23:11 ` Bad crt files H.J. Lu 1994-10-12 7:34 ` Eric Youngdale 1994-10-12 22:18 ` GNU ld, ELF and C++ H.J. Lu
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).