Slackware Package Management
Slackware Philosophy
It's in the name: Slackware. New kernel releases are often years in the making, and this is by design: stability and simplicity are fundamental to Slackware. These attributes are harder to achieve with a rolling release cycle. Having started in 1993, it's the oldest still maintained linux distribution, so they are doing something right!
The Slackware approach to package management is just as odd as the release cycle. Distributions have their dedicated package managers: Debian-based distros have apt, Red Hat has yum, and Arch has pacman, to name a few.
Slackware has slackpkg and pkgtool, but they don't resemble package managers as one knows them from other distributions. For one, slackpkg only manages packages present on the machine, for instance those that came with the installation. It's good for upgrading and removing unwanted packages.
pkgtool is similar, but it offers a more GUI-like experience in the terminal. However, neither of them do what, for instance, apt does. With apt, I can search the Linux repositories for a package that is neither installed nor on my machine, and I can download and install it right there:
sudo apt-cache search <package-name>
sudo apt install <package-name>
Further, all the necessary dependencies will be managed with those commands. Slackware has a more old school approach. You find the package you want at slackbuilds.org, download both the source file (.deb) and the tarball file (.tar.gz), untar the tarball and mv the source file into the resulting directory, edit the Slackbuild file (i.e. version) and make sure it's executable with chmod, run the SlackBuild file with ./<file>.SlackBuild, and find the resulting output in /tmp, where you run installpkg <output>. Whew! Quite a process. What's more, you may have to do these steps again to make sure the dependencies are installed.
The reasoning goes that every install ought to be completely deliberate. An administrator should always be making a conscious choice about what goes on their machine. I have to say, I do find this philosophy compelling.
Install Process
Everything here is outlined in slackbuilds.org - How to Install Packages, but I'll paraphrase it as well.
-
Navigate to slackbuilds.org and search for the package you require.
-
Select the package. For example, nginx.

-
Download both the the Source Download nginx-1.26.3.tar.gz and the SlackBuild nginx.tar.gz.

-
Untar the SlackBuild directory, and a directory appears.
tar -xvf nginx.tar.gz -
Do an integrity check on the Source File. Then, move it into the SlackBuild directory.
md5sum nginx-1.26.3.tar.gz mv nginx-1.26.3.tar.gz nginx/ -
Enter the SlackBuild directory. Edit the SlackBuild file if necessary, modifying the version number etc.
cd nginx vim nginx.SlackBuild -
Make the SlackBuild file executable.
chmod 700 nginx.SlackBuild -
Run the SlackBuild script with root authority.
sudo -i ./nginx.slackbuild -
Navigate to the resulting output file in
/tmpand install it.cd /tmp installpkg nginx-1.26.3-x86_64-1_SBo.tgz -
Done!
Uninstall Process
This process is much more straightforward.
- In a terminal, launch pkgtool.
sudo pkgtool - Navigate to remove and type the first letter of the package to get a headstart. Scroll from there.
- When found, hit space to select it, then enter. Note: if you cannot find the package, it is likely you did not install it with root authority
suto begin with, which means it is not listed in/var/packageseven though it is installed. - Done!





