|if [[ $EUID -ne 0 ]]; then|
|echo "This script must be run as root" 1>&2|
|apt-get install -y git-core autoconf bison libxml2-dev libbz2-dev libmcrypt-dev libcurl4-openssl-dev libltdl-dev libpng-dev libpspell-dev libreadline-dev make|
|mkdir -p /etc/php7/conf.d|
|mkdir -p /etc/php7/cli/conf.d|
|git clone https://github.com/php/php-src.git --depth=1|
|./configure --prefix=/usr/local/php7 --enable-bcmath --with-bz2 --enable-calendar --enable-exif --enable-dba --enable-ftp --with-gettext --with-gd --enable-mbstring --with-mcrypt --with-mhash --enable-mysqlnd --with-mysql=mysqlnd --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd --with-openssl --enable-pcntl --with-pspell --enable-shmop --enable-soap --enable-sockets --enable-sysvmsg --enable-sysvsem --enable-sysvshm --enable-wddx --with-zlib --enable-zip --with-readline --with-curl --with-config-file-path=/etc/php7/cli --with-config-file-scan-dir=/etc/php7/cli/conf.d|
is it normal that make test return "You may have found a problem in PHP."?
I get this error during
Installing PEAR environment: /usr/local/php7/lib/php/ --2015-12-03 11:24:08-- https://pear.php.net/install-pear-nozlib.phar Resolving pear.php.net (pear.php.net)... 220.127.116.11 Connecting to pear.php.net (pear.php.net)|18.104.22.168|:443... connected. ERROR: no certificate subject alternative name matches requested host name ‘pear.php.net’. To connect to pear.php.net insecurely, use `--no-check-certificate'. make: *** [install-pear] Error 5
How can I fix it? I can't just
@Faryshta I am guessing, he is talking about the Makefile in php-src folder. The pear server has problem, they replaced with a new machine and the SSL certificates don't match which means you will have to use http protocol instead. It worked for me :D. Just find https://pear.php.net/install-pear-nozlib.phar and replace with http://pear.php.net/install-pear-nozlib.phar
Ran all the commands, had to change the pear address from https to http in /tmp/php-src/makefile before running make install. But how do I connect with it using nginx, for example? I tried this:
but didn't work. I tried php.sock and php7-fpm.sock and those didn't work either.
Am I missing something here?
After this I tried the instructions here - https://bjornjohansen.no/upgrade-to-php7
So...great PHP7 is out but I can't install it...
The gist is failing for me on Ubuntu14.04:
I actually got it to work after reboot php -v:
php info in web browser still shows 5.6. The other weird part is that I get raw php in browser until I refresh each page.
add --with-apxs2 to ./configure for create /usr/lib/apache2/modules/libphp7.so
work on ubuntu 15.10 :)
PHP 7.1.0-dev (cli) (built: Dec 5 2015 12:40:12) ( NTS )
Looks like the pear server is having dramas:
So you will have thep atch your files, as above.
Also make sure you're on 7.0.0 if you want extensions etc to work properly :).
If you are lazy:
So this is what ended up working for me on Ubuntu 14.04 with Nginx:
Then edit your Nginx config file:
Then restart Nginx:
Script is falling for me
TIME END 2015-12-15 13:58:47
TEST RESULT SUMMARY
Exts skipped : 22
Exts tested : 53
Number of tests : 14319 11560
Tests passed : 11513 ( 80.4%) ( 99.6%)
Time taken : 409 seconds
EXPECTED FAILED TEST SUMMARY
Test open_basedir configuration [tests/security/open_basedir_linkinfo.phpt] XFAIL REASON: BUG: open_basedir cannot delete symlink to prohibited file. See also
Bug #70470 (Built-in server truncates headers spanning over TCP packets) [sapi/cli/tests/bug70470.phpt] XFAIL REASON: bug is not fixed yet
FAILED TEST SUMMARY
Bug #61948 (CURLOPT_COOKIEFILE '' raises open_basedir restriction) [ext/curl/tests/bug61948.phpt]
Test glob() function: ensure no platform difference, variation 3 [ext/standard/tests/file/glob_variation5.phpt]
WARNED TEST SUMMARY
Live range & throw from finally [Zend/tests/temporary_cleaning_010.phpt](warn: XFAIL section but test passes)
Bug #70219 Use after free vulnerability in session deserializer [ext/standard/tests/serialize/bug70219.phpt](warn: XFAIL section but test passes)
You may have found a problem in PHP.
Please add root-permission check like @akeinhell stated 7 days ago:
Also, add the 'make' package to 'apt-get install' list of packages; I just installed a fresh 14.04 server, and that package was missing :)