[2024-feb-29] Sad news: Eric Layton aka Nocturnal Slacker aka vtel57 passed away on Feb 26th, shortly after hospitalization. He was one of our Wiki's most prominent admins. He will be missed.

Welcome to the Slackware Documentation Project

Ceci est une ancienne révision du document !


slackpkg

Slackpkg est un outil automatisé dédié à la gestion des paquets locaux et qui permet d'installer de nouveaux paquets via le réseau. Aujourd'hui, slackpkg fait partie intégrante de la Slackware, mais s'il n'est pas installé, vous pouvez télécharger la dernière version à partir de SourceForge et l'installer avec installpkg.

Configuration

Avant d'utiliser slackpkg, il est nécessaire d'avoir une liste actualisée des paquets avec indication de leurs versions, liste que slackpkg lui-même peut télécharger automatiquement dès lors qu'un site miroir (et un seul) a été défini. Pour sélectionner un miroir, dé-commentez simplement la ligne contenant une URL dans le fichier /etc/slackpkg/mirrors. Notez que les liens sont classés par versions de la Slackware, assurez-vous que le lien sélectionné concerne bien la version installée sur votre système.

Puis exécutez:

darkstar~# slackpkg update gpg

L'étape suivante consiste à mettre à jour la liste de paquets par la commande:

darkstar~# slackpkg update

S'il n'y a pas eu de changement dans la liste, il vous sera demandé:

No changes in ChangeLog.txt between your last update and now.
Do you really want to download all other files (y/N)?

Sinon slackpkg va télécharger et copier la liste la plus récente des informations sur les paquets, et l'utilisera.

Mise en liste noire

slackpackage se conformera au contenu du fichier /etc/slackpkg/blacklist. Par exemple, les motifs suivants éviteront tout paquet installé depuis le dépôt SBo ainsi que depuis le dépôt d'alienBob :

[0-9]+_SBo
[0-9]+alien

Utilisation

L'emploi de motifs permet à Slackpkg de chercher, installer ou enlever des paquets. Slackpkg trouve tout paquet offrant une correspondance entre son nom complet lu dans la liste des paquets et le motif utilisé.

Recherche

La recherche d'un paquet vous indiquera son nom complet, sa version et s'il est installé ou non.

darkstar~# slackpkg search mc

Looking for mc in package list. Please wait... DONE

The list below shows all packages with name matching "mc".

[ installed ] - mcelog-1.0pre3-i486-1
[uninstalled] - pcmciautils-017-i486-1
[ installed ] - mc-4.8.1.3-i486-1
[ installed ] - libmcrypt-2.5.8-i486-1

recherche de fichier

Recherche d'un fichier particulier afin d'installer ou enlever ultérieurement le(s) paquet(s) contenant ce fichier:

darkstar~# slackpkg file-search sshd

Looking for sshd in package list. Please wait... DONE

The list below shows the packages that contains "sshd" file.

[ installed ] - openssh-6.0p1-i486-2

info

Pour obtenir les informations concernant un paquet : slackpkg Info nom_du_paquet affichera les informations sur ce paquet à l'écran.

installation

Pour installer un paquet, employez slackpkg install un_motif. Si le motif correspond à un ou des paquet(s) disponible(s), une fenêtre de dialogue permettra à l'utilisateur de choisir quel(s) paquet(s) installer.
Pour installer intégralement un groupe logiciel, vous pouvez saisir: slackpkg install nom_de_groupe, par exemple slackpkg install kde installera tous les éléments de kde (mais rien de kdei).

remove

To remove a package use slackpkg remove pattern. If a package was found a dialog window will present any packages that matches to the pattern and the user can un/check which packages to remove.

upgrade

If an update is available for a certain package, it can be updated with slackpkg upgrade packagename.

reinstall

This command can be used if a package became broken and needs to be re-installed.

blacklist

This can be used to add a certain package to the blacklist. Blacklisted packages are being disregarded by slackpkg.

generate-template

If you need to re-install the entire system or install a new PC that will have similar installed packages, a user can generate a template to be installed later.

install-template

This command is used to have all the packages in a template be installed on this PC.

install-new

Running slackpkg with this argument generates a list of packages that were introduces to the Slackware recently, for example new dependencies to a package. It is advisable to run this command before updating the system if you synchronize to slackware-current.

upgrade-all

Running slackpkg with this argument will generate a list of all packages that can be upgraded with a new version. The user can un/check which packages to upgrade from a dialog list.

clean-system

Running slackpkg with this argument will generate a list of all packages that are obsolete and can be safely removed from the system. Note that non-official packages will be listed here unless blacklisted.

new-config

During installation a new configuration file might be installed and overwrite your configurations. To prevent that the file will receive a “.new” prefix and after installation slackpkg will inform the user about the existence of these files. Running slackpkg with this argument will search for the existence of these files and will ask the user for instructions.

check-updates

Running slackpkg with this argument will produce a clean printout if there are any available updates.

Full system upgrade

To perform a full system upgrade, please follow these steps (as root user):

slackpkg update
slackpkg install-new
slackpkg upgrade-all
slackpkg clean-system

It is always recommended to read the latest ChangeLogs and UPGRADING.TXT (found on the HTTP/FTP mirrors for each version) before doing any major system upgrades.

Pay attention to changed configuration files. Update them either by merging your customizations from the older configuration files (Slackpkg can optionally step through every changed configuration file and allow you to resolve the changes) or manually editing the new files after allowing Slackpkg to overwrite the old configuration files. You decide which way works best for you.

Sources

 fr:slackware:slackpkg ()
Cette traduction est plus ancienne que la page originale et est peut-être dépassée. Voir ce qui a changé.