unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: "Ludovic Courtès" <ludo@gnu.org>
To: Greg Hogan <code@greghogan.com>
Cc: guix-devel@gnu.org
Subject: Re: Building clang with gcc-toolchain@11
Date: Mon, 07 Mar 2022 11:18:15 +0100	[thread overview]
Message-ID: <875yoq2hi0.fsf@gnu.org> (raw)
In-Reply-To: <CA+3U0Zm_T19jTC1sK2LoYq+aeQoM+zh_a=zBBKq+YL8ni-rjhQ@mail.gmail.com> (Greg Hogan's message of "Mon, 28 Feb 2022 11:36:17 -0500")

Hi,

Greg Hogan <code@greghogan.com> skribis:

> I'd like to instead use the latest gcc-toolchain (currently gcc-toolchain@11)
> and have clang-toolchain built with that gcc-toolchain. No matter what
> I offer in the "--with-c-toolchain" or "--with-input" options I always see
> the following error regarding '(assoc-ref %build-inputs "libc")' evaluating
> as false, even when specifying "--with-c-toolchain=clang=gcc-toolchain@10"
> that should currently be in use by default. Any ideas for fixing this?

The ‘clang’ definition reads:

             ;; Use a sane default include directory.
             (string-append "-DC_INCLUDE_DIRS="
                            (assoc-ref %build-inputs "libc")
                            "/include")

What happens if we don’t pass that option, or if we pass
“-DC_INCLUDE_DIRS=/no-such-directory”?

It might work because C_INCLUDE_PATH already contains libc’s include
directory; that way, we’d no longer rely on the “libc” label, which is
what prevents use of ‘--with-c-toolchain’ here.

HTH,
Ludo’.


  reply	other threads:[~2022-03-07 10:53 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-28 16:36 Building clang with gcc-toolchain@11 Greg Hogan
2022-03-07 10:18 ` Ludovic Courtès [this message]
2022-03-07 21:10   ` Greg Hogan

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=875yoq2hi0.fsf@gnu.org \
    --to=ludo@gnu.org \
    --cc=code@greghogan.com \
    --cc=guix-devel@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).