public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
From: Ian Lance Taylor <ian@airs.com>
To: Andrew McCall <andrew.mccall@gmail.com>
Cc: gcc-help@gcc.gnu.org
Subject: Re: Problems building a cross compiler...
Date: Fri, 22 Jul 2005 16:48:00 -0000	[thread overview]
Message-ID: <m3u0imltlo.fsf@gossamer.airs.com> (raw)
In-Reply-To: <4aa50a46050722035016beaf54@mail.gmail.com>

Andrew McCall <andrew.mccall@gmail.com> writes:

> > The simplest approach is to copy all the header files and libraries
> > onto the cross-host, using the same directory layout under some
> > directory DIR, and then configure --with-sysroot=DIR.
> 
> I have been trying to get this working since you suggested it.
> 
> I have the headers, but they come in multiple folders like this:
> 
> headers/cpp
> headers/gnu
> headres/libs
> headers/os
> headers/posix
> headers/private
> headers/tools
> 
> In os I have the normal "Be" headers, such as Be.h, Appkit.h etc. etc.
> in posix I have the posix headers like alloca.h, assert.h and
> stdlib.h.

By the default gcc expects to see a Unix style file system layout,
with /lib, /usr/include, /usr/lib, etc.  The header files would
normally be found in SYSROOT/usr/include, and, e.g., stdlib.h would be
found in SYSROOT/usr/include/stdlib.h.

You could shuffle your header files around to meet Unix expectations.
Or you could sort out INCLUDE_DEFAULTS for the particular case of
CROSS_COMPILER and TARGET_SYSTEM_ROOT.  See cppdefault.c.  I see an
instance of INCLUDE_DEFAULT in config/i386/beos-elf.h, although the
directories there do not appear to match the directories you listed
above.

I'm afraid that you have an unusual scenario, and you are going to
have to learn how gcc handles include file searching.

Ian

      parent reply	other threads:[~2005-07-22 16:48 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-07-21 13:10 Andrew McCall
2005-07-21 16:56 ` Ian Lance Taylor
2005-07-22 10:50   ` Andrew McCall
2005-07-22 11:04     ` Rupert Wood
2005-07-22 12:27       ` Andrew McCall
2005-07-22 16:48     ` Ian Lance Taylor [this message]

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m3u0imltlo.fsf@gossamer.airs.com \
    --to=ian@airs.com \
    --cc=andrew.mccall@gmail.com \
    --cc=gcc-help@gcc.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.
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).