gpt4 book ai didi

build - 无法编译 cups(在 Debian 中,使用 dpkg-buildpackage)

转载 作者:行者123 更新时间:2023-12-01 12:39:25 25 4
gpt4 key购买 nike

我已经用 apt-get source cups 下载了 cups 源代码,我正在尝试用 dpkg-buildpackage 编译它。编译失败,出现以下错误:

PASS: All job control files purged.
PASS: Printer 'Test1' correctly produced 55 page(s).
PASS: Printer 'Test2' correctly produced 23 page(s).
PASS: 135 requests logged.
PASS: CUPS-Get-Default not logged.
PASS: 0 emergency messages.
PASS: 0 alert messages.
PASS: 0 critical messages.
FAIL: 19 error messages, expected 18.
E [16/Oct/2014:15:48:55.461975 +0200] Returning IPP client-error-bad-request for Get-Jobs (no URI) from localhost
E [16/Oct/2014:15:48:55.462540 +0200] Missing attributes-natural-language attribute
E [16/Oct/2014:15:48:55.462577 +0200] Missing printer-uri, job-uri, or ppd-name attribute
E [16/Oct/2014:15:48:55.462651 +0200] Returning IPP client-error-bad-request for Get-Jobs (no URI) from localhost
E [16/Oct/2014:15:48:55.463161 +0200] Missing attributes-charset attribute
E [16/Oct/2014:15:48:55.463192 +0200] Missing attributes-natural-language attribute
E [16/Oct/2014:15:48:55.463228 +0200] Missing printer-uri, job-uri, or ppd-name attribute
E [16/Oct/2014:15:48:55.463303 +0200] Returning IPP client-error-bad-request for Get-Jobs (no URI) from localhost
E [16/Oct/2014:15:48:55.463831 +0200] Missing attributes-charset attribute
E [16/Oct/2014:15:48:55.463862 +0200] Missing attributes-natural-language attribute
E [16/Oct/2014:15:48:55.463898 +0200] Missing printer-uri, job-uri, or ppd-name attribute
E [16/Oct/2014:15:48:55.463981 +0200] Returning IPP client-error-bad-request for Get-Jobs (no URI) from localhost
E [16/Oct/2014:15:48:55.464499 +0200] Missing printer-uri, job-uri, or ppd-name attribute
E [16/Oct/2014:15:48:55.464590 +0200] Returning IPP client-error-bad-request for Get-Jobs (no URI) from localhost
E [16/Oct/2014:15:48:55.465803 +0200] Returning IPP client-error-bad-request for Get-Jobs (ipp://localhost:8631/jobs) from localhost
E [16/Oct/2014:15:48:55.466380 +0200] Returning IPP server-error-version-not-supported for Get-Jobs (no URI) from localhost
E [16/Oct/2014:15:48:55.522710 +0200] Returning IPP client-error-bad-request for Print-Job (ipp://localhost:8631/printers/Test1) from localhost
E [16/Oct/2014:15:49:02.558807 +0200] Returning IPP client-error-too-many-subscriptions for Create-Printer-Subscription (ipp://localhost:8631/printers/Test1) from localhost
E [16/Oct/2014:15:49:13.164121 +0200] [cups-deviced] PID 8234 (usb) crashed on signal 11!
E [16/Oct/2014:15:49:13.164484 +0200] [cups-deviced] PID 8235 (snmp) stopped with status 1!
PASS: 9 warning messages.
PASS: 0 notice messages.
PASS: 787 info messages.
PASS: 9755 debug messages.
PASS: 19774 debug2 messages.

1 tests failed.
Log files can be found in /tmp/cups-martin/log.
A HTML report was created in /tmp/cups-martin/cups-str-1.5-2014-10-16-martin.html.

Copies of the error_log and cups-str-1.5-2014-10-16-martin.html files are in
/home/martin/src/debian/cups-1.5.3/test.

make[1]: *** [check] Error 1
make[1]: Leaving directory `/home/martin/src/debian/cups-1.5.3'
make: *** [debian/stamp-makefile-check] Error 2
dpkg-buildpackage: error: debian/rules build gave error exit status 2

我不知道哪里出了问题。我已经安装了所有构建依赖项。

我正在使用 Debian Wheezy

有人可以帮忙吗?

最佳答案

apt-get build-dep cups 应该运行以获取 cups 的所有构建依赖项。我知道您说您安装了所有依赖项,但由于您没有说明您是如何安装的,所以我提供该命令作为我用来执行此操作的机制。

我想到了很多事情。某些软件包在以 root 用户身份完成时构建得不好(您不会找到这样说的官方来源,但我多年来在 Debian 上构建软件包时观察到了这一点)。通常,我以普通用户身份构建软件,但使用的是 fakeroot。因为我更喜欢使用 fakeroot 来构建包,所以我确保通过 apt-get install fakeroot 安装了 fakeroot。然后作为非 root 用户,我会执行 apt-get source cups 然后执行典型的 dpkg-buildpackage -b -us -uc -rfakeroot 以在 Debian 上构建二进制文件系统。作为非 root 用户,我碰巧在我的 Debian Wheezy 系统上构建了 Cups 1.5.3,没有任何问题。

我碰巧以 root 身份尝试此构建,有趣的是 cups 在尝试启动调度程序时在测试期间卡住了。作为非 root 用户,此问题不存在。尽管我的系统上发生的事情并没有产生相同的结果错误,因为我的测试根本无法完成!

如果您还没有这样做,我建议您尝试使用 fakeroot 作为非 root 用户进行构建。

具体到你的调试输出,我觉得这很奇怪:

[cups-deviced] PID 8234 (usb) 在信号 11 上崩溃!

我想知道在测试过程中是否是 USB 打印机设备的问题导致了您的失败。您的系统是否有直接连接的 USB 打印机?如果是这样,请尝试断开它并进行构建。我想知道是否特定于特定 USB 打印机的 cups-device 子系统中的问题导致了 cups 构建期间的此故障。

我碰巧找到了这个bug report关于 cups-device 和 signal 11 的类似问题(在较旧的 Ubuntu - 基于 Debian 的系统上)。这是一个较旧的错误,显然已修复,但我想知道是否还有其他情况仍然存在问题。该错误是这样说的:

But, for some reason or another, Ubuntu 9.10 and 10.04 does not properly recognize the existence of USB printers anymore. It does not recognize my HP Laserjet 4 and probably fails to recognize other USB printers, too.

然后它会在错误日志中提供此内容,这类似于您在构建杯子时在测试期间看到的错误:

Architecture: amd64
CupsErrorLog:
E [18/Apr/2010:09:43:44 -0600] [cups-deviced] PID 1768 (usb) crashed on signal 11!
E [18/Apr/2010:09:46:36 -0600] [cups-deviced] PID 1817 (usb) crashed on signal 11!

关于build - 无法编译 cups(在 Debian 中,使用 dpkg-buildpackage),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/26407766/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com