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

add -lgcc flag to fix "undefined reference to __aeabi_llsr" #156

Merged
merged 1 commit into from
Feb 6, 2019

Conversation

adhintz
Copy link
Contributor

@adhintz adhintz commented Feb 6, 2019

fixes commaai/openpilot#522

The sizes look fine:

make clean && make recover; ls -l obj/bootstub.panda.*

with this pull request (-Os and -lgcc)
   8024 Feb  5 21:57 obj/bootstub.panda.bin
 182460 Feb  5 21:57 obj/bootstub.panda.elf
  60272 Feb  5 21:57 obj/bootstub.panda.o

original before the -Os commit (-O2 and no -lgcc)
   8988 Feb  5 22:00 obj/bootstub.panda.bin
 187596 Feb  5 22:00 obj/bootstub.panda.elf
  68400 Feb  5 22:00 obj/bootstub.panda.o

However I'm not sure how to test bootstub beyond using it to flash a Panda and seeing if the Panda works.

Saw this fix suggested here: https://stackoverflow.com/questions/23410221/linking-libgcc-into-a-nostdlib-compilation

@rbiasini
Copy link
Contributor

rbiasini commented Feb 6, 2019

FYI, I've reverted -Os to -O2 for now. If this fixes the issue I'll put -Os back

@rbiasini rbiasini merged commit fd23383 into commaai:master Feb 6, 2019
@adhintz adhintz deleted the fixopt branch January 20, 2022 00:05
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 this pull request may close these issues.

panda "make recover" shows link error "undefined reference to __aeabi_llsr"
2 participants