June 15, 2024, 10:17:53 AM

OlimexODS problems !

Started by anotherbrick, December 20, 2012, 06:31:39 PM

Previous topic - Next topic


I am trying to compile a C Program with OlimexODS since 1 month
the result is as follows:

if I link with arm-none-eabi-ld in Makefile it doesnot link with libgcc.a no matter what I do
I tried everything from copying the libgcc.a in project directory to using switches -lgcc and so on
no success
console output :
arm-none-eabi-ld -g -v -nostartfiles -T./lib/stm32f4xx_flash.ld -o ./main.out obj/main.o obj/system_stm32f4xx.o obj/stm32f4xx_gpio.o obj/stm32f4xx_rcc.o obj/stm32f4xx_tim.o obj/stm32f4xx_it.o obj/stm32f4xx_syscfg.o obj/stm32_eth.o obj/ethernet.o obj/clock-arch.o obj/timer.o obj/misc.o obj/uip.o obj/httpd.o obj/uip_arp.o obj/psock.o obj/httpd-fs.o obj/httpd-cgi.o obj/http-strings.o obj/syscall.o obj/startup_stm32f4xx.o libgcc.a
obj/main.o: In function `main':
GNU ld (GNU Binutils)
C:\OlimexODS\examples\STM32-E407_Ethernet/main.c:360: undefined reference to `memcpy'

if I link with arm-none-eabi-gcc it links however it produces code
which includes 32 bit libraries (ARM7/ARM9)
which when I download to the board causes hardfault

you can see following discussion in STM32 forum


I want ask
is there anybody who uses OlimexODS ?can he tell me how he compiles with libgcc.a library succesfully ?
what is the Makefile adjustments ?




From what I can see you're linking libgcc.a correctly, your issue is with the memcpy() function.
C:\OlimexODS\examples\STM32-E407_Ethernet/main.c:360: undefined reference to `memcpy'
Take a look here and see if this applies to your main.c file:

Best Regards,
Software developer at Olimex