This is the mail archive of the ecos-discuss@sourceware.org mailing list for the eCos 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: Eclipse / CDT without Makefile Project


Mike

On 20/12/12 15:15, Michael Jones wrote:

> Thanks, now it is closer. I have provided the output showing the final failure:
> 
> /opt/ecos/gnutools/arm-eabi/lib/gcc/arm-eabi/4.6.3/../../../../arm-eabi/bin/ld: cannot find crt0.o: No such file or directory
> /opt/ecos/gnutools/arm-eabi/lib/gcc/arm-eabi/4.6.3/../../../../arm-eabi/bin/ld: cannot find -lg
> /opt/ecos/gnutools/arm-eabi/lib/gcc/arm-eabi/4.6.3/../../../../arm-eabi/bin/ld: cannot find -lc
> collect2: ld returned 1 exit status
> make: *** [Sources/hello.o] Error 1
> 
> 07:56:20 Build Finished (took 929ms)
> 
> What is interesting is that even with the -L option, it does not show up in the compile output.
> 
> The rule it makes in the makefile is
> 
> hello_world: $(OBJS) $(USER_OBJS)
> 	@echo 'Building target: $@'
> 	@echo 'Invoking: Cross GCC Linker'
> 	arm-eabi-gcc -nostartfiles -nodefaultlibs -nostdlib -static -mcpu=cortex-m3 -mthumb -Wl,--gc-sections -Wl,-static -Wl,-n -g -v -nostdlib -L../../ecos/TWR-K60D100M_install/lib -T../../ecos/TWR-K60D100M_install/lib/target.ld -o "hello_world" $(OBJS) $(USER_OBJS) $(LIBS)
> 	@echo 'Finished building target: $@'
> 	@echo ' '
> 
> Somehow it does not get passed on to the linker.

I believe your build is not getting as far as the above makefile rule.
You are missing the "-c" flag on your _compilation_ line, so GCC is
attempting to both compile and link (using a default linker script) the
first time it is invoked.

I hope this helps...

John Dallaway
eCos maintainer
http://www.dallaway.org.uk/john

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


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