dongzhaiqiang6108 2015-11-13 15:17
浏览 66

使用Pear with Puppet安装PHP CodeSniffer的问题

I'm using Vagrant and Puppet to set up a virtual machine. I'm encountering problems with PHP CodeSniffer being installed from Pear. The error I see is this:

==> default: err: /Stage[main]//Package[pear.php.net/PHP_CodeSniffer]/ensure: change from absent to present failed: Execution of '/usr/bin/pear upgrade -a pear.php.net/PHP_CodeSniffer' returned 1: Failed loading /usr/lib/php5/20090626+lfs/xdebug.so:  /usr/lib/php5/20090626+lfs/xdebug.so: cannot open shared object file: No such file or directory
==> default: downloading PHP_CodeSniffer-2.3.4.tgz ...
==> default: Starting to download PHP_CodeSniffer-2.3.4.tgz (473,411 bytes)
==> default: ................................................................................................done: 473,411 bytes
==> default: could not extract the package.xml file from "/build/php5-q1fasi/php5-5.3.10/pear-build-download/PHP_CodeSniffer-2.3.4.tgz"
==> default: Download of "pear/PHP_CodeSniffer" succeeded, but it is not a valid package archive
==> default: Error: cannot download "pear/PHP_CodeSniffer"
==> default: Download failed
==> default: upgrade failed
==> default:
==> default: notice: /Stage[main]//Vcsrepo[/usr/share/php/PHP/CodeSniffer/Standards/WordPress]: Dependency Package[pear.php.net/PHP_CodeSniffer] has failures: true
==> default: warning: /Stage[main]//Vcsrepo[/usr/share/php/PHP/CodeSniffer/Standards/WordPress]: Skipping because of failed dependencies

I also can't manually install the package and see the same error. It seems to be related to an already reported problem whereby Ubuntu can have problems unpackaging tgz files.

The relevant part of my Puppet file looks like this:

# Install PHP_CodeSniffer and the WordPress coding standard
package { 'pear.php.net/PHP_CodeSniffer':
  ensure   => 'installed',
  provider => 'pear',
}

Anyone have any ideas on how I can request the non-compressed version? Any other suggestions for resolving this problem much appreciated.

  • 写回答

1条回答 默认 最新

  • dougou3871 2015-11-15 21:09
    关注

    I'd guess that you're missing zip or zlib extensions in PHP.

    评论

报告相同问题?

悬赏问题

  • ¥50 comfyui下连接animatediff节点生成视频质量非常差的原因
  • ¥20 有关区间dp的问题求解
  • ¥15 多电路系统共用电源的串扰问题
  • ¥15 slam rangenet++配置
  • ¥15 有没有研究水声通信方面的帮我改俩matlab代码
  • ¥15 对于相关问题的求解与代码
  • ¥15 ubuntu子系统密码忘记
  • ¥15 信号傅里叶变换在matlab上遇到的小问题请求帮助
  • ¥15 保护模式-系统加载-段寄存器
  • ¥15 电脑桌面设定一个区域禁止鼠标操作