2018-01-19 05:22:08 +00:00
|
|
|
set(COMPONENT_SRCDIRS ".")
|
2018-01-12 02:49:13 +00:00
|
|
|
set(COMPONENT_ADD_INCLUDEDIRS platform_include include)
|
|
|
|
|
|
|
|
if(CONFIG_SPIRAM_CACHE_WORKAROUND)
|
2018-02-27 04:45:30 +00:00
|
|
|
set(LIBC c-psram-workaround)
|
|
|
|
set(LIBM m-psram-workaround)
|
2018-01-12 02:49:13 +00:00
|
|
|
else()
|
|
|
|
|
2018-02-27 04:45:30 +00:00
|
|
|
if(CONFIG_NEWLIB_NANO_FORMAT)
|
|
|
|
set(LIBC c_nano)
|
|
|
|
else()
|
|
|
|
set(LIBC c)
|
|
|
|
endif()
|
2018-01-12 02:49:13 +00:00
|
|
|
|
2018-02-27 04:45:30 +00:00
|
|
|
set(LIBM m)
|
|
|
|
endif()
|
2018-01-12 02:49:13 +00:00
|
|
|
|
|
|
|
register_component()
|
|
|
|
|
|
|
|
target_link_libraries(newlib "-L ${CMAKE_CURRENT_SOURCE_DIR}/lib")
|
|
|
|
target_link_libraries(newlib ${LIBC} ${LIBM})
|