../../src/gcc/gthr-posix.h:37:21: pthread.h: No such file or directory???

Rupert Wood me@rupey.net
Fri Apr 19 07:18:00 GMT 2002


Momchil Velikov wrote:

> Spencer> would someone advise me on how to fix this problem.
> 
> ... you need the solaris one in
> $prefix/sparc-sun-solaris2/sys-include.

To follow this up a little, you shouldn't be using newlib for Solaris
(or pretty much anything that isn't an embedded target).

Instead, you should create directories under your GCC install prefix

    sparc-sun-solaris2.8/sys-include
    sparc-sun-solaris2.8/lib

and copy the entire /usr/include tree from a solaris 2.8 machine to the
first, and the contents of /lib (but you don't need the subdirectories)
to the second. Then retry the cross compile, adding '--without-newlib'
to your configure line.

Alternatively, you can put the headers and libraries somewhere else and
ask GCC to install them as part of the configure

    --with-headers=<wherever>
    --with-libs=<wherever>

and, in this case, --without-newlib is assumed.

There's also a 'CrossGCC FAQ' at http://crossgcc.billgatliff.com/ in
case that helps.

Per Fransson recently tried to make a cross compiler to Solaris 2.8; you
might want to read these threads from other mailing lists: (from where
I've copy/pasted one of my old messages)

    http://gcc.gnu.org/ml/gcc/2002-04/msg00288.html
    http://sources.redhat.com/ml/crossgcc/2002-04/msg00028.html

although the latter does turn into a sys-include vs. include argument
after the first few messages :-/

Good luck,
Rup.



More information about the Gcc-help mailing list