Subject: Re: C++ q: constructors not called for classes in shared lib ?
To: Todd Vierling <tv@pobox.com>
From: Jaromir Dolecek <dolecek@ics.muni.cz>
List: current-users
Date: 02/04/1999 16:34:17
Todd Vierling wrote:
> On Thu, 4 Feb 1999, Jaromir Dolecek wrote:
> 
> : IMHO it would be nice to change ld to link it in autimatically.
> : Or other way around -- I see no good reason for NOT doing so.
> 
> I'll look at the PR, but ld will *not* be changed, as that is a very
> nonstandard way of doing things.

Nonstandard for NetBSD or nonstandard for whole word ? At least
FreeBSD 3.0+ is doing right that (guessing by comment in ltconfig
-- may be the hack is only no more needed, as F3.0 is using ELF,
if I recall correctly), I'm not sure about Linux or Slowlaris.
It's just a bit un-intuitive having to add some special object file
when linking C++ shared library in order for static constructors
to work. If it would be 50K of code, I would think it has any reason
to force people include it explicitely. But not adding that 500B
to shared library when it may need it and the code may not work correctly
without it sounds ridiculous to me.

-- 
Jaromir Dolecek <dolecek@ics.muni.cz>	http://www.ics.muni.cz/~dolecek/
-------------------------------------------------------------------------
It is better never to have been born.  But who among us has such luck?
One in a million, perhaps.