对于某些软件包,“dpkg -l”输出中的 amd64 是什么,而对于其他软件包则不是?

对于某些软件包,“dpkg -l”输出中的 amd64 是什么,而对于其他软件包则不是?

dpkg -l以下是我的 Ubuntu 系统上的命令输出,

Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name                            Version                                    Architecture Description
+++-===============================-==========================================-============-===============================================================================
ii  adduser                         3.113+nmu3ubuntu3                          all          add and remove users and groups
ii  apt                             1.0.1ubuntu2.19                            amd64        commandline package manager
ii  apt-utils                       1.0.1ubuntu2.19                            amd64        package management related utility programs
ii  base-files                      7.2ubuntu5.5                               amd64        Debian base system miscellaneous files
ii  base-passwd                     3.5.33                                     amd64        Debian base system master password and group files
ii  bash                            4.3-7ubuntu1.7                             amd64        GNU Bourne Again SHell
ii  bsdutils                        1:2.20.1-5.1ubuntu20.9                     amd64        Basic utilities from 4.4BSD-Lite
ii  busybox-initramfs               1:1.21.0-1ubuntu1                          amd64        Standalone shell setup for initramfs
ii  bzip2                           1.0.6-5                                    amd64        high-quality block-sorting file compressor - utilities
ii  console-setup                   1.70ubuntu8                                all          console font and keymap setup program
ii  coreutils                       8.21-1ubuntu5.4                            amd64        GNU core utilities
ii  cpio                            2.11+dfsg-1ubuntu1.2                       amd64        GNU cpio -- a program to manage archives of files
ii  cron                            3.0pl1-124ubuntu2                          amd64        process scheduling daemon
ii  dash                            0.5.7-4ubuntu1                             amd64        POSIX-compliant shell
ii  debconf                         1.5.51ubuntu2                              all          Debian configuration management system
ii  debconf-i18n                    1.5.51ubuntu2                              all          full internationalization support for debconf
ii  debianutils                     4.4                                        amd64        Miscellaneous utilities specific to Debian
ii  dh-python                       1.20140128-1ubuntu8.2                      all          Debian helper tools for packaging Python libraries and applications
ii  diffutils                       1:3.3-1                                    amd64        File comparison utilities
ii  dmsetup                         2:1.02.77-6ubuntu2                         amd64        Linux Kernel Device Mapper userspace library
ii  dpkg                            1.17.5ubuntu5.8                            amd64        Debian package management system
ii  e2fslibs:amd64                  1.42.9-3ubuntu1.3                          amd64        ext2/ext3/ext4 file system libraries
ii  e2fsprogs                       1.42.9-3ubuntu1.3                          amd64        ext2/ext3/ext4 file system utilities
ii  eject                           2.1.5+deb1+cvs20081104-13.1ubuntu0.14.04.1 amd64        ejects CDs and operates CD-Changers under Linux
ii  file                            1:5.14-2ubuntu3.4                          amd64        Determines file type using "magic" numbers
ii  findutils                       4.4.2-7                                    amd64        utilities for finding files--find, xargs
ii  gcc-4.8-base:amd64              4.8.4-2ubuntu1~14.04.4                     amd64        GCC, the GNU Compiler Collection (base package)
ii  gcc-4.9-base:amd64              4.9.3-0ubuntu4                             amd64        GCC, the GNU Compiler Collection (base package)

:amd64某些软件包名称末尾的 ,例如e2fslibs:amd64或 ,是什么意思gcc-4.8-base:amd64?为什么不为所有软件包指定体系结构?

答案1

:amd64名称中包含 的应用程序(即zlib1g:amd64)也可以:i386安装其对应版本而不会丢失任何内容,并且它们可以在系统中共存。名称中未指定 的应用程序(即xwayland)将删除该amd64版本并安装i386已安装的版本(如果已安装该版本),反之亦然。all体系结构列中带有 的应用程序表示该应用程序与两者兼容i386amd64无需安装对应版本。

例子:

$ dpkg -l

ii  xwayland       2:1.19.6-1ub amd64        Xwayland X server
ii  xxd            2:8.0.1453-1 amd64        tool to make (or reverse) a hex d
ii  xz-utils       5.2.2-1.3    amd64        XZ-format compression utilities
ii  xzoom          0.3-24build1 amd64        magnify part of X display, with r
ii  yasm           1.3.0-2build amd64        modular assembler with multiple s
ii  yelp           3.26.0-1ubun amd64        Help browser for GNOME
ii  yelp-xsl       3.20.1-4     all          XSL stylesheets for the yelp help
ii  zenity         3.28.1-1     amd64        Display graphical dialog boxes fr
ii  zenity-common  3.28.1-1     all          Display graphical dialog boxes fr
ii  zip            3.0-11build1 amd64        Archiver for .zip files
ii  zlib1g:amd64   1:1.2.11.dfs amd64        compression library - runtime
ii  zlib1g:i386    1:1.2.11.dfs i386         compression library - runtime
ii  zlib1g-dev:amd 1:1.2.11.dfs amd64        compression library - development

$ sudo apt install xwayland:i386
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  libaudit1:i386 libbz2-1.0:i386 libcap-ng0:i386 libepoxy0:i386
  libfontenc1:i386 libxfont2:i386
The following packages will be REMOVED:
  ubuntu-session xwayland
The following NEW packages will be installed:
  libaudit1:i386 libbz2-1.0:i386 libcap-ng0:i386 libepoxy0:i386
  libfontenc1:i386 libxfont2:i386 xwayland:i386
0 upgraded, 7 newly installed, 2 to remove and 31 not upgraded.
Need to get 1,291 kB of archives.
After this operation, 1,799 kB of additional disk space will be used.
Do you want to continue? [Y/n] ^C


$ sudo apt install zlib1g-dev:i386
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  libc6-dev:i386 linux-libc-dev:i386
Suggested packages:
  glibc-doc:i386
The following NEW packages will be installed:
  libc6-dev:i386 linux-libc-dev:i386 zlib1g-dev:i386
0 upgraded, 3 newly installed, 0 to remove and 31 not upgraded.
Need to get 3,435 kB of archives.
After this operation, 19.8 MB of additional disk space will be used.
Do you want to continue? [Y/n] ^C

希望这可以帮助!

相关内容