This is the mail archive of the
mailing list for the GCC project.
RE: [MinGW] Set NATIVE_SYSTEM_HEADER_DIR relative to configured prefix
- From: Danny Smith <dannysmith at clear dot net dot nz>
- To: 'Mark Mitchell' <mark at codesourcery dot com>, 'Ranjit Mathew' <rmathew at gmail dot com>
- Cc: 'GCC Patches' <gcc-patches at gcc dot gnu dot org>
- Date: Sat, 03 Jun 2006 16:21:46 +1200
- Subject: RE: [MinGW] Set NATIVE_SYSTEM_HEADER_DIR relative to configured prefix
> From: Mark Mitchell
> Ranjit Mathew wrote:
> > Hi,
> > After Mark's patch in:
> > http://gcc.gnu.org/ml/gcc-patches/2005-08/msg00122.html
> Ranjit --
> Sorry, I got these messages out of order. Now, I understand
> what you were asking about.
> > So I propose that MinGW's NATIVE_SYSTEM_HEADER_DIR be
> > set relative to its configured prefix as shown by the
> attached patch.
> That doesn't make sense to me. There's no guarantee that the
> MinGW headers are in the same location as the compiler; if
> your MinGW headers are in /mingw/include, you can still
> install the compiler in /usr/local. On most systems, the
> system header directory is a constant; if it's not, for
> MinGW, then I think you need a new configure option.
> (Of course, if users are free to put the MinGW headers
> wherever they like, then if you ship compiler binaries to
> someone, you can't know where they may have put the headers.
> So, I would expect people would need to use -isystem in that
Historically, mingw host doesn't have a "system include dir". Instead
host relies on a local dir being in consistent place relative to exec
prefix, and this in turn means that it is consistent relative to the gcc
driver, ie, in x-mingw:
# Make local_includedir relative to EXEC_PREFIX
local_includedir=$(libsubdir)/$(unlibsubdir)/..`echo $(exec_prefix) |
sed -e 's|^$(prefix)||' -e 's|/[^/]*|/..|g'`/include
Historically, the closest thing that mingw has to a hard-coded system
include dir is
the prefix specified by the release manager (Mumit Khan and then me in
this short history since about 1998 -- before then is before my memory)
that has been "/mingw/include"