[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
134/136: profiles: Add a gdk-pixbuf-loaders-cache-file hook.
From: |
guix-commits |
Subject: |
134/136: profiles: Add a gdk-pixbuf-loaders-cache-file hook. |
Date: |
Sun, 17 Oct 2021 05:16:28 -0400 (EDT) |
apteryx pushed a commit to branch core-updates-frozen-batched-changes
in repository guix.
commit 402c5dee9f95508ea6d697ab518a42f4392eb8c2
Author: Maxim Cournoyer <maxim.cournoyer@gmail.com>
AuthorDate: Sat Oct 2 21:28:24 2021 -0400
profiles: Add a gdk-pixbuf-loaders-cache-file hook.
This paves the way toward properly fixing https://issues.guix.gnu.org/50957.
* guix/profiles.scm (gdk-pixbuf-loaders-cache-file): Add procedure...
(%default-profile-hooks): ... and register it as a profile hook.
---
guix/profiles.scm | 30 +++++++++++++++++++++++++++++-
1 file changed, 29 insertions(+), 1 deletion(-)
diff --git a/guix/profiles.scm b/guix/profiles.scm
index 9494684..83f589c 100644
--- a/guix/profiles.scm
+++ b/guix/profiles.scm
@@ -7,7 +7,7 @@
;;; Copyright © 2016, 2018, 2019, 2021 Ricardo Wurmus <rekado@elephly.net>
;;; Copyright © 2016 Chris Marusich <cmmarusich@gmail.com>
;;; Copyright © 2017 Huang Ying <huang.ying.caritas@gmail.com>
-;;; Copyright © 2017 Maxim Cournoyer <maxim.cournoyer@gmail.com>
+;;; Copyright © 2017, 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com>
;;; Copyright © 2019 Kyle Meyer <kyle@kyleam.com>
;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com>
;;; Copyright © 2020 Danny Milosavljevic <dannym@scratchpost.org>
@@ -1161,6 +1161,33 @@ MANIFEST. Single-file bundles are required by programs
such as Git and Lynx."
`((type . profile-hook)
(hook . emacs-subdirs))))
+(define (gdk-pixbuf-loaders-cache-file manifest)
+ "Return a derivation that produces a loaders cache file for every gdk-pixbuf
+loaders discovered in MANIFEST."
+ (define gdk-pixbuf ;lazy reference
+ (module-ref (resolve-interface '(gnu packages gtk)) 'gdk-pixbuf))
+
+ (mlet %store-monad ((%gdk-pixbuf (manifest-lookup-package
+ manifest "gdk-pixbuf"))
+ (gdk-pixbuf-query-loaders
+ -> (file-append gdk-pixbuf
+ "/bin/gdk-pixbuf-query-loaders")))
+ (define build
+ (with-imported-modules (source-module-closure
+ '((guix build glib-or-gtk-build-system)))
+ #~(begin
+ (use-modules (guix build glib-or-gtk-build-system))
+ (generate-gdk-pixbuf-loaders-cache '#$(manifest-inputs manifest)
+ (list #$output)))))
+ (if %gdk-pixbuf
+ (gexp->derivation "gdk-pixbuf-loaders-cache-file" build
+ #:local-build? #t
+ #:substitutable? #f
+ #:properties
+ '((type . profile-hook)
+ (hook . gdk-pixbuf-loaders-cache-file)))
+ (return #f))))
+
(define (glib-schemas manifest)
"Return a derivation that unions all schemas from manifest entries and
creates the Glib 'gschemas.compiled' file."
@@ -1672,6 +1699,7 @@ the entries in MANIFEST."
ghc-package-cache-file
ca-certificate-bundle
emacs-subdirs
+ gdk-pixbuf-loaders-cache-file
glib-schemas
gtk-icon-themes
gtk-im-modules
- 95/136: gnu: Move a few Python packages to (gnu packages python-build)., (continued)
- 95/136: gnu: Move a few Python packages to (gnu packages python-build)., guix-commits, 2021/10/17
- 64/136: gnu: gst-plugins-ugly: Update to 1.18.5., guix-commits, 2021/10/17
- 70/136: gnu: python-keras: Enable parallel tests., guix-commits, 2021/10/17
- 98/136: gnu: Add python-tomli., guix-commits, 2021/10/17
- 111/136: gnu: colord-minimal: Introduce minimal variant., guix-commits, 2021/10/17
- 118/136: gnu: cmake-bootstrap: Update to 3.21.3., guix-commits, 2021/10/17
- 123/136: gnu: pango: Update to 1.48.10., guix-commits, 2021/10/17
- 125/136: gnu: glib: Update to 2.70, specify a bindir prefix and hide package., guix-commits, 2021/10/17
- 132/136: gnu: gtk: Add the generate-gdk-pixbuf-loaders-cache-file phase., guix-commits, 2021/10/17
- 133/136: build: glib-or-gtk: Generate the gdk-pixbuf-loaders cache file in a phase., guix-commits, 2021/10/17
- 134/136: profiles: Add a gdk-pixbuf-loaders-cache-file hook.,
guix-commits <=
- 37/136: gnu: python-sphinxcontrib-serializinghtml: Update to 1.1.5., guix-commits, 2021/10/17
- 53/136: gnu: googletest: Update to 1.11.0., guix-commits, 2021/10/17
- 56/136: gnu: mozjs-78: Update to 78.13.0., guix-commits, 2021/10/17
- 61/136: gnu: gst-plugins-base: Update to 1.18.5., guix-commits, 2021/10/17
- 69/136: gnu: tensorflow: Enable parallel build (at least partially)., guix-commits, 2021/10/17
- 90/136: gnu: glade3: Remove sitecustomize.py workaround., guix-commits, 2021/10/17
- 93/136: gnu: Build all Rust packages using the latest rustc., guix-commits, 2021/10/17
- 96/136: gnu: python-pypa-build: Update to 0.7.0., guix-commits, 2021/10/17
- 100/136: gnu: python-pytest-6: Fix version via setuptools-scm., guix-commits, 2021/10/17
- 99/136: gnu: python-setuptools-scm: Update to 6.3.2, guix-commits, 2021/10/17