Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I need to get APC running for a Drupal install of mine. I found a fairly concise guide at for installing on FC11, only, I am using FC12. I figured I would give it a shot.

I was able to run the following commands successfully - and yum installed fc12 versions of everything in the FC11 guide.

 yum install php-pear

    yum install php-devel httpd-devel

    yum groupinstall ‘Development Tools’

    yum groupinstall ‘Development Libraries’

Then, I tried pecl install apc. Everything looked good until to got to the end, where it outputted the following error.

/var/tmp/APC/php_apc.c: In function ‘zif_apc_compile_file’:
/var/tmp/APC/php_apc.c:881: warning: unused variable ‘eg_class_table’
/var/tmp/APC/php_apc.c:881: warning: unused variable ‘eg_function_table’
/var/tmp/APC/php_apc.c: At top level:
/var/tmp/APC/php_apc.c:959: error: duplicate ‘static’
make: *** [php_apc.lo] Error 1
ERROR: `make' failed

Some people have had success with installing apc-beta, but that didn't work for me..

Any suggestions? Is there something I missed that is critical in the FC12 version?

share|improve this question

To resolve this and reinstall the APC(make sure that EAccelerator removed from php),before reinstall the APC install the following packages :-

yum install pcre-devel

before installing APC.

On Debian use

aptitude install libpcre3-dev

Then you will get the following response when you reinstall the APC :-

share|improve this answer
up vote 1 down vote accepted

This is what worked for me..

# # install APC package  
# yum install php-pecl-apc  
# # install gd package to have graphs in APC dashboard (optional)  
# yum install php-gd  

I found this at..

share|improve this answer

another solution that worked for me was to edit the file /var/tmp/APC/php_apc.c and remove "static" from line 959. then i ran make and make install and it worked.

share|improve this answer
This seems very likely to be specific to a particular version of the code. Could you give more context? – mattdm Sep 29 '15 at 21:21

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.