Hi Koen, The process to build llvm-gcc as a crosscompiler is basically the same as build a normal gcc as crosscompiler. The differences: you need a LLVM installed (compiled for the host). You must configure llvm-gcc with --enable-llvm. Problems: - Today LLVM supports ARM/EABI, but llvm-gcc don't. You must apply the patch: http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20070319/046070.html (Please someone commit this patch!) - If your host system libraries are newer then gcc 4.0, you must configure llvm-gcc with "--disable-shared" (this is a workaround for a bug) It would be great to have llvm-gcc inside OpenEmbedded. The Mamona project could be the first Linux distribution totally compiled by llvm-gcc! Lauro 2007/4/1, Koen Kooi <koen at dominion.kabel.utwente.nl>:> -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Anton Korobeynikov schreef: > > Hello, Koen. > > > >> So my question is: How should I build llvm and llvm-gcc4 to have it cross-compile from x86 > >> to ARM/EABI? > > Well, just supply appropriate --host/--target options to configure. > > To llvm or llvm-gcc4? > > > I haven't tried ARM, but this definitely works for crosscompiling from > > linux to mingw32. Please also note, that you'll need native (=arm) tools > > (binutils, libcheaders, etc) > > You mean binutils-cross, right? > > > during gcc build process. > > Building gcc as a crosscompiler is fully automized in OpenEmbedded, I'm trying to add > llvm-gcc4 into that framework. > > regards, > > Koen > > -----BEGIN PGP SIGNATURE----- > Version: GnuPG v1.4.5 (Darwin) > > iD8DBQFGEBMwMkyGM64RGpERAnL+AKC4gtxNAPJetf0kOPJC2NAqF31tDwCfWmAu > WiNlCu36rf5JQ+AwGs7VSMs> =LLY2 > -----END PGP SIGNATURE----- > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev >
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Lauro Ramos Venancio schreef:> It would be great to have llvm-gcc inside OpenEmbedded. The Mamona > project could be the first Linux distribution totally compiled by > llvm-gcc!llvm-native 1.9 is in OE[1], I'm now working on getting the cvs version added and when that works llvm-gcc4 + EABI patch. I'll have to finish a project at the university first, but a llvm-gcc4 recipe should be ready for testing somewhere between easter and ELC2007. Any recommended testsuites I could run? regards, Koen [1] http://www.openembedded.org/filebrowser/org.openembedded.dev/packages/llvm -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.5 (Darwin) iD8DBQFGEVctMkyGM64RGpERApgVAKC7QElBNdoRnRr6kWIMCObKab+cowCfcdYI siQoxf2YONM1zd42dzKkivE=kUb+ -----END PGP SIGNATURE-----
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Lauro Ramos Venancio schreef:> Hi Koen, > > The process to build llvm-gcc as a crosscompiler is basically the same > as build a normal gcc as crosscompiler. The differences: you need a > LLVM installed (compiled for the host). You must configure llvm-gcc > with --enable-llvm. > > Problems: > - Today LLVM supports ARM/EABI, but llvm-gcc don't. You must apply the > patch: > http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20070319/046070.htmlThat doesn't apply anymore :( regards, Koen -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.5 (Darwin) iD8DBQFGEWPTMkyGM64RGpERAgzUAJoDlCPbR9t0U9S7BaC+db9SdByiZQCfRW7n MyGmdIjq5lot9V1czd1eZcs=rT0C -----END PGP SIGNATURE-----
> > - Today LLVM supports ARM/EABI, but llvm-gcc don't. You must apply the > > patch: > > http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20070319/046070.html > > That doesn't apply anymore :(You must use the llvm-gcc4 from the svn. It has some bug fixes that are important to ARM EABI and the patch should apply cleanly. Lauro
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Lauro Ramos Venancio schreef:> Hi Koen, > > The process to build llvm-gcc as a crosscompiler is basically the same > as build a normal gcc as crosscompiler. The differences: you need a > LLVM installed (compiled for the host). You must configure llvm-gcc > with --enable-llvm.grep llvm configure* doesn't return anything in trunk/, did I checkout[1] the wrong svn? regards, Koen [1] svn://anonsvn.opensource.apple.com/svn/llvm/trunk -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.5 (Darwin) iD8DBQFGE2eoMkyGM64RGpERAh4pAJ9VYr2XbnsGQuFJXsVXF0/TKUAlwACeMbCt WFL6OSSM1JTV0wYauDPheAI=/KyZ -----END PGP SIGNATURE-----