#24582 [Opn->Csd]: Extensions cannot be loaded dynamically on Solaris / iPlanet

From: Date: Mon, 15 Mar 2004 15:59:22 +0000
Subject: #24582 [Opn->Csd]: Extensions cannot be loaded dynamically on Solaris / iPlanet
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-56504@lists.php.net to get a copy of this message
 ID:               24582
 Updated by:       sniper@php.net
 Reported By:      CVKEWCZBUTBW at spammotel dot com
-Status:           Open
+Status:           Closed
 Bug Type:         Zend Engine 2 problem
 Operating System: Solaris
 PHP Version:      5CVS, 4CVS
 New Comment:

This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.




Previous Comments:
------------------------------------------------------------------------

[2003-07-31 14:07:00] CVKEWCZBUTBW at spammotel dot com

Yes, the patch I provided in my July 10 posting fixes the bug for
Solaris.
My July 11 posting proposes a modified patch which is more portable,
esp. it does not break compilation in a Linux environment.

------------------------------------------------------------------------

[2003-07-24 15:10:42] sniper@php.net

Does the patch you provided fix the bug for you or not?
(I have no solaris access to test it with..)


------------------------------------------------------------------------

[2003-07-11 03:54:41] CVKEWCZBUTBW at spammotel dot com

> Also, according to Solaris man page for dlopen(),
> (if I read it correctly :), RTLD_GROUP and RTLD_WORLD
> are on by default anyway. So only option needed is
> RTLD_PARENT.
> Could you try that only?

The man page is not really clear about that. I understand that if you
set NONE of the three flags, then "GROUP|WORLD" takes effect. So if you
want all three flags, you have to specify "GROUP|WORLD|PARENT".

I have no easy way to try it. I'd propose:

#if defined(RTLD_GROUP) && defined(RTLD_WORLD) && defined(RTLD_PARENT)
#define DL_LOAD(libname) dlopen(libname, RTLD_LAZY | RTLD_GLOBAL |
RTLD_GROUP | RTLD_WORLD | RTLD_PARENT)
#else
#define DL_LOAD(libname) dlopen(libname, RTLD_LAZY | RTLD_GLOBAL)
#endif

------------------------------------------------------------------------

[2003-07-10 10:50:47] sniper@php.net

We could also add those 3 extra ones always though if they just are
defined..:)


------------------------------------------------------------------------

[2003-07-10 10:46:51] sniper@php.net

RTLD_GROUP, RTLD_WORLD and RTLD_PARENT are not available
on Linux. (at least not defined at all in my system).

Also, according to Solaris man page for dlopen(), 
(if I read it correctly :), RTLD_GROUP and RTLD_WORLD are on by default
anyway. So only option needed is RTLD_PARENT.

Could you try that only?


------------------------------------------------------------------------

The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
    http://bugs.php.net/24582

-- 
Edit this bug report at http://bugs.php.net/?id=24582&edit=1


Thread (10 messages)

« previous php.bugs (#56504) next »