Public bug reported:

When installing PHP 7.0 and php-apcu package, php-apcu-bc is also
installed which provides backward compatibility for apc_* functions.
However, for PHP 7.1 this is not the case.

Currently php-apcu-bc package does not work with PHP 7.1, and for apc to
function in PHP 7.1 the php-apc-bc must be manually compiled and
installed.

$ lsb_release -rd
Description:    Ubuntu 14.04.5 LTS
Release:        14.04

php-apcu-bc:
  Installed: 1.0.3-4+donate.sury.org~trusty+1
  Candidate: 1.0.3-4+donate.sury.org~trusty+1
  Version table:
 *** 1.0.3-4+donate.sury.org~trusty+1 0
        500 http://ppa.launchpad.net/ondrej/php/ubuntu/ trusty/main amd64 
Packages
        100 /var/lib/dpkg/status

Steps to reproduce:

$ add-apt-repository ppa:ondrej/php
$ apt-get update
$ apt-get install -y php7.0-cli php7.1-cli php-apcu

Get:1 http://archive.ubuntu.com/ubuntu/ trusty/main psmisc amd64 22.20-1ubuntu2 
[53.2 kB]
Get:2 http://ppa.launchpad.net/ondrej/php/ubuntu/ trusty/main libssl1.0.2 amd64 
1.0.2j-1+deb.sury.org~trusty+1 [1268 kB]
Get:3 http://ppa.launchpad.net/ondrej/php/ubuntu/ trusty/main libedit2 amd64 
3.1-20140620-2+deb.sury.org~trusty+1 [84.4 kB]
Get:4 http://ppa.launchpad.net/ondrej/php/ubuntu/ trusty/main php-common all 
1:45+deb.sury.org~trusty+1 [13.0 kB]
Get:5 http://ppa.launchpad.net/ondrej/php/ubuntu/ trusty/main php7.1-common 
amd64 7.1.0-2+deb.sury.org~trusty+1 [875 kB]
Get:6 http://ppa.launchpad.net/ondrej/php/ubuntu/ trusty/main php7.1-json amd64 
7.1.0-2+deb.sury.org~trusty+1 [17.4 kB]
Get:7 http://ppa.launchpad.net/ondrej/php/ubuntu/ trusty/main php7.1-opcache 
amd64 7.1.0-2+deb.sury.org~trusty+1 [140 kB]
Get:8 http://ppa.launchpad.net/ondrej/php/ubuntu/ trusty/main php7.1-readline 
amd64 7.1.0-2+deb.sury.org~trusty+1 [12.1 kB]
Get:9 http://ppa.launchpad.net/ondrej/php/ubuntu/ trusty/main php7.1-cli amd64 
7.1.0-2+deb.sury.org~trusty+1 [1296 kB]
Get:10 http://ppa.launchpad.net/ondrej/php/ubuntu/ trusty/main php7.0-common 
amd64 7.0.13-1+deb.sury.org~trusty+1 [874 kB]
Get:11 http://ppa.launchpad.net/ondrej/php/ubuntu/ trusty/main php7.0-json 
amd64 7.0.13-1+deb.sury.org~trusty+1 [17.2 kB]
Get:12 http://ppa.launchpad.net/ondrej/php/ubuntu/ trusty/main php7.0-opcache 
amd64 7.0.13-1+deb.sury.org~trusty+1 [75.9 kB]
Get:13 http://ppa.launchpad.net/ondrej/php/ubuntu/ trusty/main php7.0-readline 
amd64 7.0.13-1+deb.sury.org~trusty+1 [12.2 kB]
Get:14 http://ppa.launchpad.net/ondrej/php/ubuntu/ trusty/main php7.0-cli amd64 
7.0.13-1+deb.sury.org~trusty+1 [1254 kB]
Get:15 http://ppa.launchpad.net/ondrej/php/ubuntu/ trusty/main php-apcu amd64 
5.1.7+4.0.11-2+deb.sury.org~trusty+1 [90.1 kB]
Get:16 http://ppa.launchpad.net/ondrej/php/ubuntu/ trusty/main php-apcu-bc 
amd64 1.0.3-4+donate.sury.org~trusty+1 [8284 B]

$ php7.0 -r "var_dump(apc_fetch(1));"
bool(false)

$ php7.1 -r "var_dump(apc_fetch(1));"
PHP Fatal error:  Uncaught Error: Call to undefined function apc_fetch() in 
Command line code:1
Stack trace:
#0 {main}
  thrown in Command line code on line 1

** Affects: php-apcu (Ubuntu)
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1647725

Title:
  Please add php-apcu-bc to PHP 7.1

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/php-apcu/+bug/1647725/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to