System: ubuntu 16.0.4 LTS x64 PHP: php-7.1.0 MySQL: mysql-5.7.x Apache: Apache2.4.25
phpOptions at compile install time:
cd phpDir ./configure --with-apxs2=/usr/local/apache2/apxs --with-config-file-path=/usr/local/bin/lib/php/config --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd --with-openssl --enable-mbstring --enable-ftp --enable-pcntl --enable-sockets --enable-zip --enable-mysqlnd --enable-maintainer-zts --enable-tsrm-pthreads make make install
--enable-maintainer-ztsThe explanation of this paper is as follows:
PHP ZTSIt’s on. This one is on
POSIX header file (pthread. H)I am here
/usr/local/include/pthread.hI found it in the library.
--enable-tsrm-pthreadsThe explanation of this paper is as follows:
Then, I compile and generate
pthreads.soHow to file:
Sudo MV pthreads. / phpdir / ext # move the downloaded pthreads to the extension directory under the PHP source code package cd phpDir/ext/pthreads Sudo phpize # successfully generated the configure file Sudo. / configure? Success Sudo make # failed! Sudo make install # not executed
sudo makeThere are many compile time errors:
Makefile:196: recipe for target 'php_pthreads.lo' failed make: *** [php_pthreads.lo] Error 1
I have been very helpless. It should be said that the PHP version corresponds to the pthreads version. Then, the various settings should also meet the requirements, that is, I don’t know why they can’t be generated successfully
Various additions on the network
Add pthreads to PHP in UbuntuI’ve seen them all, but I can’t find a solution! Seek a solution!??
The problem has been solved. Download the pthreads extension on GitHub. There is a problem with the extension on PECL’s official websitehttp://pecl.php.net/package/p…
I also have the same problem. My php7.1.3 is also downloaded from GitHub or not. Which version do you download? I downloaded 3.1.6
The current version 3.1.6 requires at least php7.2 +. Your PHP version is too low.
How do you look at the official website description document