Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

linker error in CUBe bootloader #26

Open
mahowi opened this issue Jul 9, 2019 · 2 comments · May be fixed by #35
Open

linker error in CUBe bootloader #26

mahowi opened this issue Jul 9, 2019 · 2 comments · May be fixed by #35

Comments

@mahowi
Copy link

mahowi commented Jul 9, 2019

When trying to compile the firmware for CUBe, compilation stops with a linker error at CUBe bootloader:
/usr/lib/gcc/arm-none-eabi/7.3.1/../../../arm-none-eabi/bin/ld: section .ARM.exidx LMA [0011ccf0,0011ccf7] overlaps section .relocate LMA [0011ccf0,0011d25f] collect2: error: ld returned 1 exit status make[3]: *** [Makefile:125: CUBE_BL.elf] Fehler 1

Compiler version: arm-none-eabi-gcc (15:7-2018-q2-6) 7.3.1 20180622 (release) [ARM/embedded-7-branch revision 261907]

@spezifanta
Copy link

I got the same error. I also tried using an Docker container as build environment:

git clone https://github.com/heliflieger/a-culfw.git
cd a-culfw
docker run -it --rm -v $(pwd):/code stronglytyped/arm-none-eabi-gcc

Inside the container I ran:

/code/culfw/Devices/CUBe
make

The Error:

arm-none-eabi-gcc  -L/arm-none-eabi/lib -Os -fno-isolate-erroneous-paths-dereference -o CUBE_BL.elf  
[...]
 ../../avr-uip/uip/uiplib.o -lc -lm -g -nostartfiles -Wl,--gc-sections -T"CUBE_BL_flash.lds"  -Xlinker -Map=CUBE_BL.map
/work/gcc-arm-none-eabi-9-2019-q4-major/bin/../lib/gcc/arm-none-eabi/9.2.1/../../../../arm-none-eabi/bin/ld: section .ARM.exidx LMA [000000000011c868,000000000011c86f] overlaps section .relocate LMA [000000000011c868,000000000011cdd7]
collect2: error: ld returned 1 exit status
Makefile:125: recipe for target 'CUBE_BL.elf' failed
make[1]: *** [CUBE_BL.elf] Error 1
make[1]: Leaving directory '/code/culfw/Devices/CUBe'
Makefile:97: recipe for target 'CUBE_BL' failed
make: *** [CUBE_BL] Error 2

@Scyten
Copy link

Scyten commented Oct 13, 2022

Solution but untested (according to this https://stackoverflow.com/questions/30778614/arm-none-eabi-ld-section-arm-exidx-overlaps-section-data)
replace CUBE_flash.lds and CUBE_BL_flash.lds with this:
CUBE_.zip
This avoids the linker error.

I have not tried this on my Max!Cube, yet!

If it works i will add a pull request!

@Scyten Scyten linked a pull request Oct 13, 2022 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants