Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to compile on PHP 5.6 #218

Open
Quix0r opened this issue Sep 12, 2015 · 3 comments
Open

Failed to compile on PHP 5.6 #218

Quix0r opened this issue Sep 12, 2015 · 3 comments

Comments

@Quix0r
Copy link

Quix0r commented Sep 12, 2015

I have the following version on my server:

$ php -v
Zend OPcache requires Zend Engine API version 220100525.
The Zend Engine API version 220131226 which is installed, is newer.
Contact Zend Technologies at http://www.zend.com/ for a later version of Zend OPcache.

PHP 5.6.13-1~dotdeb+7.1 (cli) (built: Sep  4 2015 17:30:11) 
Copyright (c) 1997-2015 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2015 Zend Technologies

I was able to build it for 5.4 but with 5.6 it fails to build:

libtool: compile:  cc -I. -I/home/***/git/ZendOptimizerPlus -DPHP_ATOM_INC -I/home/***/git/ZendOptimizerPlus/include -I/home/***/git/ZendOptimizerPlus/main -I/home/***/git/ZendOptimizerPlus -I/usr/include/php5 -I/usr/include/php5/main -I/usr/include/php5/TSRM -I/usr/include/php5/Zend -I/usr/include/php5/ext -I/usr/include/php5/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home/***/git/ZendOptimizerPlus/ZendAccelerator.c  -fPIC -DPIC -o .libs/ZendAccelerator.o
/home/***/git/ZendOptimizerPlus/ZendAccelerator.c:39:35: fatal error: TSRM/tsrm_virtual_cwd.h: No such file or directory
compilation terminated.
make: *** [ZendAccelerator.lo] Error 1
@dstogov
Copy link
Contributor

dstogov commented Sep 14, 2015

php 5.6 and above uses bundled ext/opcache.

On Sat, Sep 12, 2015 at 11:15 PM, Roland Haeder [email protected]
wrote:

I have the following version on my server:

$ php -v
Zend OPcache requires Zend Engine API version 220100525.
The Zend Engine API version 220131226 which is installed, is newer.
Contact Zend Technologies at http://www.zend.com/ for a later version of Zend OPcache.

PHP 5.6.13-1~dotdeb+7.1 (cli) (built: Sep 4 2015 17:30:11)
Copyright (c) 1997-2015 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2015 Zend Technologies

I was able to build it for 5.4 but with 5.6 it fails to build:

libtool: compile: cc -I. -I/home/_/git/ZendOptimizerPlus -DPHP_ATOM_INC -I/home//git/ZendOptimizerPlus/include -I/home/**/git/ZendOptimizerPlus/main -I/home/_/git/ZendOptimizerPlus -I/usr/include/php5 -I/usr/include/php5/main -I/usr/include/php5/TSRM -I/usr/include/php5/Zend -I/usr/include/php5/ext -I/usr/include/php5/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home//git/ZendOptimizerPlus/ZendAccelerator.c -fPIC -DPIC -o .libs/ZendAccelerator.o
/home/**
/git/ZendOptimizerPlus/ZendAccelerator.c:39:35: fatal error: TSRM/tsrm_virtual_cwd.h: No such file or directory
compilation terminated.
make: *** [ZendAccelerator.lo] Error 1


Reply to this email directly or view it on GitHub
#218.

@transat
Copy link

transat commented Oct 21, 2020

I have this exact issue trying to install zendopcache in PHP 7.3.11 via pecl on my GridServer instance of my MediaTemple server. The Gridserver doesn't include a pre-compiled version of opcache.

@rlerdorf
Copy link
Contributor

You need to build it from the PHP 7.3.11 tarball then.

Grab https://www.php.net/distributions/php-7.3.11.tar.gz

./configure && make

That will give you modules/opcache.so which you can copy to your extension directory and load normally in your ini

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants