Manage Debian packages with the Smart Package Manager
All the Extras
The Smart Package Manager makes everyday tasks of handling RPM and DEB packages simple but has a full set of controls for experts.
Package managers simplify the often complex processes involved in managing software on a Linux system. Some package managers operate at the command line, others use a graphical interface, and still others are web-based tools; however, most package managers are designed to work with a specific package format. That means if you migrate from a system that uses the RPM format (e.g., Fedora or RHEL) to a system that uses DEB packages (e.g., Debian or Ubuntu), you need to get used to a whole different collection of package tools … unless you get Smart.
Smart Package Manager (SmartPM) is an innovative tool that has gained fame as a package management system that lets you manage different package formats through a single interface. According to the project website, SmartPM supports both Red Hat's RPM and Debian's DEB formats, as well as the Mandriva/Mageia URPMI format. Additionally, it manages tarballs for Slackware.
This versatility means you only need to learn one package manager to work on nearly any Linux system. (Keep in mind, however, that SmartPM is not intended to let users mix and match random formats on a single system. See the box titled "Not a Magic Bridge.")
Not a Magic Bridge
Although SmartPM supports several package formats, be aware that a multipackage system presents some limitations. The Smart Package Manager project is quick to point out that it is "not a magical bridge between every distribution in the planet." They add, "Instead, this is software offering better package management for these distributions when working with their native packages. Using multiple packaging systems at the same time (like rpm and dpkg) is possible but would require packages from those systems to follow the same packaging guidelines. As this is not the case at the moment, mixing package systems is not recommended" [1].
One look at the SmartPM documentation makes it clear that this vaunted package neutrality is only part of what makes SmartPM so smart. Another important feature is smart transactions. According to the SmartPM project, "While other software tries to find a possible solution to satisfy the relations involved in some user-requested operation, and sometimes even fails to do so, SmartPM goes beyond it. In the kernel of Smart Package Manager lives an algorithm that will not only find a solution, if one is available, but will find the best solution. This is done by quickly weighting every possible solution with a pluggable policy, which redefines the term 'best' depending on the operation goal (install, remove, upgrade, etc.)" [2]. This smart transaction capability means that SmartPM might not choose the latest version of a package if it determines an older version will provide a better overall result for the system.
SmartPM also lets you assign priorities to packages or package sources, so you can give preferred formats an advantage. In SmartPM, external packages are accessed through channels. Each channel supports a specific package type (see Table 1), and you can assign priorities by channel or package name.
Table 1
SmartPM Channels
APT-DEB Repository |
APT-RPM Repository |
DPKG Installed Packages |
Mirror Information |
Red Carpet Channel |
RPM Directory |
RPM Header List |
RPM Metadata (YUM) |
RPM Installed Packages |
Slackware Repository |
Slackware Installed Packages |
URPMI Repository |
In addition to providing a universal GUI for managing Linux packages, SmartPM also has a powerful command-line interface for full control of the package management environment. In this article, I focus on using SmartPM with DEB-based distributions.
Installation
The program is available from the project website [1]. Alternatively, you can enter
sudo apt-get update sudo apt-get install smartpm
to install the python-smartpm
, smartpm-core
, and smartpm
packages.
Various operating modes are enabled when launching the program. The graphical user interface (GUI) can be accessed with the use of the --gui
option, whereas the interactive application for the console is launched by setting the --shell
flag.
This interface is similar to Apt and Aptitude. Adding the --gui
option to the call tells SmartPM to change to graphics mode before running.
Graphical Mode
Because you will be installing and changing base packages, you will need administrative privileges, so start SmartPM in GUI mode with:
sudo smart --gui
Otherwise, you will get the error Unable to create channel directory.
Interface
The graphical interface includes a menu bar and a row of buttons. The overview includes the software categories, information about the packages, and matching details. At the bottom of the window you will see the status bar with the total number of available and installed packages (Figure 1).
The File menu has options to upgrade channels and rebuild the cache. The File | Update Channels item updates the lists of package information. An individual update is possible by choosing File | Update Selected Channels (Figure 2). So far, only SmartPM offers this function, although it has been on the wishlist of extensions [3] for Apt and Aptitude for a long time.
The Edit menu lets you check packages for unresolved dependencies, manage repositories, select packages, and change priorities. Edit | Priorities lets you edit priorities you've already set up. Right-clicking a program and choosing Priority allows you to specify how the program evaluates sources. Figure 3 shows this for the gnome-sudoku package.
The Views menu lets you filter the display in the package selection list; for example, you can filter for non-upgradable, unlocked, or installed packages. Selecting Views | Tree Style lets you toggle between sorting by categories, package sources, or package groups.
The Help menu takes you to information about the program version and an overview of the icons used by SmartPM to indicate the status of a package. Important menu items are also implemented as buttons, such as correcting recent changes and updating all installed packages.
The text you enter in the search box on the right acts as a filter for the package list. Right-clicking the magnifying glass reveals two choices: Automatic and Description. Automatic searches file names for the text entered, whereas Description searches the package descriptions for the entered text. Figure 1 shows entries in which the smartpm
string occurs in the package name.
After selecting a package from the list, SmartPM shows you more details at the bottom of the window. In addition to general information, such as the status, priority, group, size, package source, and URL, you will find the description and the list of files that the package includes (Content).
The Changelog tab provides information on development, and you can see other packages on which the program depends or that are recommended for the program (Relations).
Buy this article as PDF
(incl. VAT)
Buy Linux Magazine
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters
Support Our Work
Linux Magazine content is made possible with support from readers like you. Please consider contributing when you’ve found an article to be beneficial.
News
-
Red Hat Enterprise Linux 9.5 Released
Notify your friends, loved ones, and colleagues that the latest version of RHEL is available with plenty of enhancements.
-
Linux Sees Massive Performance Increase from a Single Line of Code
With one line of code, Intel was able to increase the performance of the Linux kernel by 4,000 percent.
-
Fedora KDE Approved as an Official Spin
If you prefer the Plasma desktop environment and the Fedora distribution, you're in luck because there's now an official spin that is listed on the same level as the Fedora Workstation edition.
-
New Steam Client Ups the Ante for Linux
The latest release from Steam has some pretty cool tricks up its sleeve.
-
Gnome OS Transitioning Toward a General-Purpose Distro
If you're looking for the perfectly vanilla take on the Gnome desktop, Gnome OS might be for you.
-
Fedora 41 Released with New Features
If you're a Fedora fan or just looking for a Linux distribution to help you migrate from Windows, Fedora 41 might be just the ticket.
-
AlmaLinux OS Kitten 10 Gives Power Users a Sneak Preview
If you're looking to kick the tires of AlmaLinux's upstream version, the developers have a purrfect solution.
-
Gnome 47.1 Released with a Few Fixes
The latest release of the Gnome desktop is all about fixing a few nagging issues and not about bringing new features into the mix.
-
System76 Unveils an Ampere-Powered Thelio Desktop
If you're looking for a new desktop system for developing autonomous driving and software-defined vehicle solutions. System76 has you covered.
-
VirtualBox 7.1.4 Includes Initial Support for Linux kernel 6.12
The latest version of VirtualBox has arrived and it not only adds initial support for kernel 6.12 but another feature that will make using the virtual machine tool much easier.