MAC uses yii2.0 development environment configuration under XAMPP

Source: Internet
Author: User
Tags intl zts

On the Mac to install the environment, tossing me for a long time. The first use is the Mac comes with PHP, but the own PHP many extensions need to install themselves. Libevent,memcache and other extensions are installed, found that Pdo_mysql.dll expansion has always, tragedy is coming back from work for several days did not do well. Because the end of the year is busy, so only after work back to adjust the environment. Later, I just want to use a XAMPP integration environment, just in the company is also XAMPP, the general extension is integrated, no need to install.

Then a xampp, and then always appeared, before the use of the memcache extension can not be used, I re-install, but not all. The first mistake was to install the command incorrectly, because PHP is in xampp, so you have to use

sh-/applications/xampp/xamppfiles/bin/phpizesh-+-/configure- -with-php-config=/applications/xampp/xamppfiles/bin/php-config--with-libevent=/usr/local/libevent-2.0 .  +

Phpize,php-config paths are changed, so the code you find online needs to be changed. That's right./configure parameters--with,--prefix and so on, I got an idea.

memcached expansion after installation, feel can be done, how to run the program when the page will not open, return code is not, and then view the Apache Error_log, found this error

Dyld:symbol not found: _mmc_queue_pop  referenced from:/usr/local/memcache-3.0.8/memcache-3.0.8/modules/ memcache.so  expected In:flat Namespace[fri Jan 23:40:46] [notice] child PID 4317 exit signal trace/bpt Trap ( 5) Dyld:lazy symbol binding Failed:symbol not found: _mmc_queue_pop  referenced from:/usr/local/memcache-3.0.8/ Memcache-3.0.8/modules/memcache.so  expected In:flat namespace

Online search, some people say because 3.0.8 is a beta version, you have to change a stable version, my own local PHP version is 5.63, so I did not look at the use of a higher version of the memcached, so this error occurred. Next, a stable version of the re-installed again. Http://pecl.php.net/package/memcached Good, run the project when the home page finally appeared in the eyes. Random point of the other pages, and error occurred. found that the Php_intl.dll extension is not installed. The yii2.0 Premium version of Yii::t () uses the intl extension. The XAMPP does not have its own intl extension. Read the online tutorials are said to copy the Icudt38.dll extension to the Apache bin directory. But when I searched, I found that there were no extensions at all in the ICU opening. Maybe Xampp's Mac version is a little different. Finally review this post http://www.th7.cn/Program/php/201408/261919.shtml reinstall.

/usr/local/php/bin/phpize. /configure--enable-intl--with-icu-dir=/usr/local/icu/--with-php-config=/usr/local/php/bin/php-config

This path is changed to the local xampp path.

SH-3.2#/applications/xampp/xamppfiles/bin/phpizeSH- +#./configure--with-icu-dir=/usr/local/icu--with-php-config=/applications/xampp/xamppfiles/bin/php-ConfigSH-3.2#/applications/xampp/xamppfiles/bin/php-m |grepintlwarning:php startup:unable to load dynamic library'/applications/xampp/xamppfiles/lib/php/extensions/no-debug-non-zts-20131226/php_intl.dll'-Dlopen (/applications/xampp/xamppfiles/lib/php/extensions/no-debug-non-zts-20131226/php_intl.dll,9): Image not foundinchUnknown on line0
Later, the reason for the warning error is that the previous look at other sites, will be php.ini inside the php_intl.dll before, the number is removed, this can not go, in the configuration file at the end of adding a extension=intl.so on it.

Now think of other these are not difficult, difficult on their own./configure command is not ripe, do not know to use--with to D Association dependency package, do not know when installing PHP extension phpize First, this must be if you are currently using the PHP environment directory. The rest is really nothing. So it will only follow the online steps to install, and not to pursue why so installation, it will go a lot more detours.

MAC uses yii2.0 development environment configuration under XAMPP

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.