guix-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Overlays, custom package modules


From: Ludovic Courtès
Subject: Overlays, custom package modules
Date: Wed, 24 Sep 2014 14:14:45 +0200
User-agent: Gnus/5.130011 (Ma Gnus v0.11) Emacs/24.3 (gnu/linux)

"Thompson, David" <address@hidden> skribis:

> Since packages are Scheme expressions, you can simpley create a new
> package object that inherits from the package you want to modify.
>
> Untested code below:
>
>     (use-modules (guix packages) (gnu packages emacs))
>
>     (package (inherit emacs)  ...)
>
> To install, I believe you need to use something like:
>
>     guix package -e '(load "my-custom-emacs.scm")'

This works OK but is inconvenient because that makes the user’s
modification second-class (and doesn’t work well with multiple-output
packages since -e ignores all but the first output.)

Mark H Weaver <address@hidden> skribis:

> IMO, the best approach is to clone the Guix git repo, create your own
> private branch with your preferred modifications, and periodically merge
> or rebase with Guix upstream.

This approach doesn’t have the above drawbacks but is inconvenient.

I’ve finally bit the bullet.  Now it’s possible for users to write their
own package modules and then either run:

  guix package/build/... -L path/to/modules my-very-own-package ...

or:

  export GUIX_PACKAGE_PATH=/path/to/modules
  guix package -i my-very-own-package ...

The latter works with all the UIs, including the Emacs one.  So I think
it’s going to be pretty convenient (I’ve needed something like that a
couple of times, for local modifications of existing packages.)

Feedback welcome!

Thanks,
Ludo’.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]