gcc46 header search path

Andriy Gapon avg at FreeBSD.org
Fri Jul 6 16:54:07 UTC 2012


on 06/07/2012 19:21 Warner Losh said the following:
> I didn't, because I know the standard behavior.  Turns out, I don't know
> today's standard behavior, just the historical behavior of gcc, which has
> changed over the life of FreeBSD.
> 
> FreeBSD's standard compiler has never included it.  There was talk about 10
> years ago about adding it, but it was shouted down as a stupid idea.  I tend to
> agree, but I can't articulate good reasons.

Yeah.  Honestly speaking I myself was not aware of what is written in that link
and I thought that our gcc ports (from ports) added /usr/local/include to the
default search path by some mistake.  And if somebody asked me what I thought
about the idea of adding /usr/local/include to the default path, I'd say that it
was a stupid idea.
But then I discovered that information.  And verified that even Linux
distributions that have zero files under /usr/local still keep the upstream behavior.
So now I am thinking in opposite direction: do we have a strong enough reason to
deviate from the default upstream behavior in this case.

My main motivation is to keep behavior of base gcc and gcc-s from ports as close
as possible (but no closer) to avoid such hidden gems when using the compilers
interchangeably to build our ports tree.

-- 
Andriy Gapon




More information about the freebsd-toolchain mailing list