尝试安装 xulrunner 1.9.2 时,出现以下错误:
Setting up xulrunner-1.9.2 (1.9.2.28+build1+nobinonly-0ubuntu0.10.04.1) ...
/var/lib/dpkg/info/xulrunner-1.9.2.postinst: 8: /var/lib/dpkg/info/xulrunner-1.9.2.postinst: /usr/sbin/update-alternatives: not found
dpkg: error processing package xulrunner-1.9.2 (--configure):
subprocess installed post-installation script returned error exit status 127
Errors were encountered while processing:
xulrunner-1.9.2
E: Sub-process /usr/bin/dpkg returned an error code (1)
答案1
sudo nano /var/lib/dpkg/info/xulrunner-1.9.2.prerm
删除除此以外的所有内容
#!/bin/sh
set -e
sudo dpkg -P --force-all xulrunner-1.9.2
结果
抑制 xulrunner-1.9.2 (1.9.2.28+build1+nobinonly-0ubuntu0.11.04.1)...清除 xulrunner-1.9.2 (1.9.2.28+build1+nobinonly-0ubuntu0.11.04.1) 的配置文件...
祝你好运 :)