Hi All, I tried build a version of LLVM pulled from the git repo on my raspberry pi. I got close to the finish line then: llvm[2]: Building Debug+Asserts Archive Library libLLVMDebugInfo.a make[2]: Leaving directory `/home/pi/llvm-git/lib/DebugInfo' make[1]: Leaving directory `/home/pi/llvm-git/lib' make[1]: Entering directory `/home/pi/llvm-git/tools/llvm-shlib' llvm[1]: Linking Debug+Asserts Shared Library libLLVM-3.2svn.so collect2: ld terminated with signal 9 [Killed] make[1]: *** [/home/pi/llvm-git/Debug+Asserts/lib/libLLVM-3.2svn.so] Error 1 make[1]: Leaving directory `/home/pi/llvm-git/tools/llvm-shlib' make: *** [all] Error 1 So it seems that ld ran out of memory. My build command was:> ./configure --enable-shared --enable-jit && makeSo I think this means I need to cross compile but this is something that I haven't ever done before so I could use some pointers. Is there a recipe for building LLVM for raspberry pi that someone can share or any pointers? Incase it matters the source OS is OS X Mountain Lion and I'm happy to use gcc/clang/whatever works. Thanks, Keith -- http://keithsheppard.name
On 01.09.2012, at 15:02, Keith Sheppard <keithshep at gmail.com> wrote:> Hi All, > > I tried build a version of LLVM pulled from the git repo on my > raspberry pi. I got close to the finish line then: > > llvm[2]: Building Debug+Asserts Archive Library libLLVMDebugInfo.a > make[2]: Leaving directory `/home/pi/llvm-git/lib/DebugInfo' > make[1]: Leaving directory `/home/pi/llvm-git/lib' > make[1]: Entering directory `/home/pi/llvm-git/tools/llvm-shlib' > llvm[1]: Linking Debug+Asserts Shared Library libLLVM-3.2svn.so > collect2: ld terminated with signal 9 [Killed] > make[1]: *** [/home/pi/llvm-git/Debug+Asserts/lib/libLLVM-3.2svn.so] Error 1 > make[1]: Leaving directory `/home/pi/llvm-git/tools/llvm-shlib' > make: *** [all] Error 1 > > So it seems that ld ran out of memory. My build command was: > >> ./configure --enable-shared --enable-jit && makeTry --enable-optimized, debug info makes linking on linux extremely memory-intensive. If that doesn't help you can try to disable targets you don't need, which should also make the linker's life easier. - Ben> > So I think this means I need to cross compile but this is something > that I haven't ever done before so I could use some pointers. Is there > a recipe for building LLVM for raspberry pi that someone can share or > any pointers? Incase it matters the source OS is OS X Mountain Lion > and I'm happy to use gcc/clang/whatever works. > > Thanks, Keith > > -- > > http://keithsheppard.name > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
That did it! It took about a full day to build but> ./configure --enable-shared --enable-jit --enable-targets=host-only --enable-optimized && makeseems to work. Thanks Ben On Sat, Sep 1, 2012 at 9:19 AM, Benjamin Kramer <benny.kra at gmail.com> wrote:> > On 01.09.2012, at 15:02, Keith Sheppard <keithshep at gmail.com> wrote: > >> Hi All, >> >> I tried build a version of LLVM pulled from the git repo on my >> raspberry pi. I got close to the finish line then: >> >> llvm[2]: Building Debug+Asserts Archive Library libLLVMDebugInfo.a >> make[2]: Leaving directory `/home/pi/llvm-git/lib/DebugInfo' >> make[1]: Leaving directory `/home/pi/llvm-git/lib' >> make[1]: Entering directory `/home/pi/llvm-git/tools/llvm-shlib' >> llvm[1]: Linking Debug+Asserts Shared Library libLLVM-3.2svn.so >> collect2: ld terminated with signal 9 [Killed] >> make[1]: *** [/home/pi/llvm-git/Debug+Asserts/lib/libLLVM-3.2svn.so] Error 1 >> make[1]: Leaving directory `/home/pi/llvm-git/tools/llvm-shlib' >> make: *** [all] Error 1 >> >> So it seems that ld ran out of memory. My build command was: >> >>> ./configure --enable-shared --enable-jit && make > > Try --enable-optimized, debug info makes linking on linux extremely memory-intensive. > > If that doesn't help you can try to disable targets you don't need, which should also make the linker's life easier. > > - Ben > >> >> So I think this means I need to cross compile but this is something >> that I haven't ever done before so I could use some pointers. Is there >> a recipe for building LLVM for raspberry pi that someone can share or >> any pointers? Incase it matters the source OS is OS X Mountain Lion >> and I'm happy to use gcc/clang/whatever works. >> >> Thanks, Keith >> >> -- >> >> http://keithsheppard.name >> _______________________________________________ >> LLVM Developers mailing list >> LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu >> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev >-- keithsheppard.name