
If you cannot edit the file, enter the Edit mode simply typing a. bash_profile file: sudo vi ~/.bash_profile To solve the problem you have to export the variable DYLD_LIBRARY_PATH adding it to your. To reproduce the error, type in the Terminal this command: php i- | grep -i intl In /Applications/MAMP/bin/php/php5.6.6/lib/php/extensions/no-debug-non-zts-20131226/intl.so in Unknown on line 0 Referenced from: /Applications/MAMP/bin/php/php5.6.6/lib/php/extensions/no-debug-non-zts-20131226/intl.so Warning: PHP Startup: Unable to load dynamic library ‘/Applications/MAMP/bin/php/php5.6.6/lib/php/extensions/no-debug-non-zts-20131226/intl.so’ – dlopen(/Applications/MAMP/bin/php/php5.6.6/lib/php/extensions/no-debug-non-zts-20131226/intl.so, 9): Symbol not found: _ZN6icu_5513BreakIterator16getRuleStatusVecEPiiR10UErrorCode On startup (activate startup errors in PHP!), following this procedure, I’m getting a Warning: Now we have really all done: enjoy internationalization! Troubleshooting So, open again your php.ini and find the line Module Settings : here there are configurations for all the modules used by PHP.Īgain, run the command $ php -i | grep "intl" Now that we have installed Intl, we have to configure its default values. With it you’ll can manage, convert, perform math operations and many more on money values: Give it a try!Īnother good thing to try is the Intl Component provided by Symfony Framework: really astonishing!įinally, there is the last really, really important thing… Configuring defaults for Intl extension
#Mamp install install
The first you can try is to install the Money library written by Sebastian Bergman (yes, the one who wrote also PHP Unit!): it is the best library/ Value Object you can use to manage Money values. Now that you have Intl installed on your system, you can make great things with internationalization. fault_locale => no value => no valueĭone! Now you have Intl library installed and working on your MAMP installation! Now, let’s try Intl extension on the “battle field” Now, save the php.ini and restart MAMP and verify that Intl extension is properly loaded: $ php -i | grep "Internationalization support"Īnd, if you like, check also $ php -i | grep "intl" So, open it with your favorite editor and find the line Extensions.Īt the end of the section simply add the line extension=intl.so. Loaded Configuration File => /Applications/MAMP/bin/php/php5.6.6/conf/php.ini To know which php.ini your Terminal is using, type in Terminal itself: $ php -i | grep "php.ini"Ĭonfiguration File (php.ini) Path => /Applications/MAMP/bin/php/php5.6.6/conf If you have configured you MacOSX Terminal to use the same PHP binaries of MAMP, then you have to go to /Applications/MAMP/bin/php/phpX.X.X/conf/php.ini. Now the easy last part: activate your new Intl extension in your php.ini. Troubleshooting: php_intl.lo ERROR: ‘make’ failedĪs pointed out here, you have to install XCode Command Line Tools and create symlinks between XCode and MAMP. Then you have to install Autoconf before you can run the Intl installation. Please check your autoconf installation and the $PHP_AUTOCONF environment variable. If you receive an error that says something likeĬannot find autoconf. Now install the Intl binaries in PHP: $ sudo pecl install intl Troubleshooting: Error “Cannot find autoconf” This process may require some minutes and during the process you will be asked to provide the Admin password.


So, move into the icu/source folder and compile and install the binaries: $ cd icu/source Now that you have the ICU binaries, you have to install them. $ tar xzvf icu4c-4_8_1_1-src.tgz STEP 2: Compile the binaries
#Mamp install download
On the download page you’ll find binaries for the major platforms and the source code: be sure to download the source code, and NOT the binaries. Go to ICU Project download page and grab the latest version. STEP 1: Download ICU binaries and uncompress them Install Autoconf so you can run the Intl installation (more about this later). Yes, they are 2 separate binaries packages! Verify you’ve Installed XCode and its Command Line Toolsīefore you can install Intl binaries, you have to install xCode Command Line Tools. Instead you have to install Intl both for the PHP used by Terminal – the one shipped with MacOSX – and for the PHP used by your browsers – the one shipped with MAMP. STEP 0: Before to start, verify your environment Verify which version of PHP are you running in Terminalīefore you install ICU binaries, check that your Terminal is using the PHP binaries provided by MAMP. It is also required by some advanced framework as Symfony to work with international values. It is really useful, as, with it, you can, for example, manage currencies and money values in the simplest way possibile (examples at the end of this post). Is a wrapper for » ICU library, enabling PHP programmers to perform » UCA-conformant collation and date/time/number/currency formatting in their scripts.
