This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: [BUG] Compiling i386-mingw32 cross compiler


> > ** First error... egcs/CROSS/gcc/fixinc.sh is not found... creating a
> > link to egcs/gcc/fixinc.sh fixes that
> 
> I don't see this. Also, may want to leave out the host spec; let configure
> figure it out that you're hosting on i686-pc-linux-gnu instead.

For some reason it is failing to guess the host these days... these
problems occurred before that broke though.

> > ** Second error... stdlib.h and unistd.h not found when compiling
> > gcc/libgcc2.c... commenting them out allows it to compile
> 
> Don't see this either. If the runtime headers are installed in the right place,
> it should find it. Try the following and see where it's searching:
> 
>   $ cd <objdir>/gcc
>   $ echo > foo.c
>   $ ./xgcc -B./ -c -v foo.c

gives me:
#include "..." search starts here:
#include <...> search starts here:
 include
End of search list.
The following default directories have bee omitted from the search path:
/usr/local/mingw32/CROSS/lib/gcc-lib/i386-mingw32/gcc-2.96/../../../../include/g++-2
/usr/local/mingw32/CROSS/lib/gcc-lib/i386-mingw32/gcc-2.96/include
/usr/local/mingw32/CROSS/lib/gcc-lib/i386-mingw32/gcc-2.96/../../../../i386-mingw32/sys-include
/usr/local/mingw32/CROSS/lib/gcc-lib/i386-mingw32/gcc-2.96/../../../../i386-mingw32/include
End of omitted list.

> Given your prefix, the runtime headers should be in:
>   /usr/local/mingw32/i386-mingw32/include
> and libraries in:
>   /usr/local/mingw32/i386-mingw32/lib

If you include the CROSS that's basically what you get.

> > ** Third error (which I haven't found a way around)...
> > egcs/CROSS/gcc/xgcc can not build executables. try to run it manually
> > with "#include <stdio.h> int main() {}" as an input file gives:
> > cpp: unrecognized option `-remap'
> > cpp: -lang-c: linker input file unused since linking not done
> > xgcc: installation problem, cannot exec `c1': No such file or directory
> 
> You're quite possibly running the wrong cpp. Make sure you don't have
> GCC_EXEC_PREFIX, LIBRARY_PATH, etc not defined in the environment.
> Clean out environment completely (other than PATH of course ;-) and
> see if the situation improves.

Nothing at all make related... besides the MAKE='make -j4' I used on my
SMP box when building ALSA.

> What does:
> 
>   $ ./xgcc -B./ -print-prog-name=cpp
> 
> say? Is it picking up cpp from gcc build directory?

./cpp

Thank you.

Brian Macy


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]