Article View: comp.unix.programmer
Article #3392Re: C++ globals and shared lib, how to ?
From: Casper H.S. Dik - Network Securi...
Date: Wed, 03 Feb 1999 00:00
Date: Wed, 03 Feb 1999 00:00
26 lines
1640 bytes
1640 bytes
[[ PLEASE DON'T SEND ME EMAIL COPIES OF POSTINGS ]] Steve<_s_t_e_v_e_@maths.tcd.ie> no underscores writes: >Yves Dufournaud <Yves.Dufournaud@imag.fr> writes: >>I'am trying basic things using dlopen with g++-2.7.2.3 on sunos 5.5 : >>but when I load it with a dlopen and using RTLD_NOW >>constructor of global object are not called. >Isn't this a known bug with sunos? You could always >find the initialisation routine and call it manually >I suppose. No, this works fine in Solaris 2.x (SunOS 5.x), which is what he is using. You need to link with the compiler and probably with a newer version of gcc/g++ too. SunOS 4.x didn't implement init/fini routines, true but irrelevant Casper -- Expressed in this posting are my opinions. They are in no way related to opinions held by my employer, Sun Microsystems. Statements on Sun products included here are not gospel and may be fiction rather than truth.
Technical Details
Message-ID:
<casper.918048827@nl-usenet.sun.com>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<36B5EA0E.2361@imag.fr> <799gho$lpt@salmon.maths.tcd.ie>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fc89c,3b56ba1236b2e4f X-Google-Attributes: gidfc89c,public X-Google-Thread: 10ba33,3b56ba1236b2e4f X-Google-Attributes: gid10ba33,public X-Google-Thread: 11035d,3b56ba1236b2e4f X-Google-Attributes: gid11035d,public From: Casper.Dik@Holland.Sun.Com (Casper H.S. Dik - Network Security Engineer) Subject: Re: C++ globals and shared lib, how to ? Date: 1999/02/03 Message-ID: <casper.918048827@nl-usenet.sun.com> X-Deja-AN: 440175795 References: <36B5EA0E.2361@imag.fr> <799gho$lpt@salmon.maths.tcd.ie> Mail-Copies-To: never Organization: Sun Microsystems, Netherlands Newsgroups: comp.unix.programmer,comp.unix.solaris,gnu.g++.help