minor fixes
This commit is contained in:
parent
0b55ade07e
commit
6a6fdcf289
|
@ -84,22 +84,20 @@ if(CONFIG_LV_I2C)
|
||||||
list(APPEND SOURCES "lvgl_i2c/i2c_manager.c")
|
list(APPEND SOURCES "lvgl_i2c/i2c_manager.c")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if("${IDF_VERSION_MAJOR}.${IDF_VERSION_MINOR}" VERSION_GREATER_EQUAL "5.0")
|
||||||
|
idf_component_register( SRCS ${SOURCES}
|
||||||
|
INCLUDE_DIRS ${LVGL_INCLUDE_DIRS}
|
||||||
|
REQUIRES lvgl driver)
|
||||||
|
set(USE_PORT_TICK_PERIOD_MS)
|
||||||
|
else()
|
||||||
idf_component_register( SRCS ${SOURCES}
|
idf_component_register( SRCS ${SOURCES}
|
||||||
INCLUDE_DIRS ${LVGL_INCLUDE_DIRS}
|
INCLUDE_DIRS ${LVGL_INCLUDE_DIRS}
|
||||||
if(ESP_IDF_VERSION_MAJOR>=5)
|
REQUIRES lvgl)
|
||||||
REQUIRES lvgl driver
|
set(USE_PORT_TICK_RATE_MS)
|
||||||
else
|
endif()
|
||||||
REQUIRES lvgl
|
|
||||||
endif)
|
|
||||||
|
|
||||||
target_compile_definitions(${COMPONENT_LIB} PUBLIC "-DLV_LVGL_H_INCLUDE_SIMPLE")
|
target_compile_definitions(${COMPONENT_LIB} PUBLIC "-DLV_LVGL_H_INCLUDE_SIMPLE")
|
||||||
|
|
||||||
if(ESP_IDF_VERSION_MAJOR >= 5)
|
|
||||||
target_compile_definitions(${COMPONENT_LIB} PUBLIC "-USE_PORT_TICK_PERIOD_MS")
|
|
||||||
else()
|
|
||||||
target_compile_definitions(${COMPONENT_LIB} PUBLIC "-USE_PORT_TICK_RATE_MS")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
else()
|
else()
|
||||||
message(FATAL_ERROR "LVGL ESP32 drivers: ESP_PLATFORM is not defined. Try reinstalling ESP-IDF.")
|
message(FATAL_ERROR "LVGL ESP32 drivers: ESP_PLATFORM is not defined. Try reinstalling ESP-IDF.")
|
||||||
endif()
|
endif()
|
||||||
|
|
Loading…
Reference in a new issue