Slapt-get

From SlackWiki
Jump to navigation Jump to search

slapt-get is an APT-like system for Slackware package management.

It tries to emulate the features of Debian's apt-get as closely as possible.

Features

  • uses native Slackware tools (installpkg, upgradepkg, and removepkg)
  • supports multiple package sources (including http://linuxpackages.net)
  • cache data concerning packages and updates from package sources
  • supports sources from ftp, ftps, http, https, file:/// and more (libcurl)
  • resumes broken downloads and will verify package integrity with MD5 checksum
  • show packages that are available (from cached data) and installed
  • search package listing using POSIX and extended regular expressions by package name, location, and description
  • retrieve, install, and remove packages by name or by specific version
  • retrieve and apply updates
  • upgrade from one Slackware release to another in a few simple steps - see Upgrade_Using_Slapt-get
  • show description of packages, including mirror location, version, size, dependencies (where available, see FAQ), conflicts (where available, see FAQ), suggestions (where available, see FAQ), description, and installation status
  • exclude (hold) packages from upgrades, by name or by regular expression
  • transaction engine for install, remove, and upgrades, reporting concise information on what is to be done, ensuring each step happens correctly
  • "compare package version" algorithm to prevent downgrades
  • recursive dependency resolution using slack-required meta-data (see FAQ) supporting hard, soft, and conditional dependencies
  • package conflict resolution using slack-conflicts meta-data (see FAQ)
  • package suggestion support for complimentary packages (see FAQ)
  • Package data download robustness, only writing changes if all sources download successfully as well as only downloading those sources that have changed since the last download
  • i18n support via GNU gettext with over 20 language translations
  • extremely fast and easy to script with

Dependencies

slapt-get does not provide dependency resolution for packages included within the Slackware distribution. It does, however, provide a framework for dependency resolution in Slackware compatible packages similar in fashion to the hand-tuned method Advanced Packaging Tool|APT utilizes. Several package sources and Slackware based distributions take advantage of this functionality.

Adding dependency information requires no modification to the packages themselves. Rather, the package listing file, PACKAGES.TXT, is used to specify these relationships. This file is provided by Patrick Volkerding and is similar to the Packages.gz file in use by Debian. Several scripts are available to generate the PACKAGES.TXT file from a group of packages (See FAQ #17). The file format used by Patrick Volkerding is extended by adding a few extra lines per package. slapt-get then parses this file during source downloads. Typically, third party packages store the dependency information within the package itself for later extraction into the PACKAGES.TXT (See FAQ #19). The inclusion of this information within the Slackware package format does not inhibit the ability for Slackware pkgtools to install these packages. This information is silently ignored and discarded after the package is installed.

Other methods exist for adding dependency information for official Slackware packages without altering the packages themselves.

Package Sources

slapt-get works with official Slackware mirrors and third party package repositories. slapt-get looks for support files, PACKAGES.TXT and CHECKSUMS.md5, in the repository for package information. These files provide package names, versions, sizes (both compressed and uncompressed), checksums, as well as a package description. These files can be extended, as discussed in the previous section, to add dependency listings, conflict information, and package suggestions. These files can also proxy for other remote sources by specifying a MIRROR declaration for each package.

libslapt

slapt-get exports a C library that is used by gslapt to provide similar functionality through a GTK+ frontend.

Distributions

Besides Slackware, slapt-get may be used with or included by the following distributions:

* Vector Linux
* Mutagenix
* SLAX
* Slamd64
* Freerock GNOME
* GWARE GNOME
* SLAMPP
* OpenLab GNU/Linux
* Open Community Slackware Install DVD
* Floyd GNU/Linux
* STX GNU/Linux
* Nonux GNU/Linux
* Wolvix LiveCD
* College Linux
* Zenwalk Linux
* Truva Linux
* SMS(Superb Mini Server)

Examples

 $ slapt-get --update
 Retrieving package data http://www.slackware.at/data/slackware-10.0/ ...Done
 Retrieving patch list http://www.slackware.at/data/slackware-10.0/ ...Done
 Retrieving checksum list http://www.slackware.at/data/slackware-10.0/ ...Done
 Reading Package Lists...Done
 Retrieving package data http://software.jaos.org/slackpacks/10.0/ ...Cached
 Retrieving patch list http://software.jaos.org/slackpacks/10.0/ ...Cached
 Retrieving checksum list http://software.jaos.org/slackpacks/10.0/ ...Cached
 Reading Package Lists...Done
 $ slapt-get --upgrade
 Reading Package Lists... Done
 The following packages have been EXCLUDED:
   devs kernel-headers
 The following packages will be upgraded:
   binutils bash bin bind cdrtools bzip2 kbd cups cxxlibs e2fsprogs etc gawk gcc gdb inetd infozip less links
   logrotate lynx man man-pages openssh openssl openssl-solibs pidentd pkgtools procps sed shadow slocate
   sysklogd sysvinit tar tcpip util-linux vim wget zlib
 39 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.
 Need to get 36710K of archives.
 After unpacking 17880K of additional disk space will be used.
 Do you want to continue? [y/N]
 $ slapt-get --show slapt-get
 Package Name: slapt-get
 Package Mirror: http://software.jaos.org/slackpacks/10.0/
 Package Location: .
 Package Version: 0.9.9f-i386-1
 Package Size: 147 K
 Package Installed Size: 530 K
 Package Required:   curl >= 7.12.0-i486-1,glibc-solibs >= 2.3.2-i486-7,binutils,openssl >= 0.9.7d-i486-1,pkgtools,zlib
 Package Conflicts:
 Package Suggests:
 Package MD5 Sum:  cb4b44cbb4efee4e993109231b107828
 Package Description:
 slapt-get: slapt-get (APT like system for Slackware)
 slapt-get: slapt-get is an APT like system for Slackware package management.
 slapt-get:
 slapt-get:  * See /usr/doc/slapt-get-0.9.9f/ for complete documentation.
 slapt-get:  * You will also want to customize /etc/slapt-get/slapt-getrc,
 slapt-get:    using a local mirror.  www.slackware.com may be very busy.
 slapt-get:  * Support:
 slapt-get:    http://software.jaos.org/cgi-bin/mailman/listinfo/slapt-get-user
 slapt-get:  * Please translate
 slapt-get:    http://software.jaos.org/BUILD/slapt-get/po/slapt-get.pot
 slapt-get:    then send to slapt-get-devel@software.jaos.org
 slapt-get:
 Package Installed: yes

External links