确定依赖关系并从目录安装

确定依赖关系并从目录安装

我有一个包含 .deb 格式的所有依赖项的目录。

但它们有很多。我只需要那些我需要的gimp。

biggenius@hacbook:~/Desktop/rocks/packages$ dpkg-deb -I gimp_2.6.12-1ubuntu1_i386.deb 
 new debian package, version 2.0.
 size 4722192 bytes: control archive= 7927 bytes.
    1894 bytes,    27 lines      control              
   15660 bytes,   219 lines      md5sums              
     353 bytes,    14 lines   *  postinst             #!/bin/sh
     160 bytes,     5 lines   *  postrm               #!/bin/sh
     331 bytes,    11 lines   *  preinst              #!/bin/sh
     245 bytes,    14 lines   *  prerm                #!/bin/sh
 Package: gimp
 Version: 2.6.12-1ubuntu1
 Architecture: i386
 Maintainer: Ubuntu Desktop Team <[email protected]>
 Installed-Size: 12814
 Depends: libgimp2.0 (>= 2.6.12), libgimp2.0 (<= 2.6.12-z), gimp-data (>= 2.6.12), gimp-data (<= 2.6.12-z), python-gtk2 (>= 2.8.0), libaa1 (>= 1.4p5), libbabl-0.0-0, libc6 (>= 2.15), libcairo2 (>= 1.2.4), libdbus-1-3 (>= 1.0.2), libdbus-glib-1-2 (>= 0.88), libexif12, libfontconfig1 (>= 2.8.0), libfreetype6 (>= 2.2.1), libgdk-pixbuf2.0-0 (>= 2.22.0), libgegl-0.0-0 (>= 0.0.22), libglib2.0-0 (>= 2.31.2), libgtk2.0-0 (>= 2.24.0), libjpeg8 (>= 8c), liblcms1 (>= 1.15-1), libmng1 (>= 1.0.10), libpango1.0-0 (>= 1.18.0), libpng12-0 (>= 1.2.13-4), libpoppler-glib8 (>= 0.18), librsvg2-2 (>= 2.14.4), libtiff4, libwebkitgtk-1.0-0 (>= 1.3.10), libwmf0.2-7 (>= 0.2.8.4), libx11-6, libxext6, libxfixes3, libxmu6, libxpm4, zlib1g (>= 1:1.1.4), python (>= 2.7.1-0ubuntu2), python2.7
 Recommends: ghostscript
 Suggests: gimp-help-en | gimp-help, gimp-data-extras, gvfs-backends, libasound2
 Provides: gimp-helpbrowser, gimp-python
 Section: graphics
 Priority: optional
 Homepage: http://www.gimp.org
 Description: The GNU Image Manipulation Program
  GIMP is an advanced picture editor. You can use it to edit, enhance,
  and retouch photos and scans, create drawings, and make your own
  images. Lots of tools are available; you can sharpen and resize photos,
  and remove dust and red-eyes, for example.
  .
  It has a large collection of professional-level editing tools and
  filters, similar to the ones you might find in PhotoShop. Numerous
  fine-control settings and features like layers, paths, masks, and
  scripting give you total control over your images.
  .
  Many image file formats are supported, including JPEG, PhotoShop
  (.psd), and Paint Shop Pro (.psp) files. It can also be used to scan
  and print photos.
 Original-Maintainer: Ari Pollak <[email protected]>

我怎样才能只安装目录中的这些礼仪?

在此输入图像描述

答案1

您可以aptitude -s install gimp让 aptitude 为您解决依赖关系,然后使用该列表来找出您需要安装的软件包。

您还可以使用 来设置包含所有 deb 文件的本地存储库reprepro,暂时将您的存储库/etc/apt/sources.list作为唯一的存储库,然后简单地aptitude install gimp

然而,最明智的方法是aptitude install gimp……或者您没有互联网连接?

答案2

您必须根据包创建一个存储库。你可以轻松地做到这一点dpkg-扫描软件包,例如:

dpkg-scanpackages . /dev/null | gzip > Packages.gz
echo "deb file:/path/to/directory ./" > /etc/apt/sources.list.d/local-mirror.list
apt-get update

这将允许您使用本地镜像中的文件。有关更详细的示例,请查看Ubuntu 个人存储库手动的。

相关内容