Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
#1: Should i add --with-headers to binutils as well or it's only a gcc specific configure parameter?
#2: When i'm trying to compile binutils how jnc100 explained ( with --host=i586-pc-giszOS --target=i586-pc-giszOS) configure runs without failure but when i start make it looks for header files without success. Where should i put the header files of my C library? I've an include directory in .../my_cross_dir, should i place them there?
I've tried both without luck.. I got the same results with error that's why i asked
If i add the --with-headers parameter: CC=i586-pc-giszOS-gcc ./configure --host=i586-pc-giszOS --target=i586-pc-giszOS --prefix=/home/giszo/gcc_giszOS_native --disable-nls --with-headers=/path/of/my/C/header/files
i got the following error: *** --with-headers is only supported when cross compiling
If i just drop my libc header files to .../my_cross_dir/include i got a lot of error like this:
checking sys/time.h usability... no
checking sys/time.h presence... no
checking for sys/time.h... no
and so on..
giszo wrote:Where should i put the header files of my C library?
Personally, mine go in /usr/cross/i586-pc-tysos/include, where $PREFIX=/usr/cross and $TARGET=i586-pc-tysos (from when I built the cross compiler). Obviously, you need to be sure that your C library contains all the required headers...
I just moved the header files from ../my_cross_dir/include to ../my_cross_dir/i586-pc-giszOS/include and now make runs, thanks! I just need to work on my C library a bit more
<irony>
Of course not. It is named "standard" to mislead people into thinking it is about a standard collection of functions declared in standard headers...
</irony>
What is the problem with my header file if i got errors like these:
/home/giszo/gcc_giszOS_cross/bin/../lib/gcc/i586-pc-giszOS/4.2.2/../../../../i586-pc-giszOS/include/sys/types.h:45: error: two or more data types in declaration specifiers
In sys/types.h line #45 is the following:
typedef int pid_t;