On Aug 30, 2013, at 15:42, Michael Newton wrote:

> On Fri, Aug 30, 2013 at 10:13 AM, Ryan Schmidt wrote:
> 
>> I've worked around it for now:
>> 
>> https://trac.macports.org/changeset/110361
>> 
>> The bugs as I see it are
>> 
>> 1) the documentation does not mention that the php sockets extension should 
>> be installed
>> 2) the build system does not recognize when the php sockets extension has 
>> been installed separately and not compiled into the php executable
> 
> Thanks for your assistance with this, it works great now. When I tried 
> forcing -DHAVE_SOCKETS during configure, I just got errors during 
> compilation. (And the only google result for that error was a bug report you 
> filed on php.net!)
> 
> I don't see 1) being a problem, since if I'm trying to pass it an already 
> created socket resource I will obviously have the extension installed. 
> However I wasn't sure if 2) was a problem unique to Macports; I had a feeling 
> that if I built it from source that COMPILE_DL_SOCKETS or HAVE_SOCKETS would 
> have been defined somewhere along the way. Maybe I'll give that a shot and 
> file an upstream bug if it's still a problem.

1) is a problem in that I, as a person packaging the software without really 
knowing what it's supposed to do, had no way of knowing that it required 
another package. A program's documentation should mention what its requirements 
are. It mentioned needing libevent and openssl, but not the PHP sockets 
extension.

If you build PHP from source and compile in the sockets extension then I expect 
those constants will be defined, however it is more convenient for users to be 
able to add and remove extensions later, after having compiled PHP itself, like 
we do in MacPorts, and it seems like their build system should either detect 
and accommodate that usage or the documentation should be updated to state that 
-DHAVE_SOCKETS needs to be added.

_______________________________________________
macports-users mailing list
[email protected]
https://lists.macosforge.org/mailman/listinfo/macports-users

Reply via email to