[lazarus] cross compile again

LeVA leva at az.isten.hu
Sat Dec 13 04:00:03 EST 2003


Hello!

Beacuse no one replied, I thought that it might be useful to spend the
whole night with googling, and searching the answers for this cross
compiling :)
Now it somewhat clearer for me, what should I do.
I found a new howto, which explains this thing a little bit simpler.
Now I realized, that lazarus need these tools (asw, dlltools etc...) to
compile the project to win32. I think that those utils will be there,
after I compiled my new gcc, as I read it on the web-page (am I right?).
My problem is that I can not compile the new gcc(3.3.1). When typing
make, it says after a while that it can not find the sys/sysctl.h header
file. Well it is in my /usr/include dir, but gcc can not detect it,
because of the configure parameters I've added to it before the make.
I tought that I could solve this, and symlinked the /usr/include/sys
dir, to the gcc-source's include dir. Now the make found the sysctl.h
file, but it reported that another .h file is missing. So I linked
another (/usr/include/linux) dir to the gcc's include dir, and now the
make finally went thru this phase. But then it wrote some error messages
which I can not understand, and I thought maybe you could help me.
So, here is the make's output:



/home/leva/FreePascal/cross-compile_bin/i386-pc-mingw32/gcc-build/gcc/xgcc 
-B/home/leva/FreePascal/cross-compile_bin/i386-pc-mingw32/gcc-build/gcc/ 
-B/home/leva/FreePascal/cross-compile_bin/i386-pc-mingw32/bin/ 
-B/home/leva/FreePascal/cross-compile_bin/i386-pc-mingw32/lib/ -isystem 
/home/leva/FreePascal/cross-compile_bin/i386-pc-mingw32/include -c 
-DHAVE_CONFIG_H -O2 -g -O2 -I. -I../../../gcc-3.3.1/libiberty/../include 
  -W -Wall -Wtraditional -pedantic 
../../../gcc-3.3.1/libiberty/physmem.c -o physmem.o
In file included from ../../../gcc-3.3.1/include/features.h:283,
                  from ../../../gcc-3.3.1/include/unistd.h:26,
                  from ../../../gcc-3.3.1/libiberty/physmem.c:25:
../../../gcc-3.3.1/include/sys/cdefs.h:31:3: warning: suggest hiding 
#error from traditional C with an indented #
In file included from ../../../gcc-3.3.1/include/bits/types.h:143,
                  from ../../../gcc-3.3.1/include/unistd.h:190,
                  from ../../../gcc-3.3.1/libiberty/physmem.c:25:
../../../gcc-3.3.1/include/bits/pthreadtypes.h:16:3: warning: suggest 
hiding #error from traditional C with an indented #
...
...
...
../../../gcc-3.3.1/include/bits/stdio.h:113: warning: traditional C 
rejects ISO C style function definitions
../../../gcc-3.3.1/include/bits/stdio.h: In function `ferror_unlocked':
...
...
...
../../../gcc-3.3.1/include/bits/sigthread.h: At top level:
../../../gcc-3.3.1/include/bits/sigthread.h:36: warning: `__thread' is 
not at beginning of declaration
../../../gcc-3.3.1/include/bits/sigthread.h:36: error: storage class 
specified for parameter `type name'
../../../gcc-3.3.1/libiberty/pexecute.c: In function `pexecute':
../../../gcc-3.3.1/libiberty/pexecute.c:391: error: `O_BINARY' 
undeclared (first use in this function)
../../../gcc-3.3.1/libiberty/pexecute.c:391: error: (Each undeclared 
identifier is reported only once
../../../gcc-3.3.1/libiberty/pexecute.c:391: error: for each function it 
appears in.)
../../../gcc-3.3.1/libiberty/pexecute.c:422: warning: passing arg 3 of 
pointer to function from incompatible pointer type
../../../gcc-3.3.1/libiberty/pexecute.c:439: warning: assignment 
discards qualifiers from pointer target type
../../../gcc-3.3.1/libiberty/pexecute.c:374: warning: unused variable 
`retries'
../../../gcc-3.3.1/libiberty/pexecute.c:374: warning: unused variable 
`sleep_interval'
../../../gcc-3.3.1/libiberty/pexecute.c:366: warning: unused parameter 
`this_pname'
../../../gcc-3.3.1/libiberty/pexecute.c:367: warning: unused parameter 
`temp_base'
../../../gcc-3.3.1/libiberty/pexecute.c: In function `pwait':
../../../gcc-3.3.1/libiberty/pexecute.c:457: warning: unused parameter 
`flags'
make[1]: *** [pexecute.o] Error 1




I hope someone can understand these error messages, and can explain me, 
how to compile this gcc, and then finally, I will be able to compile my 
project to win32.


Thanks for the help!

Daniel


-- 
LeVA







More information about the Lazarus mailing list