* practicality of custom config
@ 2019-12-30 23:29 Michael Zucchi
2019-12-31 9:50 ` Pierre Neidhardt
2020-01-01 9:34 ` Ricardo Wurmus
0 siblings, 2 replies; 5+ messages in thread
From: Michael Zucchi @ 2019-12-30 23:29 UTC (permalink / raw)
To: help-guix
Morning,
From the manual:
"It is also /customizable/: users can /derive/ specialized package
definitions from existing ones, including from the command line (see
Package Transformation Options
<https://guix.gnu.org/manual/en/html_node/Package-Transformation-Options.html#Package-Transformation-Options>).
"
But in reality how practical would it be to create a system which for
example doesn't include pulseaudio? I'm using slackware 64and it
provides this option so ideally I don't want guix dragging it back in.
Looking through the package definitions it looks like considerable
effort: either editing or using code to edit (aka deriving) every
package that uses it. For deriving changes it would require internal
knowledge of the source package definition and would thus be rather
fragile and difficult to maintain.
This is one example but there may be other system-wide options that one
might want to customise in a similar way to services, is there a
mechanism for this?
Z
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: practicality of custom config
2019-12-30 23:29 practicality of custom config Michael Zucchi
@ 2019-12-31 9:50 ` Pierre Neidhardt
2019-12-31 23:23 ` Michael Zucchi
2020-01-01 9:34 ` Ricardo Wurmus
1 sibling, 1 reply; 5+ messages in thread
From: Pierre Neidhardt @ 2019-12-31 9:50 UTC (permalink / raw)
To: Michael Zucchi, help-guix
[-- Attachment #1: Type: text/plain, Size: 444 bytes --]
Hi Michael,
Indeed, in practice it's not easy to tell Guix "build a system without
sound" or things like that.
An option would be to implement a feature à-la USE flags (as in Portage
on Gentoo).
This was discussed previously here:
https://lists.gnu.org/archive/html/guix-devel/2019-05/msg00285.html
I'm planning to work on it in the coming weeks. Feedback welcome!
Stay tuned!
--
Pierre Neidhardt
https://ambrevar.xyz/
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: practicality of custom config
2019-12-30 23:29 practicality of custom config Michael Zucchi
2019-12-31 9:50 ` Pierre Neidhardt
@ 2020-01-01 9:34 ` Ricardo Wurmus
1 sibling, 0 replies; 5+ messages in thread
From: Ricardo Wurmus @ 2020-01-01 9:34 UTC (permalink / raw)
To: Michael Zucchi; +Cc: help-guix
Hi,
> From the manual:
>
> "It is also /customizable/: users can /derive/ specialized package
> definitions from existing ones, including from the command line (see
> Package Transformation Options
> <https://guix.gnu.org/manual/en/html_node/Package-Transformation-Options.html#Package-Transformation-Options>).
> "
>
>
> But in reality how practical would it be to create a system which for
> example doesn't include pulseaudio? I'm using slackware 64and it
> provides this option so ideally I don't want guix dragging it back in.
“pulseaudio” is a good example because many packages build with its
headers without linking to it. What’s the right thing to do here when
you want it removed? In those cases you cannot just remove “pulseaudio”
from the inputs, which is something that the package transformations
mentioned in the manual can easily do.
> Looking through the package definitions it looks like considerable
> effort: either editing or using code to edit (aka deriving) every
> package that uses it.
The package transformations act on the whole package graph recursively,
so it would be enough to write a simple transformer once and apply it to
all leaf nodes that you reference in the list of system packages.
Of course this would mean compiling packages anew, because we don’t
offer binary substitutes for arbitrary package variants.
> This is one example but there may be other system-wide options that
> one might want to customise in a similar way to services, is there a
> mechanism for this?
Package transformers are the generic mechanism to use here, but it is
true that a feature is missing to apply a package transformer on the
*whole* system (and not just the “packages” field of a system
configuration).
Doing something smarter or context aware however cannot easily be done
automatically (as in the case where pulseaudio is needed at build time
merely for its headers but doesn’t result in linking).
--
Ricardo
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2020-01-01 14:54 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-12-30 23:29 practicality of custom config Michael Zucchi
2019-12-31 9:50 ` Pierre Neidhardt
2019-12-31 23:23 ` Michael Zucchi
2020-01-01 14:54 ` Pierre Neidhardt
2020-01-01 9:34 ` Ricardo Wurmus
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).