Slackware is a Linux distribution developed by Patrick Volkerding initially it was released in 1993. The distribution was based on the Softland Linux system which was one of the first Linux distribution created. Slackware development aims for design stability, simplicity, and most Unix-like system. It is considered to be most suitable for advanced and technically inclined users. Local packages are managed by a set of tools collectively known as pkgtools while slackpkg is used to manage packages over a network or internet. We will see more about managing packages in Slackware Linux in this article.
Slackware Packages
Packages used in Slackware are distributed as compressed tarballs. Generally, these package compressed using gzip, lzma compressions with the file extension .tgz, and .txz later the support for bzip2 and Izma compression was also added which uses the file extension .tbz and .tlz respectively but these are not commonly used. The compressed package includes the original programs as well as scripts that are to be run upon performing an operation like installation or removal of software. The package does
not track or manages dependencies which are viewed as allowing more flexibility and control. Slackware packages can also be build using SlackBuilds.
How to manage a package in Slackware from a local machine
The pkgtool is used to manage a package locally it provides a text-based menu interface. The package is listed on the menu you can choose which package to install and which one to leave. pkgtools provides the following commands to install, upgrade and remove a package-
installpkg package_name(s)
– Will search the package in the current directory or the path you specified with the package name.
upgradepkg package_name(s)
– Upgrade a package from the current directory or path that you specified with the package name. If you pass the --install-new
flag with this command it will work like installpkg
command.
removepkg package_name(s)
– It will remove a package from the system. This command does not require full filename and can operate with only the software name associated with the package.
How to manage a package in Slackware from a remote mirror
The slackpkg program was originally developed by Piter Punk later officially it was included in the main tree in Slackware 12.2. Slackware packages are installed and upgraded using a remote FTP or HTTP mirror. You should set the mirror in /etc/slackpkg/mirrors
before using slackpkg. You can also make a mirror active from the available list by uncommenting it (by deleting # sign). Some commands of slackpkg are given below-
slackpkg check-updates
– The command will check for new updates on the remote mirror.
slackpkg update
– It will download the updates to the Slackware changelog and file list. It should be must be done before downloading updated software.
slackpkg install-new
– Looks for new packages that are added to distribution. It should be run if a new release of software available and the machine is running on a previous version.
slackpkg install package_name(s)
– Looks for matching package name and displays a menu allowing the choice of installation.
slackpkg upgrade-all
-Will display the menu listing all the packages with the newer version. Once you choose and confirm for upgrade the packages will start downloading and upgrading.
slackpkg upgrade package_name(s)
– Upgrade a specific package.
slackpkg clean-system
– Display a menu listing all packages on the local system that are not present on upstream mirrors. It will remove all the packages that don’t belong to a standard Slackware installation like a third party software.
slackpkg remove package_name(s)
– It will search and display a menu for the choice of removal of the given package.
slackpkg reinstall package_name(s)
– Reinstall the given package. It is useful if any installed package gets corrupted.
slackpkg search package_name(s)
– It will search for the matching package and display them with the installation status.
slackpkg file-search filename
-Searches for the specified file if matched it will be presented along with the package containing that file.
slackpkg info package_name(s)
– Will display the standard information about the given package
slackpkg blacklist package_name(s)
– Will add the given package to a blacklist
which is located in /etc/slackpkg/blacklist
. No operation like installation, up-gradation, or removal can be performed by the slackpkg.
What are SlackBuild Scripts
SlackBuild scripts are the shell scripts that automate the process of configuring, compiling, and creating a Slackware package from the source archives. Slackbuild.org is a community managed project which offers Slackbuild scripts for a growing volume of third party software. These scripts emphasize integrity and proper operation. The local compilation also verifies the package for compatibility with your machine. If you would like to explore more about building scripts then you should visit SlackBuild Scripts
What is sbopkg
sbopkg is a program like pkgtool, which facilitates the management of SlackBuilds it operates similarly to slackpkg but works with the slackBuilds.org repository. Like a pkgtool, It also offers a text-based menu interface. It also provides a sync option which ensures that you are working with the latest version of all SlackBuilds.
I hope that it will give a basic understanding for managing package in Slackware Linux distribution if still, you have a query you can write us in the comments below.