Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
baselibc: Fix fflush duplicate error
This tries to fix error: Linking review/bin/targets/nordic_pca10056-auracast_usb/app/@apache-mynewt-nimble/apps/auracast_usb/auracast_usb.elf Error: Arm GNU Toolchain arm-none-eabi/13.2 Rel1/bin/../lib/gcc/arm-none-eabi/13.2.1/../../../../arm-none-eabi/bin/ld.exe: Arm GNU Toolchain arm-none-eabi/13.2 Rel1/bin/../lib/gcc/arm-none- eabi/13.2.1/thumb/v7e-m/nofp\libg.a(libc_a-fflush.o): in function `fflush': fflush.c:(.text.fflush+0x0): multiple definition of `fflush'; review/bin/targets/nordic_pca10056-auracast_usb/app/@apache-mynewt-core/libc/baselibc/@apache-mynewt-core_libc_baselibc.a(mynewt.o):review/repos/apache-mynewt-core/libc/baselibc/src/mynewt.c:54: first defined here fflush is not used anywhere in the code but for some reason gcc 12 and 13 complains about duplicate. When baselibc version of fflush is removed code compiles and links without problem and final elf does not have fflush from libc_a-fflush.o. Now fflush is weak so linker will take other version when needed. This is workaround till batter solution is found.
- Loading branch information