[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
103/140: build: glib-or-gtk-build-system: Simplify the wrap-all-programs
From: |
guix-commits |
Subject: |
103/140: build: glib-or-gtk-build-system: Simplify the wrap-all-programs phase. |
Date: |
Sun, 17 Oct 2021 23:11:07 -0400 (EDT) |
apteryx pushed a commit to branch core-updates-frozen-batched-changes
in repository guix.
commit 93a9e72294b0eb30f8d9aa4c286877bc8b153dac
Author: Maxim Cournoyer <maxim.cournoyer@gmail.com>
AuthorDate: Sun Oct 3 21:11:37 2021 -0400
build: glib-or-gtk-build-system: Simplify the wrap-all-programs phase.
* guix/build/glib-or-gtk-build-system.scm (wrap-all-programs)
<handle-output>: Precisely build the list of variable specifications, rather
than relying on a bunch of conditionals.
---
guix/build/glib-or-gtk-build-system.scm | 59 ++++++++-------------------------
1 file changed, 13 insertions(+), 46 deletions(-)
diff --git a/guix/build/glib-or-gtk-build-system.scm
b/guix/build/glib-or-gtk-build-system.scm
index 9f4cc09..655f20c 100644
--- a/guix/build/glib-or-gtk-build-system.scm
+++ b/guix/build/glib-or-gtk-build-system.scm
@@ -169,52 +169,19 @@ add a dependency of that output on GLib and GTK+."
(alist-cons output directory inputs)))
(gio-mod-dirs (gio-module-directories
(alist-cons output directory inputs)))
- (data-env-var
- (if (not (null? datadirs))
- `("XDG_DATA_DIRS" ":" prefix ,datadirs)
- #f))
- (gtk-mod-env-var
- (if (not (null? gtk-mod-dirs))
- `("GTK_PATH" ":" prefix ,gtk-mod-dirs)
- #f))
- (gio-mod-env-var
- (if (not (null? gio-mod-dirs))
- `("GIO_EXTRA_MODULES" ":" prefix ,gio-mod-dirs)
- #f)))
- (cond
- ((and data-env-var gtk-mod-env-var gio-mod-env-var)
- (for-each (cut wrap-program <> #:sh (sh)
- data-env-var
- gtk-mod-env-var
- gio-mod-env-var)
- bin-list))
- ((and data-env-var gtk-mod-env-var (not gio-mod-env-var))
- (for-each (cut wrap-program <> #:sh (sh)
- data-env-var
- gtk-mod-env-var)
- bin-list))
- ((and data-env-var (not gtk-mod-env-var) gio-mod-env-var)
- (for-each (cut wrap-program <> #:sh (sh)
- data-env-var
- gio-mod-env-var)
- bin-list))
- ((and (not data-env-var) gtk-mod-env-var gio-mod-env-var)
- (for-each (cut wrap-program <> #:sh (sh)
- gio-mod-env-var
- gtk-mod-env-var)
- bin-list))
- ((and data-env-var (not gtk-mod-env-var) (not gio-mod-env-var))
- (for-each (cut wrap-program <> #:sh (sh)
- data-env-var)
- bin-list))
- ((and (not data-env-var) gtk-mod-env-var (not gio-mod-env-var))
- (for-each (cut wrap-program <> #:sh (sh)
- gtk-mod-env-var)
- bin-list))
- ((and (not data-env-var) (not gtk-mod-env-var) gio-mod-env-var)
- (for-each (cut wrap-program <> #:sh (sh)
- gio-mod-env-var)
- bin-list))))))))
+ (env-vars `(,@(if (not (null? datadirs))
+ (list `("XDG_DATA_DIRS" ":" prefix ,datadirs))
+ '())
+ ,@(if (not (null? gtk-mod-dirs))
+ (list `("GTK_PATH" ":" prefix ,gtk-mod-dirs))
+ '())
+ ,@(if (not (null? gio-mod-dirs))
+ (list `("GIO_EXTRA_MODULES" ":"
+ prefix ,gio-mod-dirs))
+ '()))))
+ (for-each (lambda (program)
+ (apply wrap-program program #:sh (sh) env-vars))
+ bin-list))))))
(for-each handle-output outputs)
#t)
- 75/140: gnu: glibc: Remove unneeded nscd patching., (continued)
- 75/140: gnu: glibc: Remove unneeded nscd patching., guix-commits, 2021/10/17
- 80/140: gnu: diffutils: Update to 3.8., guix-commits, 2021/10/17
- 78/140: gnu: gtk+-2: Fix ‘builder’ test., guix-commits, 2021/10/17
- 85/140: gnu: Add ld-gold-wrapper., guix-commits, 2021/10/17
- 86/140: gnu: gdb: Patch references to /bin/sh and add debug output., guix-commits, 2021/10/17
- 96/140: gnu: python-pypa-build: Update to 0.7.0., guix-commits, 2021/10/17
- 94/140: gnu: fontconfig: Add a search path for XDG_DATA_DIRS., guix-commits, 2021/10/17
- 91/140: gnu: rust: Bootstrap rust from 1.39.0 and optimize build time., guix-commits, 2021/10/17
- 99/140: gnu: python-setuptools-scm: Update to 6.3.2, guix-commits, 2021/10/17
- 101/140: gnu: python-pathlib2: Update to 2.3.6., guix-commits, 2021/10/17
- 103/140: build: glib-or-gtk-build-system: Simplify the wrap-all-programs phase.,
guix-commits <=
- 106/140: gnu: at-spi2-atk: Break a dependency cycle between GTK+ and Inkscape., guix-commits, 2021/10/17
- 109/140: gnu: json-glib-minimal: Introduce minimal variant., guix-commits, 2021/10/17
- 112/140: gnu: libcloudproviders-minimal: Introduce minimal variant., guix-commits, 2021/10/17
- 111/140: gnu: colord-minimal: Introduce minimal variant., guix-commits, 2021/10/17
- 110/140: gnu: Add docbook-xsl-ns., guix-commits, 2021/10/17
- 128/140: gnu: libsoup: Reverse inheritance relationship with libsoup-minimal., guix-commits, 2021/10/17
- 129/140: gnu: libsoup: Update to 3.0.1., guix-commits, 2021/10/17
- 133/140: gnu: python-flit: Update to 3.3.0., guix-commits, 2021/10/17
- 137/140: build: glib-or-gtk: Generate the gdk-pixbuf-loaders cache file in a phase., guix-commits, 2021/10/17
- 08/140: gnu: gtk+: Add a debug output., guix-commits, 2021/10/17