Commit Graph

4 Commits

Author SHA1 Message Date
chao an 36039c8526 newlib/impure: declare thread specific file only if __NEWLIB__ is defined.
Signed-off-by: chao an <anchao@xiaomi.com>
2022-10-12 17:22:24 +08:00
chao an 83a3fd9780 newlib/impure: sync with newlib(4.2.0) reent update
arm-none-eabi-ld: nuttx/staging/libc.a(lib_impure.o):(.data.impure_data+0x4): undefined reference to `__sf'
arm-none-eabi-ld: nuttx/staging/libc.a(lib_impure.o):(.data.impure_data+0x8): undefined reference to `__sf'
arm-none-eabi-ld: nuttx/staging/libc.a(lib_impure.o):(.data.impure_data+0xc): undefined reference to `__sf'

Toolchain:
  Version: GNU Arm Embedded Toolchain to Version 11.3.Rel1(August 8, 2022)
  Tar:     arm-gnu-toolchain-11.3.rel1-x86_64-arm-none-eabi.tar.xz

Break change:
https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;h=b0cb9f85ca3626e0e68fd451c3090d253ceb4300

Signed-off-by: chao an <anchao@xiaomi.com>
2022-10-11 18:38:14 +08:00
Xiang Xiao 4e92e32d7b libc/impure: Fix the inconsistence from the different toolchain
some toolchain provider remove const qualifier from global_impure_ptr
(e.g. Espressif) but other provider keep it(e.g. ARM or Cadence), so
let's define const to empty macro to pass the compile and more safety.

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-07-22 11:02:48 +03:00
Xiang Xiao 4ae7f4c1f6 libs: Move libxx_impure.cxx from libs/libxx/ to libs/libc/misc/
to fix the gcov link error:
arm-none-eabi-ld: /home/xiaoxiang/vela/prebuilts/gcc/linux/arm/bin/../lib/gcc/arm-none-eabi/10.3.1/thumb/v7e-m/nofp/libgcov.a(_gcov.o): in function `gcov_error_exit':
libgcov-driver.c:(.text+0x7c): undefined reference to `_impure_ptr'
arm-none-eabi-ld: /home/xiaoxiang/vela/prebuilts/gcc/linux/arm/bin/../lib/gcc/arm-none-eabi/10.3.1/thumb/v7e-m/nofp/libgcov.a(_gcov.o): in function `get_gcov_error_file':
libgcov-driver.c:(.text+0x1e0): undefined reference to `_impure_ptr'
arm-none-eabi-ld: /home/xiaoxiang/vela/prebuilts/gcc/linux/arm/bin/../lib/gcc/arm-none-eabi/10.3.1/thumb/v7e-m/nofp/libgcov.a(_gcov.o): in function `gcov_exit_open_gcda_file.isra.0':
libgcov-driver.c:(.text+0x660): undefined reference to `_impure_ptr'

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-05-06 14:43:57 -03:00