diff options
author | Ricardo Wurmus <rekado@elephly.net> | 2018-08-13 20:39:08 +0200 |
---|---|---|
committer | Ricardo Wurmus <rekado@elephly.net> | 2018-08-13 20:39:32 +0200 |
commit | b86c019efbc5c4ea35f3cd6d2f52985f40e49e6c (patch) | |
tree | 01c8ec8d4172c2834bef1e8859d6ca8b99338470 /guix/build/meson-build-system.scm | |
parent | 25bd72678ae4048b0b84ee82bc5f2644367e9715 (diff) | |
parent | 7b38f045c04fe69001ff5c2f04486cc51a69ae82 (diff) | |
download | gnu-guix-b86c019efbc5c4ea35f3cd6d2f52985f40e49e6c.tar gnu-guix-b86c019efbc5c4ea35f3cd6d2f52985f40e49e6c.tar.gz |
Merge branch 'staging' into core-updates
Diffstat (limited to 'guix/build/meson-build-system.scm')
-rw-r--r-- | guix/build/meson-build-system.scm | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/guix/build/meson-build-system.scm b/guix/build/meson-build-system.scm index 9724764424..f6b8b49801 100644 --- a/guix/build/meson-build-system.scm +++ b/guix/build/meson-build-system.scm @@ -1,6 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2017 Peter Mikkelsen <petermikkelsen10@gmail.com> ;;; Copyright © 2018 Ricardo Wurmus <rekado@elephly.net> +;;; Copyright © 2018 Marius Bakke <mbakke@fastmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -45,18 +46,13 @@ (prefix (assoc-ref outputs "out")) (args `(,(string-append "--prefix=" prefix) ,(string-append "--buildtype=" build-type) + ,(string-append "-Dc_link_args=-Wl,-rpath=" + (assoc-ref outputs "out") "/lib") + ,(string-append "-Dcpp_link_args=-Wl,-rpath=" + (assoc-ref outputs "out") "/lib") ,@configure-flags ,source-dir))) - ;; Meson lacks good facilities for dealing with RUNPATH, so we - ;; add the output "lib" directory here to avoid doing that in - ;; many users. Related issues: - ;; * <https://github.com/mesonbuild/meson/issues/314> - ;; * <https://github.com/mesonbuild/meson/issues/3038> - ;; * <https://github.com/NixOS/nixpkgs/issues/31222> - (unless (getenv "LDFLAGS") - (setenv "LDFLAGS" (string-append "-Wl,-rpath=" out "/lib"))) - (mkdir build-dir) (chdir build-dir) (apply invoke "meson" args))) @@ -148,8 +144,13 @@ for example libraries only needed for the tests." (replace 'configure configure) (replace 'build build) (replace 'check check) - (replace 'install install) - (add-after 'strip 'fix-runpath fix-runpath))) + ;; XXX: We used to have 'fix-runpath' here, but it appears no longer + ;; necessary with newer Meson. However on 'core-updates' there is a + ;; useful 'strip-runpath' procedure to ensure no bogus directories in + ;; RUNPATH (remember that we tell Meson to not touch RUNPATH in + ;; (@ (gnu packages build-tools) meson-for-build)), so it should be + ;; re-added there sans the augment-rpath calls (which are not needed). + (replace 'install install))) (define* (meson-build #:key inputs phases #:allow-other-keys #:rest args) |