[PATCH] CMake: rework CMake minimum requirement check

yegorslists at googlemail.com yegorslists at googlemail.com
Wed Jun 4 02:13:39 PDT 2025


From: Yegor Yefremov <yegorslists at googlemail.com>

Check for the CMake minimum version only in the main
CMakeLists.txt as examples and lua are subdirectories
included from it.

Signed-off-by: Yegor Yefremov <yegorslists at googlemail.com>
---
 examples/CMakeLists.txt | 2 --
 lua/CMakeLists.txt      | 2 --
 2 files changed, 4 deletions(-)

diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt
index 04f18b0..9347ac2 100644
--- a/examples/CMakeLists.txt
+++ b/examples/CMakeLists.txt
@@ -1,5 +1,3 @@
-cmake_minimum_required(VERSION 2.6)
-
 IF (BUILD_EXAMPLES)
     PROJECT(ubox-examples C)
     ADD_DEFINITIONS(-O1 -Wall -Werror --std=gnu99 -g3)
diff --git a/lua/CMakeLists.txt b/lua/CMakeLists.txt
index 34c9ab1..104a56a 100644
--- a/lua/CMakeLists.txt
+++ b/lua/CMakeLists.txt
@@ -1,5 +1,3 @@
-cmake_minimum_required(VERSION 2.6)
-
 PROJECT(uloop C)
 
 SET(CMAKE_INSTALL_PREFIX /)
-- 
2.34.1




More information about the openwrt-devel mailing list