Created
March 17, 2019 01:01
-
-
Save dmnlk/4779a45fe8ff68072a019be292eebbb1 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 1. `curl -L -O https://github.com/phpbrew/phpbrew/raw/master/phpbrew` | |
| 2. chmod +x phpbrew | |
| 3. phpbrew init | |
| 4. `phpbrew install -j 8 7.1.27 +default +dbs +intl` | |
| ``` | |
| configure: error: Please reinstall the BZip2 distribution | |
| Please checkout the build log file for more details: | |
| tail /Users/xx/.phpbrew/build/php-7.1.27/build.log | |
| ``` | |
| 5. `brew install bzip2` | |
| 6. `xcode-select --install` | |
| 7. add opt `phpbrew install -j 8 7.1.27 +default +dbs +intl +bz2=/usr/local/Cellar/bzip2/1.0.6_1/` | |
| ``` | |
| configure: error: mcrypt.h not found. Please reinstall libmcrypt. | |
| Please checkout the build log file for more details: | |
| tail /Users/xx/.phpbrew/build/php-7.1.27/build.log | |
| ``` | |
| 8. brew install mcrypt | |
| ``` | |
| checking for pg_config... not found | |
| configure: error: Cannot find libpq-fe.h. Please specify correct PostgreSQL installation path | |
| ``` | |
| 9. ` brew install postgresql` | |
| 10. add opt `phpbrew install -j 8 7.1.27 +default +dbs +intl +bz2=/usr/local/Cellar/bzip2/1.0.6_1/ +pgsql=/usr/local/Cellar/postgresql/11.2/bin` | |
| ``` | |
| checking pcre install prefix... /usr/local | |
| checking libzip... no | |
| checking for the location of zlib... configure: error: zip support requires ZLIB. Use --with-zlib-dir=<DIR> to specify prefix where ZLIB include and library are located | |
| ``` | |
| 11. ` phpbrew install -j 8 7.1.27 +default +dbs +intl +bz2=/usr/local/Cellar/bzip2/1.0.6_1/ +pgsql=/usr/local/Cellar/postgresql/11.2/bin +zlib=/usr/local/Cellar/zlib/1.2.11/` | |
| ``` | |
| * We found that you enabled 'mysql' variant, you might need to setup your | |
| 'pdo_mysql.default_socket' or 'mysqli.default_socket' in your php.ini file. | |
| * To configure your installed PHP further, you can edit the config file at | |
| /Users/masakikawaguchi/.phpbrew/php/php-7.1.27/etc/php.ini | |
| To use the newly built PHP, try the line(s) below: | |
| $ phpbrew use php-7.1.27 | |
| Or you can use switch command to switch your default php to php-7.1.27: | |
| $ phpbrew switch php-7.1.27 | |
| Enjoy! | |
| ``` | |
| success! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment