Zend framework APC安装

Zend framework APC安装,zend-framework,xampp,apc,Zend Framework,Xampp,Apc,我正试图在我的mac上安装APC。我正在使用XAMPP。我从/Applications/XAMPP/xamppfiles/bin目录运行了这个命令 sudo ./pecl install apc --alldeps 我犯了很多错误。有几个是/否选项,我只是按建议输入。我不确定我做错了什么,但如果有什么可以给我的话,我需要一些建议。我将发布整个安装日志 parsePackageName(): invalid package name "--alldeps" in "--alldeps" inva

我正试图在我的mac上安装APC。我正在使用XAMPP。我从/Applications/XAMPP/xamppfiles/bin目录运行了这个命令

sudo ./pecl install apc --alldeps
我犯了很多错误。有几个是/否选项,我只是按建议输入。我不确定我做错了什么,但如果有什么可以给我的话,我需要一些建议。我将发布整个安装日志

parsePackageName(): invalid package name "--alldeps" in "--alldeps"
invalid package name/package file "--alldeps"
downloading APC-3.1.9.tar ...
Starting to download APC-3.1.9.tar (Unknown size)
.................................................done: 801,792 bytes
54 source files, building
running: phpize-5.3.1
grep: /Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/main/php.h: No such file or directory
grep: /Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/Zend/zend_modules.h: No such file or directory
grep: /Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/Zend/zend_extensions.h: No such file or directory
Configuring for:
PHP Api Version:
Zend Module Api No:
Zend Extension Api No:
Enable internal debugging in APC [no] : no
Enable per request file info about files used from the APC cache [no] : no
Enable spin locks (EXPERIMENTAL) [no] : no
Enable memory protection (EXPERIMENTAL) [no] : no
Enable pthread mutexes (default) [yes] : yes
Enable pthread read/write locks (EXPERIMENTAL) [no] : no
building in /var/tmp/pear-build-root/APC-3.1.9
running: /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/configure --enable-apc-debug=no --enable-apc-filehits=no --enable-apc-spinlocks=no --enable-apc-memprotect=no --enable-apc-pthreadmutex=yes --enable-apc-pthreadrwlocks=no
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for a sed that does not truncate output... /usr/bin/sed
checking for cc... cc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking how to run the C preprocessor... cc -E
checking for icc... no
checking for suncc... no
checking whether cc understands -c and -o together... yes
checking for system library directory... lib
checking if compiler supports -R... no
checking if compiler supports -Wl,-rpath,... yes
checking build system type... i686-apple-darwin11.2.0
checking host system type... i686-apple-darwin11.2.0
checking target system type... i686-apple-darwin11.2.0
checking for PHP prefix... /Applications/XAMPP/xamppfiles
checking for PHP includes... -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1 -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/main -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/TSRM -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/Zend -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/ext -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/ext/date/lib -I/Applications/XAMPP/xamppfiles/include
checking for PHP extension directory... /Applications/XAMPP/xamppfiles/lib/php/php-5.3.1/extensions/no-debug-non-zts-20090626
checking for PHP installed headers prefix... /Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php
checking if debug is enabled... no
checking if zts is enabled... no
checking for re2c... no
configure: WARNING: You will need re2c 0.13.4 or later if you want to regenerate PHP parsers.
checking for gawk... no
checking for nawk... no
checking for awk... awk
checking if awk is broken... no
checking whether to enable APC support... yes, shared
checking whether we should enable cache request file info... no
checking whether we should use mmap... yes
checking whether we should use semaphore locking instead of fcntl... no
checking whether we should use pthread mutex locking... yes
pthread mutexs are supported!
checking whether we should use pthread read/write locking... no
checking whether the target compiler supports builtin atomics... yes
checking whether we should use spin locks... no
checking whether we should enable memory protection... no
checking for zend_set_lookup_function_hook... no
checking for sigaction... yes
checking for union semun... yes
checking whether we should enable valgrind support... checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
yes
checking valgrind/memcheck.h usability... no
checking valgrind/memcheck.h presence... no
checking for valgrind/memcheck.h... no
checking for shm_open in -lrt... no
checking for ld used by cc... /usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld
checking if the linker (/usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld) is GNU ld... no
checking for /usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld option to reload object files... -r
checking for BSD-compatible nm... /usr/bin/nm
checking whether ln -s works... yes
checking how to recognise dependent libraries... pass_all
checking dlfcn.h usability... yes
checking dlfcn.h presence... yes
checking for dlfcn.h... yes
checking the maximum length of command line arguments... 196608
checking command to parse /usr/bin/nm output from cc object... rm: conftest.dSYM: is a directory
rm: conftest.dSYM: is a directory
rm: conftest.dSYM: is a directory
rm: conftest.dSYM: is a directory
ok
checking for objdir... .libs
checking for ar... ar
checking for ranlib... ranlib
checking for strip... strip
rm: conftest.dSYM: is a directory
rm: conftest.dSYM: is a directory
checking if cc static flag  works... rm: conftest.dSYM: is a directory
yes
checking if cc supports -fno-rtti -fno-exceptions... rm: conftest.dSYM: is a directory
no
checking for cc option to produce PIC... -fno-common
checking if cc PIC flag -fno-common works... rm: conftest.dSYM: is a directory
yes
checking if cc supports -c -o file.o... rm: conftest.dSYM: is a directory
yes
checking whether the cc linker (/usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld) supports shared libraries... yes
checking dynamic linker characteristics... darwin11.2.0 dyld
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... no

creating libtool
appending configuration tag "CXX" to libtool
configure: creating ./config.status
config.status: creating config.h
running: make
/bin/sh /private/var/tmp/pear-build-root/APC-3.1.9/libtool --mode=compile cc  -I. -I/Applications/XAMPP/xamppfiles/temp/pear/temp/APC -DPHP_ATOM_INC -I/private/var/tmp/pear-build-root/APC-3.1.9/include -I/private/var/tmp/pear-build-root/APC-3.1.9/main -I/Applications/XAMPP/xamppfiles/temp/pear/temp/APC -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1 -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/main -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/TSRM -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/Zend -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/ext -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/ext/date/lib -I/Applications/XAMPP/xamppfiles/include  -DHAVE_CONFIG_H  -g -O2   -c /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.c -o apc.lo
mkdir .libs
 cc -I. -I/Applications/XAMPP/xamppfiles/temp/pear/temp/APC -DPHP_ATOM_INC -I/private/var/tmp/pear-build-root/APC-3.1.9/include -I/private/var/tmp/pear-build-root/APC-3.1.9/main -I/Applications/XAMPP/xamppfiles/temp/pear/temp/APC -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1 -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/main -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/TSRM -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/Zend -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/ext -I/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/ext/date/lib -I/Applications/XAMPP/xamppfiles/include -DHAVE_CONFIG_H -g -O2 -c /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.c  -fno-common -DPIC -o .libs/apc.o
In file included from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.c:34:
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:61:17: error: php.h: No such file or directory
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:62:30: error: main/php_streams.h: No such file or directory
In file included from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.c:34:
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:69: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:70: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:71: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:72: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:73: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:74: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:77: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:78: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:79: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:80: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:83: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:84: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:85: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:92: error: 'MAXPATHLEN' undeclared here (not in a function)
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:93: error: expected specifier-qualifier-list before 'php_stream_statbuf'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:96: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:99: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:100: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.h:107: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
In file included from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_zend.h:36,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.c:35:
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_php.h:44:18: error: zend.h: No such file or directory
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_php.h:45:22: error: zend_API.h: No such file or directory
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_php.h:46:26: error: zend_compile.h: No such file or directory
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_php.h:47:23: error: zend_hash.h: No such file or directory
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_php.h:48:29: error: zend_extensions.h: No such file or directory
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_php.h:66:21: error: rfc1867.h: No such file or directory
In file included from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.c:35:
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_zend.h:79: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_zend.h:80: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_zend.h:82: warning: parameter names (without types) in function declaration
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_zend.h:83: warning: parameter names (without types) in function declaration
In file included from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_pool.h:34,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_main.h:37,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:43,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:40,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.c:36:
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_sma.h:49: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_sma.h:50: warning: parameter names (without types) in function declaration
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_sma.h:51: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_sma.h:52: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_sma.h:53: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_sma.h:54: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_sma.h:55: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_sma.h:81: error: expected ')' before 'limited'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_sma.h:82: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_sma.h:85: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'apc_sma_get_avail_size'
In file included from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_main.h:37,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:43,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:40,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.c:36:
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_pool.h:63: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_pool.h:65: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_pool.h:66: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_pool.h:77: error: expected specifier-qualifier-list before 'apc_palloc_t'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_pool.h:107: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_pool.h:109: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_pool.h:111: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_pool.h:112: error: expected ';', ',' or ')' before 'TSRMLS_DC'
In file included from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_main.h:38,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:43,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:40,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.c:36:
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_serializer.h:32: error: expected ';', ',' or ')' before '*' token
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_serializer.h:33: error: expected ')' before '*' token
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_serializer.h:36: error: expected declaration specifiers or '...' before 'apc_serialize_t'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_serializer.h:37: error: expected declaration specifiers or '...' before 'apc_unserialize_t'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_serializer.h:38: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_serializer.h:56: error: expected declaration specifiers or '...' before 'apc_serialize_t'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_serializer.h:57: error: expected declaration specifiers or '...' before 'apc_unserialize_t'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_serializer.h:58: error: expected ';', ',' or ')' before 'TSRMLS_DC'
In file included from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:43,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:40,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.c:36:
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_main.h:44: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_main.h:45: warning: parameter names (without types) in function declaration
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_main.h:46: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_main.h:47: warning: parameter names (without types) in function declaration
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_main.h:48: warning: parameter names (without types) in function declaration
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_main.h:49: warning: parameter names (without types) in function declaration
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_main.h:70: error: expected specifier-qualifier-list before 'apc_serialize_t'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_main.h:76: warning: parameter names (without types) in function declaration
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_main.h:77: error: expected ';', ',' or ')' before 'TSRMLS_DC'
In file included from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:40,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.c:36:
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:51: error: expected specifier-qualifier-list before 'zend_function'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:61: error: expected specifier-qualifier-list before 'zend_class_entry'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:91: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:92: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:93: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:94: error: expected ')' before '*' token
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:95: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:115: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:116: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:117: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:124: error: expected ')' before '*' token
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:129: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:130: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'apc_register_optimizer'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:135: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:136: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:141: error: expected ';', ',' or ')' before '*' token
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_compile.h:142: error: expected ')' before '*' token
In file included from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_lock.h:40,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:41,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.c:36:
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_sem.h:35: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_sem.h:37: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_sem.h:38: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_sem.h:39: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_sem.h:40: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_sem.h:41: error: expected ';', ',' or ')' before 'TSRMLS_DC'
In file included from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_lock.h:41,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:41,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.c:36:
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_fcntl.h:35: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_fcntl.h:37: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_fcntl.h:38: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_fcntl.h:39: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_fcntl.h:40: error: expected ';', ',' or ')' before 'TSRMLS_DC'
In file included from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_lock.h:42,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:41,
                 from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.c:36:
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_pthreadmutex.h:31: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_pthreadmutex.h:33: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_pthreadmutex.h:34: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_pthreadmutex.h:35: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'apc_pthreadmutex_nonblocking_lock'
In file included from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.c:36:
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:44:18: error: TSRM.h: No such file or directory
In file included from /Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc.c:36:
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:132: error: expected specifier-qualifier-list before 'zend_op_array'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:140: error: expected specifier-qualifier-list before 'zval'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:173: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:180: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:186: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:201: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:204: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:207: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:215: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:222: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:231: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:236: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:237: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:243: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:254: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:276: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:283: error: expected declaration specifiers or '...' before 'zend_op_array'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:287: error: expected ';', ',' or ')' before 'TSRMLS_DC'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:290: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'apc_compile_cache_entry'
/Applications/XAMPP/xamppfiles/temp/pear/temp/APC/apc_cache.h:296: error: expected ';', ',' or ')' before '*' token
更新
所以我取得了一些更大的进步。事实证明,我需要安装一个开发包来消除大部分错误。我现在正在运行此命令:

sudo pecl install apc
一切都很好,直到最后我得到这个

/usr/include/php/ext/pcre/php_pcre.h:29:18: error: pcre.h: No such file or directory
In file included from /private/tmp/pear/temp/APC/apc.c:44:
/usr/include/php/ext/pcre/php_pcre.h:37: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
/usr/include/php/ext/pcre/php_pcre.h:38: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
/usr/include/php/ext/pcre/php_pcre.h:44: error: expected specifier-qualifier-list before ‘pcre’
/private/tmp/pear/temp/APC/apc.c:393: error: expected specifier-qualifier-list before ‘pcre’
/private/tmp/pear/temp/APC/apc.c: In function ‘apc_regex_compile_array’:
/private/tmp/pear/temp/APC/apc.c:454: error: ‘apc_regex’ has no member named ‘preg’
/private/tmp/pear/temp/APC/apc.c:454: error: ‘apc_regex’ has no member named ‘preg’
/private/tmp/pear/temp/APC/apc.c:455: error: ‘apc_regex’ has no member named ‘nreg’
/private/tmp/pear/temp/APC/apc.c:455: error: ‘apc_regex’ has no member named ‘nreg’
/private/tmp/pear/temp/APC/apc.c: In function ‘apc_regex_match_array’:
/private/tmp/pear/temp/APC/apc.c:487: error: ‘apc_regex’ has no member named ‘preg’
/private/tmp/pear/temp/APC/apc.c:487: error: ‘apc_regex’ has no member named ‘preg’
/private/tmp/pear/temp/APC/apc.c:488: error: ‘apc_regex’ has no member named ‘nreg’
/private/tmp/pear/temp/APC/apc.c:488: error: ‘apc_regex’ has no member named ‘nreg’
make: *** [apc.lo] Error 1
ERROR: `make' failed

现在怎么办?

我认为错误的主要原因之一是PHP头文件似乎丢失或不完整

grep: .../php-5.3.1/php/main/php.h: No such file or directory
grep: .../php-5.3.1/php/Zend/zend_modules.h: No such file or directory
grep: .../php/php-5.3.1/php/Zend/zend_extensions.h: No such file or directory

.../APC/apc.h:61:17: error: php.h: No such file or directory
.../APC/apc.h:62:30: error: main/php_streams.h: No such file or directory
我认为缺少PHP头文件会导致APC文件中的解析错误,因为它没有特定的宏定义

您可以尝试下载并将所有.h文件解压缩到
/Applications/XAMPP/xamppfiles/include/php/php-5.3.1/php/
中。您需要保留目录结构,因为您至少需要
php
Zend
目录中的头文件


由于某些原因,这些文件中的一些被删除了,不在应该的位置,或者XAMPP没有将它们放在正确的位置。

在安装apc之前,请尝试使用sudo yum install pcre devel安装pcre devel。

如果您使用的是任何linux操作系统,则可以使用apc软件包

sudo apt-get install php-apc

参考资料:

日志中实际上还有更多内容,字符已用完。最后一行是错误:“make”失败