假设php5.6安装路径为/data2/php
[root@nextcloud src]# pwd/usr/local/src[root@nextcloud src]# wget [root@nextcloud src]# tar zxvf zendopcache-7.0.5.tgz[root@nextcloud src]# cd zendopcache-7.0.5[root@nextcloud zendopcache-7.0.5]# /data2/php/bin/phpize[root@nextcloud zendopcache-7.0.5]# ./configure --with-php-config=/data2/php/bin/php-config[root@nextcloud zendopcache-7.0.5]# make && make install[root@nextcloud zendopcache-7.0.5]# # ll /data2/php/lib/php/extensions/no-debug-non-zts-20131226total 1656-rwxr-xr-x 1 root root 1104672 Nov 13 00:07 opcache.a-rwxr-xr-x 1 root root 586768 Nov 13 00:07 opcache.so[root@nextcloud zendopcache-7.0.5]# vim /data2/php/lib/php.inizend_extension=opcache.so[root@nextcloud zendopcache-7.0.5]# /etc/init.d/php-fpm restart
[root@nextcloud zendopcache-7.0.5]# /data2/php/bin/php -m......Zend OPcache......