简体   繁体   中英

How do I upgrade intl extension to ICU 4+ on OS X 10.7 Lion with PHP 5.3.8-ZS5.5.0

I am running OS X 10.7 Lion with Zend Server CE 5.5 (and therefore PHP 5.3.8). When I try to setup a new Symfony2 project the configuration checker warns me to upgrade the intl extension to ICU 4+.

I followed the instructions I found in another StackOverflow Post , mainly this blog post about upgrading intl on Lion . But when I try to compile the extension with PHP 5.3.8. I get the following error:

$ make
/bin/sh /Users/Florian/Downloads/php-5.3.8/ext/intl/libtool --mode=compile cc -I/usr/local/include -I. -I/Users/Florian/Downloads/php-5.3.8/ext/intl -DPHP_ATOM_INC -I/Users/Florian/Downloads/php-5.3.8/ext/intl/include -I/Users/Florian/Downloads/php-5.3.8/ext/intl/main -I/Users/Florian/Downloads/php-5.3.8/ext/intl -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/local/include  -DHAVE_CONFIG_H  -g -O2   -c /Users/Florian/Downloads/php-5.3.8/ext/intl/php_intl.c -o php_intl.lo 
mkdir .libs
cc -I/usr/local/include -I. -I/Users/Florian/Downloads/php-5.3.8/ext/intl -DPHP_ATOM_INC -I/Users/Florian/Downloads/php-5.3.8/ext/intl/include -I/Users/Florian/Downloads/php-5.3.8/ext/intl/main -I/Users/Florian/Downloads/php-5.3.8/ext/intl -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/local/include -DHAVE_CONFIG_H -g -O2 -c /Users/Florian/Downloads/php-5.3.8/ext/intl/php_intl.c  -fno-common -DPIC -o .libs/php_intl.o
/Users/Florian/Downloads/php-5.3.8/ext/intl/php_intl.c:490: error: ‘PHP_FE_END’ undeclared here (not in a function)
make: *** [php_intl.lo] Error 1

I was able to compile intl.so with PHP 5.3.6 but when I put that file in my php_extensions directory, PHP does not recognize intl at all. I think in my last attempt I tried to compile it with ICU 4.0.1, but I also tried some other versions like 4.8.1 or 4.6.1. Is there any possibility to compile ICU with PHP 5.3.8 on 10.7 at the moment?

How much do you need Zend Server? If not at all, then you could try http://php-osx.liip.ch/ which comes with ext/intl and everything else you need for Symfony2

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM