Salome HOME
Remove CMake warnings: set-up cmake policies globally
authorvsr <vsr@opencascade.com>
Thu, 16 Apr 2020 16:47:26 +0000 (19:47 +0300)
committervsr <vsr@opencascade.com>
Thu, 16 Apr 2020 16:48:46 +0000 (19:48 +0300)
cmake/SalomeMacros.cmake

index d0ba8857d1536c77e4102bb2735c5f9d3d6884c4..ad57253a09e221f479db0e5a5da0b486273f0d28 100644 (file)
 # Author: A.Geay, V. Sandler, A. Bruneton
 #
 
+#----------------------------------------------------------------------------
+# Set-up global policies
+#----------------------------------------------------------------------------
+CMAKE_POLICY(SET CMP0003 NEW)   # Ensure proper linker behavior
+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
+
 #----------------------------------------------------------------------------
 # LIST_CONTAINS is a macro useful for determining whether a list has a 
 # particular entry