On 23-Feb-2008, Jens Langner wrote:
as I am currently working on fixing our outstanding issues with building/creating an updated native OS4 4.2.x gcc compiler, I am currently having some trouble as I haven't yet built any native compiler myself and just create linux hosted cross compilers. Would someone who built the last native compiler please enlight me (probably Hans-Jörg) how he managed to link the hosted compiler against "-lunix" which is obviously required to have the compiler properly working with unix pathes?
It's been a while since I built a native compiler, but as far as I remember, you need to modify the specs file (-dumpspecs them to the appropriate place if they don't exist) for the cross compiler so that it builds the executables with -lunix (change the *lib: line to add -lunix in front of -lc). Of course, you can change it back/remove the specs file after everything is built.
AFAIR, you *may* also need to link .../newlib/lib/soft-float/*.[oa] files to .../newlib/*.[oa] files (the directory linking would probably work, too) before starting the build since the compiler will try to build the soft-float variants of linker libraries.
This is not related to the native compiler, but if you build the whole thing, make sure you build both newlib and clib2 C++ libraries (you have probably had the chance to do that before, but there's additional information in my posts at http://utilitybase.com/forum/index.php?action=vthread&forum=2&topic=658 if required).
Andrija