Question about 'provides' and emacs packaging
Jon Turney
jon.turney@dronecode.org.uk
Wed Oct 6 20:22:45 GMT 2021
On 06/10/2021 17:23, Jon Turney wrote:
> On 06/10/2021 13:01, Ken Brown via Cygwin-apps wrote:
>>
>> This seems to work, with one caveat. Suppose package P requires
>> feature f, and packages Q, R, S,... provide f. If the user selects P
>> and one or more of Q, R, S,..., setup is happy. But if the user
>> simply selects P, then setup/libsolv will choose among Q, R, S,... the
>> one whose name is alphabetically first. In the emacs case, this would
>> be emacs-lucid, which is a stupid default. The default ought to be
>> emacs-nox. So I can make it work if I call that package emacs-basic
>> instead of emacs-nox.
>
> Yeah, I think what's wanted here is for the solver to output a problem
> with the choices, rather than picking one. I'm not sure how to get it
> to do that.
>
> (Ofc, then we need some UI for picking problem solutions, rather than
> just always using the default)
Thinking about this some more, that's probably not how it wants to work,
since just installing emacs-common would then require user interaction
to solve the problem, rather than just installing emacs-nox as well...
> (and I'm not sure how we'd encode "emacs-basic" should be the default
> provider of "emacs-bin" as the input into the solver; presumably there'd
> by some scheme with weights attached to provide names to set the order
> rather than alphabetic)
So all that's left is to fix that.
This is discussed somewhat in [1], and it seems that having emacs-common
suggest: or weak-dep: on emacs-nox would cause that to be the preferred
provide:r by the solver (in the absence of other provide:ing packages
being selected or installed)
So I guess we'd need to add something like that to setup.ini and feed
that data into the solver as well.
[1] https://github.com/openSUSE/libsolv/issues/66
More information about the Cygwin-apps
mailing list