GCC System Headers

llewelly@xmission.com llewelly@xmission.com
Thu Mar 25 12:02:00 GMT 2004

"Eddie Diener" <eddielee@tropicsoft.com> writes:

> How does GCC/G++ know where to look for its system header files ?

It's based on stuff figured out by the 'configure' script, when gcc is
    configured, before it is built from source code.

You can run:

    $ gcc -v hello.cc

    to see where gcc looks for header files.

If you need to chage where GCC looks for header from the command line,
    see http://xrl.us/btf4 and read about -I, -I-, and so forth. -I is
    usually sufficient.

> I am using GCC/G++ with MingW/DevCpp on Windows. In the DevCpp distribution,
> which used GCC 3.2.3, the C header files are in the DevCpp\include directory
> and the C++ header files are off of the DevCpp\include\c++ directory. Yet
> when I downloaded the latest MingW/GCC/G++ implementation, 3.3.1, there are
> no C header files in the release and the C++ header files are placed off of
> the DevCpp\include\c++\3.3.1 directory.
> So I am confused. First, why there are no C header files in the
> distribution,

GCC does not come with an implementation of the standard C library; it
    relies on the systm provided C library.

More information about the Gcc-help mailing list