Subject: Re: mit-pthreads and C++
To: Gary D. Duzan <>
From: Zdenek Salvet <>
List: current-users
Date: 10/27/1997 17:19:24
> =>   I've been attempting to get OmniORB, which requires pthreads,
> =>running on NetBSD. While I can eventually manage to get everything
> =>to compile, when I run it I don't get anything that is sent to cerr
> =>for output.  If I put in an fprintf, I get the output fine. I've
> =>tried any number of link options and library orderings, but nothing
> =>makes it work. I fear this is just a symptom of a deeper problem.
> =>   Has anyone else tried this and had similar results? Thanks.
>    Sorry, I forgot the details.
> NetBSD 1.3_ALPHA NetBSD 1.3_ALPHA (WHEEL) #0: Sat Oct 25 15:36:37 EDT 1997 i386
> I'm using the pkgsrc/devel/mit-pthreads version.
> When I put a 'cerr << "foo" << endl;' at the beginning of main(), I
> still don't get anything. My current theory is that the constructor
> for cerr isn't getting called, which makes be wonder if any static
> constructors are getting called.

Try to link with static c++ library, I think g++ does not support
static constructors in our shared libraries. ( Has anyone tried using
collect2 instead ld directly ?)

Zdenek Salvet                                     
           If God had meant for us to be in the Army,
         we would have been born with green, baggy skin.