[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
103/130: build: glib-or-gtk-build-system: Simplify the wrap-all-programs
From: |
guix-commits |
Subject: |
103/130: build: glib-or-gtk-build-system: Simplify the wrap-all-programs phase. |
Date: |
Sat, 16 Oct 2021 02:36:42 -0400 (EDT) |
apteryx pushed a commit to branch core-updates-frozen-batched-changes
in repository guix.
commit 08047748cebe6982ad5a992bb943175c81c94c70
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)
- 82/130: gnu: curl: Honor #:tests?., (continued)
- 82/130: gnu: curl: Honor #:tests?., guix-commits, 2021/10/16
- 84/130: gnu: make-ld-wrapper: Add a LINKER argument., guix-commits, 2021/10/16
- 81/130: build: qt-utils: Don't wrap .X-real files., guix-commits, 2021/10/16
- 90/130: gnu: glade3: Remove sitecustomize.py workaround., guix-commits, 2021/10/16
- 89/130: aux-files: sitecustomize: Cleanup and add explanatory comments., guix-commits, 2021/10/16
- 87/130: gnu: gdb: Normalize indentation., guix-commits, 2021/10/16
- 97/130: gnu: Add python-flit-core., guix-commits, 2021/10/16
- 96/130: gnu: python-pypa-build: Update to 0.7.0., guix-commits, 2021/10/16
- 101/130: gnu: python-pathlib2: Update to 2.3.6., guix-commits, 2021/10/16
- 100/130: gnu: python-pytest-6: Fix version via setuptools-scm., guix-commits, 2021/10/16
- 103/130: build: glib-or-gtk-build-system: Simplify the wrap-all-programs phase.,
guix-commits <=
- 109/130: gnu: libcloudproviders-minimal: Introduce minimal variant., guix-commits, 2021/10/16
- 112/130: gnu: inkscape: Remove the legacy 0.92 version., guix-commits, 2021/10/16
- 111/130: gnu: rest: Use libsoup-minimal., guix-commits, 2021/10/16
- 119/130: gnu: mit-krb5: Absorb 1.19.2 graft., guix-commits, 2021/10/16
- 122/130: build: glib-or-gtk: Generate the gdk-pixbuf-loaders cache file in a phase., guix-commits, 2021/10/16
- 117/130: gnu: cmake-bootstrap: Update to 3.21.3., guix-commits, 2021/10/16
- 26/130: gnu: gst-plugins-bad: Add missing inputs to enable more features., guix-commits, 2021/10/16
- 48/130: gnu: python-gst: Update to 1.19.2., guix-commits, 2021/10/16
- 51/130: gnu: pulseaudio: Update to 15.0., guix-commits, 2021/10/16
- 55/130: gnu: abseil-cpp: Update to 20210324.2., guix-commits, 2021/10/16