Hi I am trying to cross compile llvm-gcc front for ARM target Followed below steps #../llvm-gcc-4.2-2.9.source/configure --program-prefix=llvm- --enable-llvm=/home/yuvraj/llvm/llvm-2.9 --enable-languages=c,c++ --target=arm-none-linux-gnueabi # make I am getting some kind of linker errors /opt/arm-2010.09/bin/arm-none-linux-gnueabi-ld: cannot find crtn.o: No such file or directory @ final stage. I copied crtn.o to current working directory. But getting same issue How do i resolve this issue? Thanks Yuvi R -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20110707/c07a988a/attachment.html>
Hi Yuvi,
crt{i,n,begin,end,0,1}.o are runtime objects that are OS-dependent. Are you
compiling for baremetal or arm-linux?
If baremetal, you'd need to put your core startup code in crt1.o, and
create stub objects for the rest so the linker doesn't complain (touch
test.c; clang -march=armv7 -c -o test.o test.c; cp test.o crt{i,n,begin,end}.o).
Cheers,
James
From: llvmdev-bounces at cs.uiuc.edu [mailto:llvmdev-bounces at cs.uiuc.edu] On
Behalf Of Yuvaraj Ragupathi
Sent: 07 July 2011 12:39
To: llvmdev at cs.uiuc.edu
Subject: [LLVMdev] llvm-gcc cross compiling for ARM
Hi
I am trying to cross compile llvm-gcc front for ARM target
Followed below steps
#../llvm-gcc-4.2-2.9.source/configure --program-prefix=llvm-
--enable-llvm=/home/yuvraj/llvm/llvm-2.9 --enable-languages=c,c++
--target=arm-none-linux-gnueabi
# make
I am getting some kind of linker errors
/opt/arm-2010.09/bin/arm-none-linux-gnueabi-ld: cannot find crtn.o: No such file
or directory
@ final stage.
I copied crtn.o to current working directory. But getting same issue
How do i resolve this issue?
Thanks
Yuvi R
-- IMPORTANT NOTICE: The contents of this email and any attachments are
confidential and may also be privileged. If you are not the intended recipient,
please notify the sender immediately and do not disclose the contents to any
other person, use it for any purpose, or store or copy the information in any
medium. Thank you.
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://lists.llvm.org/pipermail/llvm-dev/attachments/20110707/2d65351f/attachment.html>
Here is how I do it on x86-64 machine running Ubuntu-11.04:
1. install flex and bison
2. download arm-2011.03 from www.codesourcery.com and add to path (setenv
PATH ${PATH}:/home/dskhudia/projects/arm-2011.03/bin)
3. mkdir llvm-gcc-obj; cd llvm-gcc-obj
4. ../llvm-gcc-4.2-2.9.source/configure --target=arm-none-linux-gnueabi
--program-prefix=llvm-
--enable-llvm=/home/dskhudia/projects/llvm-2.9/obj-arm
--prefix=/home/dskhudia/projects/llvm-install-arm
--with-sysroot=/home/dskhudia/projects/arm-2011.03/arm-none-linux-gnueabi/libc
--with-gnu-ld=/home/dskhudia/projects/arm-2011.03/bin/arm-none-linux-gnueabi-ld
--with-gnu-as=/home/dskhudia/projects/arm-2011.03/bin/arm-none-linux-gnueabi-as
--with-gnu-ar=/home/dskhudia/projects/arm-2011.03/bin/arm-none-linux-gnueabi-ar
--disable-bootstrap -disable-optimized --disable-multilib --enable-checking
--disable-shared --enable-languages=c,c++
Hope that helps.
Daya
On Thu, Jul 7, 2011 at 7:38 AM, Yuvaraj Ragupathi <yuvaraj.addu at
gmail.com>wrote:
> Hi
>
> I am trying to cross compile llvm-gcc front for ARM target
>
> Followed below steps
>
>
> #../llvm-gcc-4.2-2.9.source/configure --program-prefix=llvm-
> --enable-llvm=/home/yuvraj/llvm/llvm-2.9 --enable-languages=c,c++
> --target=arm-none-linux-gnueabi
>
> # make
>
> I am getting some kind of linker errors
>
> /opt/arm-2010.09/bin/arm-none-linux-gnueabi-ld: cannot find crtn.o: No such
> file or directory
>
>
>
> @ final stage.
>
> I copied crtn.o to current working directory. But getting same issue
>
> How do i resolve this issue?
>
>
> Thanks
>
> Yuvi R
>
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://lists.llvm.org/pipermail/llvm-dev/attachments/20110707/964ab0f2/attachment.html>
Thanks for your reply I got error */bin/sh: build/genmodes: not found* I am trying to resolve it Thanks Yuvi R On Thu, Jul 7, 2011 at 8:10 PM, D S Khudia <daya.khudia at gmail.com> wrote:> Here is how I do it on x86-64 machine running Ubuntu-11.04: > > 1. install flex and bison > 2. download arm-2011.03 from www.codesourcery.com and add to path (setenv > PATH ${PATH}:/home/dskhudia/projects/arm-2011.03/bin) > 3. mkdir llvm-gcc-obj; cd llvm-gcc-obj > 4. ../llvm-gcc-4.2-2.9.source/configure --target=arm-none-linux-gnueabi > --program-prefix=llvm- > --enable-llvm=/home/dskhudia/projects/llvm-2.9/obj-arm > --prefix=/home/dskhudia/projects/llvm-install-arm > --with-sysroot=/home/dskhudia/projects/arm-2011.03/arm-none-linux-gnueabi/libc > --with-gnu-ld=/home/dskhudia/projects/arm-2011.03/bin/arm-none-linux-gnueabi-ld > --with-gnu-as=/home/dskhudia/projects/arm-2011.03/bin/arm-none-linux-gnueabi-as > --with-gnu-ar=/home/dskhudia/projects/arm-2011.03/bin/arm-none-linux-gnueabi-ar > --disable-bootstrap -disable-optimized --disable-multilib --enable-checking > --disable-shared --enable-languages=c,c++ > > Hope that helps. > Daya > > > On Thu, Jul 7, 2011 at 7:38 AM, Yuvaraj Ragupathi <yuvaraj.addu at gmail.com>wrote: > >> Hi >> >> I am trying to cross compile llvm-gcc front for ARM target >> >> Followed below steps >> >> >> #../llvm-gcc-4.2-2.9.source/configure --program-prefix=llvm- >> --enable-llvm=/home/yuvraj/llvm/llvm-2.9 --enable-languages=c,c++ >> --target=arm-none-linux-gnueabi >> >> # make >> >> I am getting some kind of linker errors >> >> /opt/arm-2010.09/bin/arm-none-linux-gnueabi-ld: cannot find crtn.o: No >> such file or directory >> >> >> >> @ final stage. >> >> I copied crtn.o to current working directory. But getting same issue >> >> How do i resolve this issue? >> >> >> Thanks >> >> Yuvi R >> >> _______________________________________________ >> LLVM Developers mailing list >> LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu >> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev >> >> >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20110708/b833b2ed/attachment.html>