Date: Tue, 24 Nov 1998 11:08:28 -0600 (CST) From: Jonathan Gapen <jagapen@whitewater.chem.wisc.edu> To: freebsd-hackers@FreeBSD.ORG Subject: Re: ELF Global Constructors Message-ID: <Pine.NXT.4.05.9811241058290.2702-100000@billybob.chem.wisc.edu> In-Reply-To: <199811240822.TAA07814@cimlogic.com.au>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 24 Nov 1998, John Birrell wrote: > For an example of a constructor, have a look at: > src/lib/libc_r/uthread/uthread_autoinit.cc > > This is how a threaded process is initialised prior to the process calling > main(). This code works with the in-tree compiler (I haven't used egcs, so > I'm not sure about that). Doh! I forgot to mention that most of GNUstep is written in Objective C, so C++ constructors aren't going to work. Further, the global class trick doesn't work. That does suggest to me the bad hack of linking in a C++ class which calls that function. Still, I'd like to find out how the C++ compiler hooks in those constructors to be called before main(), so I can do the same. -- Jonathan Gapen - sysadmin - biker - caver - collecter of old computers I think you know exactly what I mean when I say it's a shpadoinkle day. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.NXT.4.05.9811241058290.2702-100000>