关于编译安装php的选项可以为
| 1 | ./configure --prefix=/usr/local/php --with-mysql=mysqlnd --with-pdo-mysql=mysqlnd --with-mysqli=mysqlnd --with-iconv --with-openssl --enable-mbstring --with-freetype-dir --with-jpeg-dir --with-png-dir --with-libxml-dir=/usr/ --enable-xml --enable-sockets --enable-fpm --with-config-file-path=/etc/ --with-config-file-scan-dir=/etc/php.d --with-bz2 --with-curl --with-mhash --with-mcrypt --enable-intl --with-gd --enable-gd-native-ttf --enable-shmop |
需要安装memcache需要编译libmemcache
libmemcached的下载地址为https://launchpad.net/libmemcached
编译安装
wget tar xf libmemcached-1.0.18.tar.gz cd libmemcached-1.0.18.tar.gz./configure make && make install |
扩展memcache模块
memcached的模块地址为http://pecl.php.net/package/memcache
编译安装
| 1 | <a style="color: rgb(66, 133, 244);" href="http://pecl.php.net/get/memcache-3.0.8.tgz" target="_blank">http://pecl.php.net/get/memcache-3.0.8.tgz</a> |
| 12345 | tar xf memcache-3.0.8.tgzcd memcache-3.0.8 进入解压以后的目录,是没有configure文件的,需要执行 /usr/local/php/bin/phpize ./configure --with-php-config=/usr/local/php/bin/php-config make && make install |
编辑php.ini文件,在里面添加以下行
| 1 | extension=memcache.so |
redis的模块添加与memcached的一样
redis的下载地址为http://pecl.php.net/package/redis
编译完成后同样需要添加extesion文件
本文以及验证通过,此处不在给出验证结果
点击查看更多内容
为 TA 点赞
评论
共同学习,写下你的评论
评论加载中...
作者其他优质文章
正在加载中
感谢您的支持,我会继续努力的~
扫码打赏,你说多少就多少
赞赏金额会直接到老师账户
支付方式
打开微信扫一扫,即可进行扫码打赏哦