Subject: Re: libpthread busted?
To: None <>
From: Gary Duzan <>
List: current-users
Date: 03/05/2003 19:13:02
In Message <> ,
   Thor Lancelot Simon <> wrote:

=>It seems to me that any executable that wishes to dlopen() objects that
=>may reference pthread functions *is inherently a threaded application*
=>and must, therefore, itself be linked to libpthread at compile time.  Any
=>method of hiding the fact that one is changing boats mid-stream seems
=>highly prone to error and highly likely to come back to bite us in the

   It would be fairly evil, but it seems that some bit of magic to
automagically link in pthreads when dlopen() is referenced in the
object file would deal with the problem. I doubt you can ever predict
accurately whether or not a program which calls dlopen() is going to
try to load something threaded, so it would be safest to assume that
you will, which is going to require pthreads.

   Of course, I have no idea how hard this would actually be, and
it could cause other problems, e.g., if these pluggable authentication
schemes which use dlopen() ever show up, but it is a thought.

					Gary Duzan