components/esp32-owb/CMakeLists.txt

changeset 72
acc1904cd70d
parent 15
83314e7b1b4a
--- a/components/esp32-owb/CMakeLists.txt	Tue Sep 26 14:56:04 2023 +0200
+++ b/components/esp32-owb/CMakeLists.txt	Tue Sep 26 14:57:18 2023 +0200
@@ -1,2 +1,12 @@
-idf_component_register(SRCS owb_rmt.c owb.c owb_gpio.c INCLUDE_DIRS include)
+if (NOT IDF_VERSION_MAJOR)
+  set(IDF_VERSION_MAJOR 3)
+endif()
 
+if (IDF_VERSION_MAJOR LESS 5)
+    message(FATAL_ERROR "Can't build: requires ESP-IDF version 5.0 or above.")
+endif()
+
+set(COMPONENT_ADD_INCLUDEDIRS include)
+set(COMPONENT_SRCS "owb.c" "owb_gpio.c" "owb_rmt.c")
+set(COMPONENT_REQUIRES "soc" "driver" "esp_rom")
+register_component()

mercurial