File tree Expand file tree Collapse file tree 7 files changed +9
-21
lines changed Expand file tree Collapse file tree 7 files changed +9
-21
lines changed Original file line number Diff line number Diff line change @@ -2,8 +2,7 @@ cmake_minimum_required(VERSION 3.5)
2
2
3
3
if (NOT DEFINED PROJECT_NAME )
4
4
include ($ENV{IDF_PATH} /tools/cmake/project.cmake)
5
-
6
- list (APPEND EXTRA_COMPONENT_DIRS components/lvgl_esp32_drivers components/lvgl_esp32_drivers/lvgl_touch components/lvgl_esp32_drivers/lvgl_tft)
7
-
8
5
project (lvgl-demo)
9
- endif (NOT DEFINED PROJECT_NAME )
6
+ else ()
7
+ message (FATAL_ERROR "LV PORT ESP32: This must be a project's main CMakeLists.txt." )
8
+ endif ()
Original file line number Diff line number Diff line change 4
4
#
5
5
6
6
PROJECT_NAME := lvgl-demo
7
-
8
- # Add new components (source folders)
9
- EXTRA_COMPONENT_DIRS := components/lvgl_esp32_drivers/lvgl_tft
10
- EXTRA_COMPONENT_DIRS += components/lvgl_esp32_drivers/lvgl_touch
11
- # Must be before include $(IDF_PATH)/make/project.mk
12
- # $(PROJECT_PATH)/xxx didn't work -> use $(abspath xxx) instead
13
-
14
7
include $(IDF_PATH ) /make/project.mk
15
-
Original file line number Diff line number Diff line change @@ -6,4 +6,6 @@ idf_component_register(SRCS ${SOURCES}
6
6
INCLUDE_DIRS .
7
7
REQUIRES lvgl)
8
8
9
+ else ()
10
+ message (FATAL_ERROR "LVGL LV examples: ESP_PLATFORM is not defined. Try reinstalling ESP-IDF." )
9
11
endif ()
Original file line number Diff line number Diff line change 2
2
# Component Makefile
3
3
#
4
4
5
- CFLAGS += -DLV_CONF_INCLUDE_SIMPLE
5
+ CFLAGS += -DLV_LVGL_H_INCLUDE_SIMPLE
6
6
7
7
COMPONENT_SRCDIRS := lv_examples \
8
8
lv_examples/src/lv_demo_benchmark \
Original file line number Diff line number Diff line change 1
- set (SOURCES main.c)
2
- idf_component_register(SRCS ${SOURCES}
3
- INCLUDE_DIRS .)
4
-
5
- target_compile_definitions (${COMPONENT_LIB} PUBLIC "-DLV_LVGL_H_INCLUDE_SIMPLE" )
1
+ idf_component_register(SRCS main.c)
Original file line number Diff line number Diff line change 3
3
#
4
4
# (Uses default behaviour of compiling all source files in directory, adding 'include' to include path.)
5
5
6
- CFLAGS += -DLV_CONF_INCLUDE_SIMPLE
7
- CFLAGS += -DLV_LVGL_H_INCLUDE_SIMPLE
6
+ CFLAGS+ = -DLV_LVGL_H_INCLUDE_SIMPLE
Original file line number Diff line number Diff line change 21
21
#include "driver/gpio.h"
22
22
23
23
/* Littlevgl specific */
24
- #ifdef LV_CONF_INCLUDE_SIMPLE
24
+ #ifdef LV_LVGL_H_INCLUDE_SIMPLE
25
25
#include "lvgl.h"
26
26
#else
27
27
#include "lvgl/lvgl.h"
You can’t perform that action at this time.
0 commit comments