This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: ld: target not found collect2: ld returned 1 exit status


5.5.2011 8:52, naga raj kirjoitti:

I have ported Gcc-4.6.0 to a embedded target.

Who then ported GNU binutils for this target? And why you haven't discussed with this person about which target options would be used and for what purposes?

For big endian( I made big-endian as default) it is working fine.

  But when I use -mlittle-endian flag, in compiler it is generating
error as ld: target  not found collect2: ld returned 1 exit status.

I would assume your GCC to give some option to the target 'ld' which it doesn't grok...

So in my attempts I have used -c -mlittle-endian flags in compilation

ex: zz-gcc -c -mlittle-endian abc.c

and I linked manually with -EL option then it is working fine.

ex: zz-ld -N -EL abc.o

What options your GCC is giving to the linker when you see them via? :

zz-gcc -v -mlittle-endian -o abc.x abc.c


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]