From: Zhu Zihao <all_but_last@163.com>
To: "Ludovic Courtès" <ludo@gnu.org>
Cc: 58394@debbugs.gnu.org, Zhu Zihao <all_but_last@163.com>
Subject: [bug#58394] [PATCH 4/4] gnu: libcxx+libcxxabi: Use G-expressions.
Date: Thu, 27 Oct 2022 16:33:30 +0800 [thread overview]
Message-ID: <20221027083330.960-4-all_but_last@163.com> (raw)
In-Reply-To: <87eduy4yhv.fsf@gnu.org>
* gnu/packages/llvm.scm (libcxx+libcxxabi-6)[arguments]: Use G-expressions.
<#:configure-flags>: Use "this-package-native-input".
---
gnu/packages/llvm.scm | 44 ++++++++++++++++++++++---------------------
1 file changed, 23 insertions(+), 21 deletions(-)
diff --git a/gnu/packages/llvm.scm b/gnu/packages/llvm.scm
index 17c51ea6bb..324149116b 100644
--- a/gnu/packages/llvm.scm
+++ b/gnu/packages/llvm.scm
@@ -1677,27 +1677,29 @@ (define-public libcxx+libcxxabi-6
(name "libcxx+libcxxabi")
(version (package-version libcxx-6))
(arguments
- `(#:configure-flags
- (list "-DLIBCXX_CXX_ABI=libcxxabi"
- (string-append "-DLIBCXX_CXX_ABI_INCLUDE_PATHS="
- (assoc-ref %build-inputs "libcxxabi")
- "/include"))
- #:phases
- (modify-phases (@ (guix build cmake-build-system) %standard-phases)
- (add-after 'set-paths 'adjust-CPLUS_INCLUDE_PATH
- (lambda* (#:key inputs #:allow-other-keys)
- (let ((gcc (assoc-ref inputs "gcc")))
- ;; Hide GCC's C++ headers so that they do not interfere with
- ;; the ones we are attempting to build.
- (setenv "CPLUS_INCLUDE_PATH"
- (string-join
- (delete (string-append gcc "/include/c++")
- (string-split (getenv "CPLUS_INCLUDE_PATH")
- #\:))
- ":"))
- (format #true
- "environment variable `CPLUS_INCLUDE_PATH' changed to ~a~%"
- (getenv "CPLUS_INCLUDE_PATH"))))))))
+ (list
+ #:configure-flags
+ #~(list "-DLIBCXX_CXX_ABI=libcxxabi"
+ (string-append "-DLIBCXX_CXX_ABI_INCLUDE_PATHS="
+ #$(this-package-native-input "libcxxabi")
+ "/include"))
+ #:phases
+ #~(modify-phases (@ (guix build cmake-build-system) %standard-phases)
+ (add-after 'set-paths 'adjust-CPLUS_INCLUDE_PATH
+ (lambda* (#:key inputs #:allow-other-keys)
+ (let ((gcc (assoc-ref inputs "gcc")))
+ ;; Hide GCC's C++ headers so that they do not interfere with
+ ;; the ones we are attempting to build.
+ (setenv "CPLUS_INCLUDE_PATH"
+ (string-join
+ (delete (string-append gcc "/include/c++")
+ (string-split (getenv "CPLUS_INCLUDE_PATH")
+ #\:))
+ ":"))
+ (format
+ #true
+ "environment variable `CPLUS_INCLUDE_PATH' changed to ~a~%"
+ (getenv "CPLUS_INCLUDE_PATH"))))))))
(native-inputs
(list clang-6 llvm-6 libcxxabi-6))))
--
2.38.0
next prev parent reply other threads:[~2022-10-27 8:36 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-10-09 14:59 [bug#58394] [PATCH]: gnu: libcxx: Update to 14.0.6 Zhu Zihao
2022-10-23 10:37 ` Ludovic Courtès
2022-10-27 8:33 ` [bug#58394] [PATCH 1/4] gnu: libcxx: Use G-expressions Zhu Zihao
2022-10-27 8:33 ` [bug#58394] [PATCH 2/4] gnu: libcxx: Update to 14.0.6 Zhu Zihao
2022-10-27 8:33 ` [bug#58394] [PATCH 3/4] gnu: libcxxabi: Use G-expressions Zhu Zihao
2022-10-27 8:33 ` Zhu Zihao [this message]
2022-11-05 23:38 ` bug#58394: [PATCH 1/4] gnu: libcxx: " Ludovic Courtès
2022-10-27 8:36 ` [bug#58394] [PATCH]: gnu: libcxx: Update to 14.0.6 Zhu Zihao
2022-11-02 13:52 ` Zhu Zihao
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20221027083330.960-4-all_but_last@163.com \
--to=all_but_last@163.com \
--cc=58394@debbugs.gnu.org \
--cc=ludo@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).