Mac OSX 10.12.6编译安装Tengine+PHP7.1
先发一下电脑配置,电脑版本如下图:
PHP安装步骤如下:
请确保电脑已经关闭SIP(System Integrity Protection)。

关闭SIP的方法去问Google!
下载PHP7.1.1并且解压。
wget http://mirrors.sohu.com/php/php-7.1.1.tar.gz tar -zcvf php-7.1.1.tar.gz
安装PHP前前依赖安装
brew install gcc
brew install libxml2
brew install openssl
brew install autoconf
brew install libjpeg
brew install libpng
brew install freetype
brew install gettext
brew install mcrypt libmcrypt4.编译安装
参数如下:
./configure --prefix=/usr/local/php71 --with-config-file-path=/usr/local/php71/etc --with-mcrypt=/usr/include --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd --with-gd --with-iconv --with-zlib --enable-xml --enable-bcmath --enable-shmop --enable-sysvsem --enable-inline-optimization --enable-mbregex --enable-fpm --enable-mbstring --enable-ftp --enable-gd-native-ttf --enable-pcntl --enable-sockets --with-xmlrpc --enable-zip --enable-soap --without-pear --with-gettext --enable-session --with-curl --with-jpeg-dir --with-freetype-dir --enable-opcache --with-libxml-dir=/usr/local/Cellar/libxml2/2.9.7 --with-openssl-dir=/usr/local/Cellar/openssl/1.0.2m/
sudo make && sudo make install
安装Tengine(nginx)步骤如下:
和PHP一样先下载Tengine! http:tengine.taobao.otg
下载依赖包:jemalloc ,zlib,openssl,pcre.
3.编译安装
参数:./configure --prefix=/usr/local/nginx --with-http_stub_status_module --with-http_ssl_module --with-http_gzip_static_module \\n--with-pcre=/Users/guoyexuan/Downloads/pcre-8.38 \\n--with-zlib=/Users/guoyexuan/Downloads/zlib-1.2.11 \\n--with-jemalloc=/Users/guoyexuan/Downloads/jemalloc-3.6.0 \\n--with-openssl=/Users/guoyexuan/Downloads/openssl-1.0.2m
4.修改MakeFiles.
&& ./config --prefix=/Users/xxx/Downloads/tengine-2.2.1/../openssl-1.0.2m/.openssl no-shared \ 将 config 修改为 Configure darwin64-x86_64-cc, --prefix 之后的不用修改, 修改后的如: && ./Configure darwin64-x86_64-cc --prefix=/Users/xxx/Downloads/tengine-2.2.1/../openssl-1.0.2m/.openssl no-shared \
5.sudo make && sudo make install.
相关推荐
liuhangtiant 2020-10-20
RisenWang 2020-06-22
houjinkai 2020-04-26
liwf 2020-01-10
泥淖 2019-11-12
AcFunJ 2019-11-05
competeking 2019-07-16
畅聊架构 2019-07-12
Lincain 2019-07-01
sctq 2019-06-28
houjinkai 2019-06-26
卷确 2019-06-25
xiedengmin 2019-04-04
alexdeblog 2017-08-07
fightingtl 2017-09-06
LinuxJob 2017-09-06
hfight 2013-12-10
王科 2017-06-20