From: Thiago Jung Bauermann via Bug reports for GNU Guix <bug-guix@gnu.org>
To: Leo Famulari <leo@famulari.name>
Cc: 49815@debbugs.gnu.org, Thiago Jung Bauermann <bauermann@kolabnow.com>
Subject: bug#49815: [PATCH] build-system/scons: Set $CPPPATH
Date: Fri, 6 Aug 2021 19:55:17 -0300 [thread overview]
Message-ID: <20210806225517.346462-1-bauermann@kolabnow.com> (raw)
In-Reply-To: <YQhikmaTv8sRAGbZ@jasmine.lan>
The SCons build system sets the compiler include path from the $CPPPATH
environment variable while GCC and Guix use $C_INCLUDE_PATH, so set the
former with the value of the latter.
* guix/build/scons-build-system.scm (build): Set $CPPPATH from
$C_INCLUDE_PATH.
---
Hi Leo,
I was able to build your patch using this one.
Thanks,
Thiago
guix/build/scons-build-system.scm | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/guix/build/scons-build-system.scm b/guix/build/scons-build-system.scm
index 17a0b7b877e6..fa422c41a172 100644
--- a/guix/build/scons-build-system.scm
+++ b/guix/build/scons-build-system.scm
@@ -20,6 +20,7 @@
(define-module (guix build scons-build-system)
#:use-module ((guix build gnu-build-system) #:prefix gnu:)
#:use-module (guix build utils)
+ #:use-module (srfi srfi-26)
#:export (%standard-phases
scons-build))
@@ -32,6 +33,10 @@
(define* (build #:key outputs (build-targets '()) (scons-flags '()) (parallel-build? #t) #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))
(mkdir-p out)
+ ;; SCons expects the include path in $CPPPATH, so copy from
+ ;; $C_INCLUDE_PATH.
+ (let ((c-include-path (getenv "C_INCLUDE_PATH")))
+ (and=> c-include-path (cut setenv "CPPPATH" <>)))
(apply invoke "scons"
(append (if parallel-build?
(list "-j" (number->string
next prev parent reply other threads:[~2021-08-06 22:56 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-08-01 21:27 bug#49815: Upcoming timekeeping failure in gpsd Leo Famulari
2021-08-02 21:24 ` Leo Famulari
2021-08-06 22:55 ` Thiago Jung Bauermann via Bug reports for GNU Guix [this message]
2021-08-07 0:44 ` Sarah Morgensen
2021-08-07 0:58 ` bug#49815: [PATCH] build-system/scons: Set $CPPPATH Thiago Jung Bauermann via Bug reports for GNU Guix
2021-08-07 3:13 ` bug#49815: Upcoming timekeeping failure in gpsd Sarah Morgensen
2021-08-07 18:12 ` Leo Famulari
2021-08-07 22:17 ` Thiago Jung Bauermann via Bug reports for GNU Guix
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=20210806225517.346462-1-bauermann@kolabnow.com \
--to=bug-guix@gnu.org \
--cc=49815@debbugs.gnu.org \
--cc=bauermann@kolabnow.com \
--cc=leo@famulari.name \
/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).