Re: patch for libdld (182 Views)
Occasional Contributor
Posts: 5
Registered: ‎08-08-2005
Message 1 of 4 (182 Views)

patch for libdld


We are facing the webserver starting issue after deploying few web application. We have libsasl library which have dlopen defined in it , which intern has shl_load call and this shl_load is getting null input in one of its argument.
Now we want that our webserver should use the dlopen defined in system libraries like in libdld.

Please suggest is there any way we can bypass dlopen function of our library and let system library do that task.

Is there any libdld patch we can check for as we found same webserver working fine on some other machine.

All suggestion are welcome.
Looking forward for reply

Honored Contributor
Posts: 4,194
Registered: ‎04-07-2005
Message 2 of 4 (182 Views)

Re: patch for libdld

I guess it is 11.11, this is a latest patch PHSS_33033,||&patchid=PHSS_33033&context=hpux:800:11:11

"A ship in the harbor is safe, but that is not what ships are built for"
Honored Contributor
Posts: 1,155
Registered: ‎11-24-2004
Message 3 of 4 (182 Views)

Re: patch for libdld

The version of dlopen() used will depend on how the executable was linked. The first external symbol found matching the pattern for dlopen() will be linked in. The order the libraries is linked is important. I don't know whether that helps you, especially if you can't relink the executable.
Esteemed Contributor
Posts: 375
Registered: ‎05-16-2003
Message 4 of 4 (182 Views)

Re: patch for libdld

you can either alter the linkline so that libdld appears precedes libsasl in the linkline:

cc ... -ldld ... -lsasl
ld ... -ldld ... -lsasl

or use LD_PRELOAD/LD_PRELOAD_ONCE at runtime:

env LD_PRELOAD=/usr/lib/ ./server

the first approach is recommended.

dlopen is available in 11.11/11.23 libdld. please use the latest linker/loader patches PHSS_33032(11.00)/PHSS_33033(11.11)/PHSS_33349(11.23).
The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation.