Browse Source

#IQRV #comment [CMake] 添加控件的是否编译选项

gifur 3 năm trước cách đây
mục cha
commit
0e216d0665
2 tập tin đã thay đổi với 8 bổ sung1 xóa
  1. 6 1
      CMakeLists.txt
  2. 2 0
      addin/cmake/ConfigOptions.cmake

+ 6 - 1
CMakeLists.txt

@@ -515,7 +515,12 @@ if(BUILD_TOOLS)
 else()
 	message(WARNING "skipping Tool directory.")
 endif(BUILD_TOOLS)
-add_subdirectory(Plugins)
+if(BUILD_PLUGINS)
+	add_subdirectory(Plugins)
+else()
+	message(WARNING "skipping Plugins directory.")
+endif(BUILD_PLUGINS)
+
 if(BUILD_DEVADAPTER)
 	add_subdirectory(DevAdapter)
 else()

+ 2 - 0
addin/cmake/ConfigOptions.cmake

@@ -33,6 +33,8 @@ option(BUILD_MODULE "whether build entity module or not" ON)
 
 option(BUILD_TOOLS "whether build tools or not" ON)
 
+option(BUILD_PLUGINS "whether build plugins or not" ON)
+
 option(BUILD_DEVADAPTER "whether build device adapter or not" ON)
 
 option(WITH_LOCAL_DEVLIB "build dev adapter with local dependency libraries except conan" OFF)