PHP APC installation failed on Ubuntu
Asked Answered
G

2

9

I have done this

sudo apt-get install php-pear php5-dev make libpcre3-dev

and then

sudo pecl install apc

But I'm getting this error:

                         ^
make: *** [apc_compile.lo] Error 1
ERROR: `make' failed

Do you have idea what can be issue? And how to solve it?

Gastroenterostomy answered 7/2, 2014 at 11:19 Comment(0)
B
28

Why do you install PHP over the package manager and APC over PECL?

apt-get install php-apc

is much easier and you get the correct package for APC.

Brownlee answered 7/2, 2014 at 11:22 Comment(4)
I have done "apt-get install php-apc" and then "sudo pecl install pac" and again the same errorGastroenterostomy
You don't need pecl. You have installed the package over the package manager. Restart PHP / Apache and its working.Cerebrum
With "apt-get install php-apc".Cerebrum
Please also refer : bugs.php.net/bug.php?id=65731 [2013-09-21 14:38 UTC] [email protected] -Status: Open +Status: Suspended [2013-09-21 14:38 UTC] [email protected] APC doesn't support PHP 5.5. PHP 5.5 comes bundled with an opcode cache now.Mango
B
0

Just an addition to the answer mentioned as correct. I got

Package 'php-apc' has no installation candidate

when tried to install with sudo apt-get install php-apc. So try sudo apt-get install php-apcu and use apcu instead of apc everywhere.

Booker answered 14/5, 2021 at 11:42 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.