[pacman-dev] Alternatives system brainstorm

Giancarlo Razzolini grazzolini at archlinux.org
Thu Oct 17 13:32:49 UTC 2019

Em outubro 17, 2019 7:53 Allan McRae escreveu:
> In Debian & Fedora land, these additional files are called slaves.
> Note that both those distros use the "same" tool to manage these things.
>  In addition, each alternative is given a priority.   So if (e.g.) two
> python2 and python3 are installed at the same time, it would select the
> one with the higher priority.  Fedora also has "ghost" files (not sure
> about Debian).  I.e. the python3 package contains a ghost
> /usr/bin/python, so searching file databases gives a match.

Priorities are a nice thing to have. I think I've reported this on the bugtracker
(or there was a bug report I've commented in). The example is mkinitcpio/dracut.

The only reason mkinitcpio is preferred over dracut right now is because it is on
the core repo and dracut is in the extra repo. Being able to define priorities
will benefit not just the alternatives system.

Then again, how will repo priority work? Will it be completely removed?

> Now how does that inform our potential implementation?  Mostly, I don't
> like that they set up all the alternatives in the post install with one
> long command passed to their tool.  I'd prefer we had a file with a list
> of needed symlinks so this could happen automatically.

I agree, we shouldn't do this on post install. Ideally pacman itself should
handle all the filesystem operations.

> Could also include an optional priority statement?  Or should that be
> captured in the PKGBUILD?

I think the priorities should be captured at the PKGBUILD itself. It would
also make it easier for pacman to know what they are.

Giancarlo Razzolini
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://lists.archlinux.org/pipermail/pacman-dev/attachments/20191017/c11601e8/attachment.sig>

More information about the pacman-dev mailing list