I'm trying to install Magento 2 on my MAMP PRO but I receive this error from composer:
*Your requirements could not be resolved to an installable set of packages.
Problem 1
- magento/framework 100.0.4 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- magento/framework 100.0.4 requires ext-mcrypt * -> the requested PHP extension mcrypt is missing from your system.
- Installation request for magento/framework 100.0.4 -> satisfiable by magento/framework[100.0.4].*
But mcrypt is install in my MAMP:
Screenshot of phpinfo()
in my MAMP environment
I tried adding the php version to .bash_profile
file but it didn't resolve:
export MAMP_PHP=/Applications/MAMP/bin/php/php5.5.10/bin
export PATH="$MAMP_PHP:$PATH"
I try running php -i | grep mcrypt this is the result: ~/Sites/magento2 $ php -i | grep mcrypt
Configure Command => './configure' '--with-mysql=mysqlnd' '--with-gd' '--with-jpeg-dir=/Applications/MAMP/Library' '--with-png-dir=/Applications/MAMP/Library' '--with-zlib' '--with-zlib-dir=/Applications/MAMP/Library' '--with-freetype-dir=/Applications/MAMP/Library' '--prefix=/Applications/MAMP/bin/php/php5.6.10' '--exec-prefix=/Applications/MAMP/bin/php/php5.6.10' '--sysconfdir=/Applications/MAMP/bin/php/php5.6.10/conf' '--with-config-file-path=/Applications/MAMP/bin/php/php5.6.10/conf' '--enable-ftp' '--enable-gd-native-ttf' '--with-bz2=/usr' '--with-ldap' '--with-mysqli=mysqlnd' '--with-t1lib=/Applications/MAMP/Library' '--enable-mbstring=all' '--with-curl=/Applications/MAMP/Library' '--enable-sockets' '--enable-bcmath' '--with-imap=shared,/Applications/MAMP/Library/lib/imap-2007f' '--enable-soap' '--with-kerberos' '--enable-calendar' '--with-pgsql=shared,/Applications/MAMP/Library/pg' '--enable-exif' '--with-libxml-dir=/Applications/MAMP/Library' '--with-gettext=shared,/Application s/MAMP/Library' '--with-xsl=/Applications/MAMP/Library' '--with-pdo-mysql=mysqlnd' '--with-pdo-pgsql=shared,/Applications/MAMP/Library/pg' '--with-mcrypt=shared,/Applications/MAMP/Library' '--with-openssl' '--enable-zip' '--with-iconv=/Applications/MAMP/Library' '--enable-opcache' '--enable-cgi' '--enable-intl' '--with-icu-dir=/Applications/MAMP/Library' '--with-tidy=shared' '--enable-wddx' '--with-libexpat-dir=/Applications/MAMP/Library' '--with-readline' 'CFLAGS=-arch 'LDFLAGS=-arch 'LIBS=-lresolv' 'CXXFLAGS=-arch Registered Stream Filters => zlib. , bzip2. , convert.iconv. , string.rot13, string.toupper, string.tolower, string.strip_tags, convert. , consumed, dechunk, mcrypt. , mdecrypt.
mcrypt
mcrypt support => enabled
mcrypt_filter support => enabled
mcrypt.algorithms_dir => no value => no value
mcrypt.modes_dir => no value => no value
On Mac, running MAMP: You need to find the php.ini file for the version of php you are running and replace the extension_dir line as below. (making sure to replace "php5.6.10" with your version and "no-debug-non-zts-20131226" with the name of the folder inside extensions.)
php.ini file usually located at: mamp/php/your-php-version/conf
extension_dir = "/Applications/MAMP/bin/php/php5.6.10/lib/php/extensions/no-debug-non-zts-20131226/"
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.