]> SALOME platform Git repositories - tools/configuration.git/commitdiff
Salome HOME
Fix errors when using CMake older than 3.12 V9_5_0rc1
authorvsr <vsr@opencascade.com>
Mon, 8 Jun 2020 09:10:44 +0000 (12:10 +0300)
committervsr <vsr@opencascade.com>
Mon, 8 Jun 2020 09:10:44 +0000 (12:10 +0300)
cmake/SalomeMacros.cmake

index 78ee4627df43a9b65f2ecd5536b606ccc8cc0df5..33078a936556b0642ecf2a84f7b8f3a3d9ddb42b 100644 (file)
@@ -27,7 +27,9 @@ IF(WIN32)
   CMAKE_POLICY(SET CMP0020 OLD) # Disable automatic linking to qtmain.lib
 ENDIF(WIN32)
 CMAKE_POLICY(SET CMP0053 NEW)   # For correct Qt 5 detection procedure
-CMAKE_POLICY(SET CMP0074 NEW)   # Use ROOT variables when detecting packages
+IF(CMAKE_VERSION VERSION_GREATER_EQUAL 3.12)
+  CMAKE_POLICY(SET CMP0074 NEW) # Use ROOT variables when detecting packages
+ENDIF()
 
 #----------------------------------------------------------------------------
 # LIST_CONTAINS is a macro useful for determining whether a list has a