[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
01/07: gnu: meson: Extend the python path in the installed program.
From: |
guix-commits |
Subject: |
01/07: gnu: meson: Extend the python path in the installed program. |
Date: |
Mon, 22 Nov 2021 17:52:29 -0500 (EST) |
civodul pushed a commit to branch core-updates-frozen
in repository guix.
commit 021d3a32f5a2544e1111f8bbec20b75c40ad007d
Author: Vivien Kraus <vivien@planete-kraus.eu>
AuthorDate: Thu Nov 18 15:17:52 2021 +0100
gnu: meson: Extend the python path in the installed program.
* gnu/packages/build-tools.scm (meson-wrapped): New variable.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
---
gnu/packages/build-tools.scm | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)
diff --git a/gnu/packages/build-tools.scm b/gnu/packages/build-tools.scm
index 849101c..6a8a9c6 100644
--- a/gnu/packages/build-tools.scm
+++ b/gnu/packages/build-tools.scm
@@ -287,6 +287,7 @@ files and generates build instructions for the Ninja build
system.")
(inputs `(("ninja" ,ninja)))
(propagated-inputs `(("python" ,python)))
(home-page "https://mesonbuild.com/")
+ (properties '((hidden? . #t)))
(synopsis "Build system designed to be fast and user-friendly")
(description
"The Meson build system is focused on user-friendliness and speed.
@@ -297,6 +298,29 @@ files}, are written in a custom domain-specific language
(@dfn{DSL}) that
resembles Python.")
(license license:asl2.0)))
+(define-public meson-wrapped
+ (package/inherit meson
+ (arguments
+ `(;; FIXME: Tests require many additional inputs and patching many
+ ;; hard-coded file system locations in "run_unittests.py".
+ #:tests? #f
+ #:phases (modify-phases %standard-phases
+ ;; Meson calls the various executables in out/bin through the
+ ;; Python interpreter, so we cannot use the shell wrapper.
+ (replace 'wrap
+ (lambda* (#:key outputs inputs #:allow-other-keys)
+ (let ((python-version
+ (python-version (assoc-ref inputs "python")))
+ (output (assoc-ref outputs "out")))
+ (substitute* (string-append output "/bin/meson")
+ (("# EASY-INSTALL-ENTRY-SCRIPT")
+ (format #f "\
+import sys
+sys.path.insert(0, '~a/lib/python~a/site-packages')
+# EASY-INSTALL-ENTRY-SCRIPT"
+ output python-version)))))))))
+ (properties '())))
+
;;; This older Meson variant is kept for now for gtkmm and others that may
;;; have problems with 0.60.
(define-public meson-0.59
- branch core-updates-frozen updated (a24b83d -> 12f6831), guix-commits, 2021/11/22
- 01/07: gnu: meson: Extend the python path in the installed program.,
guix-commits <=
- 03/07: gnu: gupnp-igd: Set HOME before 'check' phase., guix-commits, 2021/11/22
- 02/07: gnu: meson-wrapped: Do not propagate Python., guix-commits, 2021/11/22
- 05/07: gnu: libgadu: Build with '-fcommon'., guix-commits, 2021/11/22
- 06/07: gnu: certdata2pem: Make public., guix-commits, 2021/11/22
- 04/07: gnu: libmateweather: Build with libsoup 2., guix-commits, 2021/11/22
- 07/07: gnu: openresolv: Wrap resolvconf., guix-commits, 2021/11/22