Skip to content
  • Daniele E. Domenichelli's avatar
    Do not change minimum required version in modules · 81a3f228
    Daniele E. Domenichelli authored
    Some modules change CMake minimum required version when they are
    included. For example:
    
      cmake_minimum_required(VERSION 2.8.12)
      message("${CMAKE_MINIMUM_REQUIRED_VERSION}")
      include(CheckTypeSize)
      message("${CMAKE_MINIMUM_REQUIRED_VERSION}")
    
    will produce the following output:
    
      2.8.12
      2.6
    
    This patch ensures that when you include a CMake module the minimum
    required version and the policies set are left unchanged.
    
    Fixes Issue #14864
    81a3f228