Skip to content

Commit

Permalink
COMP: Fix configuration warning setting CMP0074 to NEW
Browse files Browse the repository at this point in the history
This commit addresses the following warning:

  CMake Warning (dev) at UKFTractography.cmake:62 (find_package):
    Policy CMP0074 is not set: find_package uses <PackageName>_ROOT variables.
    Run "cmake --help-policy CMP0074" for policy details.  Use the cmake_policy
    command to set the policy and suppress this warning.

    CMake variable ZLIB_ROOT is set to:

      /path/to/zlib-install

    For compatibility, CMake is ignoring the variable.
  Call Stack (most recent call first):
    CMakeLists.txt:84 (include)
  This warning is for project developers.  Use -Wno-dev to suppress it.
  • Loading branch information
jcfr committed Apr 30, 2019
1 parent e333cae commit 4fb5db4
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
cmake_minimum_required(VERSION 3.5)

if(POLICY CMP0074)
cmake_policy(SET CMP0074 NEW) #3.12.0 `find_package()`` uses ``<PackageName>_ROOT`` variables.
endif()

#-----------------------------------------------------------------------------
# Enable C++11
#-----------------------------------------------------------------------------
Expand Down

0 comments on commit 4fb5db4

Please sign in to comment.