you are absolutely right.
thanks for the feedback!


On Tue, Apr 9, 2013 at 9:50 PM, Olly Betts <> wrote:
Rodolfo Ochoa writes:
> I think ./Source/Modules/php.cxx381:     Printf(f_phpcode, "    if
(!dl('php_%s.dll')) return;\n", module);
> shouldn't have php_ prefix hardcoded on windows, since I modify my output
for different platforms and have a standard name for all libraries, this
gives me problems on the output using CMAKE.

The intention of this code is to try to load the C/C++ extension part
of the binding if it hasn't already been loaded.

But these days it's very common to have dl() disabled for security
reasons, usually via this in php.ini:

enable_dl = Off

And so you can't really rely on this code working on an arbitrary
installation of PHP anyway.

I recommend you load your module from php.ini, and then the name
passed to dl() is irrelevant as it'll never get called.  You want
something like this in php.ini:


Really the only reason the dl() call is still there is that removing it
might break things for some existing users, which seems unfriendly.
But so would changing the filename passed, so it makes no sense to do


Precog is a next-generation analytics platform capable of advanced
analytics on semi-structured data. The platform includes APIs for building
apps and a phenomenal toolset for data science. Developers can use
our toolset for easy data analysis & visualization. Get a free account!
Swig-user mailing list