apt-rdepends 不显示多架构信息

apt-rdepends 不显示多架构信息

我正在apt-rdepends使用AMD64系统与i386作为外国建筑。但似乎apt-rdepends丢失了包的架构信息:

$ apt-rdepends libgcc1:i386
Reading package lists... Done
Building dependency tree       
Reading state information... Done
libgcc1:i386
  Depends: gcc-4.9-base (= 4.9-20140406-0ubuntu1)
  Depends: libc6 (>= 2.2.4)
  PreDepends: multiarch-support
gcc-4.9-base
libc6
  Depends: libgcc1
libgcc1
  Depends: gcc-4.9-base (= 4.9-20140406-0ubuntu1)
  Depends: libc6 (>= 2.14)
  PreDepends: multiarch-support
multiarch-support
  Depends: libc6 (>= 2.3.6-2)

虽然apt-cache显示了正确的架构但无法递归:

$ apt-cache depends libgcc1:i386
libgcc1:i386
  Depends: gcc-4.9-base:i386
  Depends: libc6:i386
  PreDepends: multiarch-support:i386
    multiarch-support
  Breaks: <gcc-4.3>
  Breaks: <gcc-4.3:i386>
  Breaks: gcc-4.4
  Breaks: gcc-4.4:i386
  Breaks: <gcc-4.5>
  Breaks: <gcc-4.5:i386>
  Replaces: libgcc1
  Breaks: libgcc1

关于如何在不丢失架构信息的情况下递归检索依赖项有什么建议吗?

答案1

正如您所发现的,apt-cache depends'--recurse选项提供了一种递归变体。为了使其有用,您需要禁用一些依赖项类型:

$ apt-cache depends --recurse --no-breaks --no-replaces --no-suggests libgcc1:i386

libgcc1:i386
  Depends: gcc-6-base:i386
  Depends: libc6:i386
gcc-6-base:i386
libc6:i386
  Depends: libgcc1:i386
  Replaces: libc6-i686:i386
    libc6:i386
libc6-i686:i386

apt-rdepends成为孤儿并且尚未更新以正确支持多架构。 (我想说现在不太可能出现这种情况。)

答案2

正如我在评论中发布的那样,它本身apt-cache depends就有一个--recurse选项。

关闭除 和 之外的所有其他包关系DependsPreDepends我得到了我需要的输出:

$ apt-cache depends --recurse --no-recommends --no-suggests --no-conflicts --no-breaks --no-replaces --no-enhances
libc6:i386
  Depends: libgcc1:i386
libgcc1:i386
  Depends: gcc-4.9-base:i386
  Depends: libc6:i386
  PreDepends: multiarch-support:i386
    multiarch-support
gcc-4.9-base:i386
multiarch-support:i386
  Depends: libc6:i386
multiarch-support
  Depends: libc6
libc6
  Depends: libgcc1
libgcc1
  Depends: gcc-4.9-base
  Depends: libc6
  PreDepends: multiarch-support
    multiarch-support:i386
gcc-4.9-base

相关内容