我尝试在 CentOS 7 上从源代码构建 apr-utils-1.6.1 (目标是获得 httpd-2.4.29),但我遇到了一个依赖问题:
# rpmbuild -tb apr-util-1.6.1.tar.bz2
error: Failed build dependencies:
db4-devel is needed by apr-util-1.6.1-1.x86_64
yum 中不提供 db4-devel,而 libdb-devel 提供版本 5,该版本不满足依赖关系要求。
我尝试下载并安装 db4-devel,但它有它自己的依赖项,我无法满足:
# rpm -iv db4-devel-4.7.25-22.el6.x86_64.rpm
warning: db4-devel-4.7.25-22.el6.x86_64.rpm: Header V3 RSA/SHA1 Signature, key ID c105b9de: NOKEY
error: Failed dependencies:
db4 = 4.7.25-22.el6 is needed by db4-devel-4.7.25-22.el6.x86_64
db4-cxx = 4.7.25-22.el6 is needed by db4-devel-4.7.25-22.el6.x86_64
libdb-4.7.so()(64bit) is needed by db4-devel-4.7.25-22.el6.x86_64
libdb_cxx-4.7.so()(64bit) is needed by db4-devel-4.7.25-22.el6.x86_64
尝试安装 db4 也会失败,因为 Berkely DB 版本 5 已经安装并在 CentOS 7 上使用:
# rpm -iv db4-4.7.25-22.el6.x86_64.rpm
warning: db4-4.7.25-22.el6.x86_64.rpm: Header V3 RSA/SHA1 Signature, key ID c105b9de: NOKEY
error: Failed dependencies:
db4 < 5 is obsoleted by (installed) libdb-5.3.21-20.el7.x86_64
我现在不太确定如何继续。我是否只需要部署一台 CentOS 6 机器来减少损失?看来CentOS 6还是有db4的。我正在考虑修改规范文件以删除 db4 要求,但我不确定这会产生什么影响,或者如何正确地做到这一点。
谢谢。