FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » Compiling PHP 5.x on Cygwin
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: Compiling PHP 5.x on Cygwin [message #182656 is a reply to message #182642] Fri, 23 August 2013 22:08 Go to previous message
Christoph Michael Bec is currently offline  Christoph Michael Bec
Messages: 207
Registered: June 2013
Karma:
Senior Member
Jerry Stuckle wrote:

> On 8/20/2013 2:20 PM, Christoph Michael Becker wrote:
>
>> Thanks, Jerry, that brought me a bit further. Indeed including
>> <cygwin/types.h> in the config file made the general check for flock
>> happy; the second check for the opcache additionally needed a ||
>> defined(__CYGWIN32__) to an #elif. After these modifications building
>> was possible; however, I was not able to actually activate the opcache.
>>
>> The problem seems to be that PHP is building shared libraries with a .so
>> extension on Cygwin, where this should be .dll.a. This also happens
>> with the original ./configure and --enable-opcache=no. This is no
>> problem for the PHP executable, which statically links in the default
>> extensions, but not the opcache extension.
>
> Can you rename the libraries? Or maybe change the config script to
> generate the proper names? (I don't know - it's been too long since I
> used cygwin - and then not with PHP).

Renaming the libraries would not help--there all just < 1 KB in size.
Changing the config script (or the Makefile) might work, but some quick
tests were not successful. I guess it's best to postpone further work
until some more basic issues are resolved (see below).

>> Running "make test" produced failures for all tests, which might be
>> related to the shared library issue. It seems to me PHP's Cygwin
>> support has some flaws. I'm considering to file a bug report/feature
>> request to improve that, even if I understand that supporting Cygwin has
>> probably low priority for the PHP developers.
>>
>
> I doubt you'll get any help. Is there a version of PHP in the cygwin
> libraries (I don't know - it's been too long since I used cygwin, but
> IIRC there was one)? Maybe that will help get you on the right track.

Unfortunately there's no PHP available via the regular Cygwin
distribution. However, the Cygwin ports project[1] offers a PHP
package--but only 5.4.19 (there really fast anyway, as this was released
only several hours ago).

Regarding the failing tests I had filed a bug report[2], and due to the
quick feedback of the PHP devs (what pleasantly surprised me) I made
some progress here. I'll see where that goes.

>> I'm still stuck with Windows XP (I know, I should have already
>> upgraded), so I can't run the native Windows build of PHP 5.5. But even
>> after upgrading I would prefer being able to compile PHP in a Unix like
>> environment. I would prefer using Cygwin over a virtual machine
>> installation of a Linux system, as it is more lightweight and may
>> suffice for my purposes.
>>
>
> Yup, XP is at EOL and pretty soon there won't be any further updates. I
> know it's a hassle - I still have a couple of programs which don't run
> under Windows 7 (even in emulation mode) so I have to use a Windows XP
> virtual box. A hassle.
>
> And yes, cygwin is more lightweight; if the overhead of a virtual box is
> a problem for you, than that's the way to go.
>
> Of course, you can get some pretty cheap laptops nowadays. Maybe it
> would be worth investing in one and just installing Linux on it :)
>
> Or if you don't need to move around, desktops are getting even cheaper :))

That's an option to consider, if I can't manage to get extensions
relying on shared libraries working on Cygwin.

Thanks for your help. :)

[1] <http://cygwinports.org/>
[2] <https://bugs.php.net/bug.php?id=65497>

--
Christoph M. Becker
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: switch with case 0
Next Topic: Re: korean character sets
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Sun Nov 24 17:25:46 GMT 2024

Total time taken to generate the page: 0.05821 seconds