Allow more generic firmware customization

This commit adds a new Kconfig setting CONFIG_CUSTOMIZATION. If enabled, the
subdirectory src/custom is added to the build. It can contain an own
CMakeLists.txt file to add several different C/C++ files.

Readme has been updated to explain also DTS overlays and custom prj.conf files.
This commit is contained in:
Martin Jäger
2020-06-04 11:50:09 +02:00
committed by Martin Jäger
parent 0e5e2f89b1
commit 7769e4063c
3 changed files with 56 additions and 6 deletions
+6
View File
@@ -40,6 +40,12 @@ target_sources(app PRIVATE
../src/ext/can_msg_queue.cpp
)
# Using this option enables user-specific customization of the firmware. The
# src/custom subfolder should have its own CMakeLists.txt file.
if(${CONFIG_CUSTOMIZATION})
add_subdirectory(../src/custom build/custom)
endif()
add_subdirectory(../lib/thingset build/thingset)
add_subdirectory(../lib/oled-display build/oled-display)
#add_subdirectory_ifdef(CONFIG_EXT_OLED_DISPLAY ../lib/oled-display)