This is the mail archive of the crossgcc@sourceware.org mailing list for the crossgcc project.
See the CrossGCC FAQ for lots more information.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
Hi, While building crosstool-0.38 on Fedora Core 4 (i686) for powerpc-7450, gcc-3.4.1 and glibc 2.3.3 (the default for demo-ppc7450.sh), I ran into a minor problem. At the step where testhello.sh is run to build hello.c, I got the following error: /opt/crosstool/gcc-3.4.1-glibc-2.3.3/powerpc-7450-linux-gnu/bin/powerpc-7450-linux-gnu-gcc -static hello.c -o powerpc-7450-linux-gnu-hello-static hello.c: In function `main': hello.c:4: error: `PATH_MAX' undeclared (first use in this function) hello.c:4: error: (Each undeclared identifier is reported only once hello.c:4: error: for each function it appears in.) I did a quick search to find which header(s) defined PATH_MAX and found two: /opt/crosstool/gcc-3.4.1-glibc-2.3.3/powerpc-7450-linux-gnu/powerpc-7450-linux-gnu/sys-include/linux/limits.h and: /opt/crosstool/gcc-3.4.1-glibc-2.3.3/powerpc-7450-linux-gnu/powerpc-7450-linux-gnu/include/linux/limits.h The limits.h that hello.c actually includes is (found via gcc -E): /opt/crosstool/gcc-3.4.1-glibc-2.3.3/powerpc-7450-linux-gnu/lib/gcc/powerpc-7450-linux-gnu/3.4.1/include/limits.h which doesn't include any other header files. But, that header is needed to get the definition for LONG_MIN. Adding a third include to hello.c, for <linux/limits.h>, fixes the problem. Ron McCall ------ Want more information? See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/ Want to unsubscribe? Send a note to crossgcc-unsubscribe@sources.redhat.com
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |