NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: cannot dlopen non loadable libpthread error



On Sun, Sep 30, 2012 at 07:42:18PM +0530, Mayuresh wrote:
> Is this limitation specific to pthread or is there a general limitation on
> use of dlopen. (If the latter, I think many applications would have faced
> problems.)

The former - libc changes its behaviour depending on availability of
threads (a lot more locking). Transition from non-threaded to threaded
state is only possible once and very early.

> Also, I noticed the error going away with
> LD_PRELOAD=/usr/lib/libpthread.so.1
> 
> How reliable/good is this workaround?

No idea - but I would guess this basically makes things the same as
with ld.elf_so loading libpthread early, so it is probably ok.

Side remark: I haven't tried scanimage, but xsane works fine for me in
-current.

Martin


Home | Main Index | Thread Index | Old Index