mirror of
https://github.com/espressif/esp-idf.git
synced 2026-06-01 02:26:32 +03:00
The cmakev2 build system may evaluate components recursively and all
components has to make sure all their variables are properly
initialized.
Fixes: a7115b6b36 ("refactor(jpeg): Split hal layer for jpeg")
Signed-off-by: Frantisek Hrbata <frantisek.hrbata@espressif.com>
23 lines
555 B
CMake
23 lines
555 B
CMake
idf_build_get_property(target IDF_TARGET)
|
|
if(${target} STREQUAL "linux")
|
|
return() # This component is not supported by the POSIX/Linux simulator
|
|
endif()
|
|
|
|
set(includes)
|
|
|
|
if(EXISTS "${CMAKE_CURRENT_LIST_DIR}/${target}/include")
|
|
list(APPEND includes "${target}/include")
|
|
endif()
|
|
list(APPEND includes "include")
|
|
|
|
set(srcs)
|
|
|
|
# JPEG related source files
|
|
if(CONFIG_SOC_JPEG_CODEC_SUPPORTED)
|
|
list(APPEND srcs "jpeg_hal.c")
|
|
endif()
|
|
|
|
idf_component_register(SRCS ${srcs}
|
|
INCLUDE_DIRS ${includes}
|
|
REQUIRES soc hal)
|