我正在尝试在PHP中获取rename_function
的访问权限,为此我需要PECL APD。我使用Ubuntu 14.04 LTS。
我正在尝试运行sudo pecl install apd
,但我得到了以下错误:
downloading apd-1.0.1.tgz ... Starting to download apd-1.0.1.tgz (36,643 bytes) ..........done: 36,643 bytes 15 source files, building running: phpize Cannot find config.m4. Make sure that you run '/usr/bin/phpize' in the top level source directory of the module If the command failed with 'phpize: not found' then you need to install php5-dev package. You can do it by running 'apt-get install php5-dev' as a root userERROR: `phpize' failed
我应该从特定目录运行此命令吗?
这次我尝试打开详细选项,以便日志中有线索:
sudo /usr/bin/pecl -vvvvv install apd
Warning: file_exists(): Unable to find the wrapper "channel" - did you forget to enable it when you configured PHP? in PEAR/Downloader/Package.php on line 1518添加到事务:重命名 /usr/share/php/doc/apd/.tmpLICENSE 为 /usr/share/php/doc/apd/LICENSE 添加到事务:安装为 LICENSE /usr/share/php/doc/apd/LICENSE /usr/share/php/doc/apd + 将 /tmp/pear/temp/tmpNUpEpz/apd-1.0.1/README 复制到 /usr/share/php/doc/apd/.tmpREADME 添加到事务:将 /usr/share/php/doc/apd/.tmpREADME 的权限更改为 664 添加到事务:重命名 /usr/share/php/doc/apd/.tmpREADME 为 /usr/share/php/doc/apd/README 添加到事务:安装为 README /usr/share/php/doc/apd/README /usr/share/php/doc/apd + 将 /tmp/pear/temp/tmpNUpEpz/apd-1.0.1/pprofp 复制到 /usr/bin/.tmppprofp + 将 /usr/bin/.tmppprofp 的权限更改为可执行 添加到事务:将 /usr/bin/.tmppprofp 的权限更改为 775 添加到事务:重命名 /usr/bin/.tmppprofp 为 /usr/bin/pprofp 添加到事务:安装为 pprofp /usr/bin/pprofp /usr/bin/ + 将 /tmp/pear/temp/tmpNUpEpz/apd-1.0.1/pprof2calltree 复制到 /usr/bin/.tmppprof2calltree + 将 /usr/bin/.tmppprof2calltree 的权限更改为可执行 添加到事务:将 /usr/bin/.tmppprof2calltree 的权限更改为 775 添加到事务:重命名 /usr/bin/.tmppprof2calltree 为 /usr/bin/pprof2calltree 添加到事务:安装为 pprof2calltree /usr/bin/pprof2calltree /usr/bin/ 15 个源文件,正在构建中 正在构建于 /tmp/pear/temp/pearf7LGca 正在执行:phpize 找不到 config.m4 文件。 请确保在模块的顶级源目录中运行 '/usr/bin/phpize' 命令
Warning: is_file(): Unable to find the wrapper "channel" - did you forget to enable it when you configured PHP? in PEAR/Downloader/Package.php on line 1528
Warning: is_file(): Unable to find the wrapper "channel" - did you forget to enable it when you configured PHP? in PEAR/Downloader/Package.php on line 1528 Downloading "http://pecl.php.net/get/apd-1.0.1.tgz" downloading apd-1.0.1.tgz ... Starting to download apd-1.0.1.tgz (36,643 bytes) ..........done: 36,643 bytes + cp /tmp/pear/temp/tmpNUpEpz/apd-1.0.1/LICENSE /usr/share/php/doc/apd/.tmpLICENSE adding to transaction: chmod 664 /usr/share/php/doc/apd/.tmpLICENSE
如果命令返回 'phpize: not found',则需要以 root 用户身份安装 php5-dev 包。可以通过运行 'apt-get install php5-dev' 来实现。回滚了 12 个文件操作 + 删除 /usr/share/php/doc/apd/.tmpLICENSE + 删除 /usr/share/php/doc/apd/.tmpREADME+ rm /usr/bin/.tmpprofp + rm /usr/bin/.tmppprof2calltree 错误: `phpize' 失败
警告:在 System.php 的 214 行,unlink(/tmp/glibctestRdKE0K) 没有找到该文件或目录。
警告:在 System.php 的 214 行,unlink(/tmp/pear/temp/pearf7LGca) 没有找到该文件或目录。