summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
Diffstat (limited to 'Modules')
-rw-r--r--Modules/CMakeDetermineCompileFeatures.cmake12
-rw-r--r--Modules/CMakeDetermineCompilerABI.cmake12
-rw-r--r--Modules/CMakeDetermineCompilerId.cmake9
-rw-r--r--Modules/CMakeDetermineSystem.cmake2
-rw-r--r--Modules/CMakeGenericSystem.cmake8
-rw-r--r--Modules/CMakeGraphVizOptions.cmake146
-rw-r--r--Modules/CMakeTestCCompiler.cmake6
-rw-r--r--Modules/CMakeTestCSharpCompiler.cmake8
-rw-r--r--Modules/CMakeTestCUDACompiler.cmake6
-rw-r--r--Modules/CMakeTestCXXCompiler.cmake6
-rw-r--r--Modules/CMakeTestCompilerCommon.cmake11
-rw-r--r--Modules/CMakeTestFortranCompiler.cmake12
-rw-r--r--Modules/CMakeTestOBJCCompiler.cmake6
-rw-r--r--Modules/CMakeTestOBJCXXCompiler.cmake6
-rw-r--r--Modules/CMakeTestSwiftCompiler.cmake6
-rw-r--r--Modules/CPack.cmake2
-rw-r--r--Modules/CheckCSourceCompiles.cmake6
-rw-r--r--Modules/CheckCSourceRuns.cmake6
-rw-r--r--Modules/CheckCXXSourceCompiles.cmake6
-rw-r--r--Modules/CheckCXXSourceRuns.cmake6
-rw-r--r--Modules/CheckFortranFunctionExists.cmake17
-rw-r--r--Modules/CheckFortranSourceCompiles.cmake6
-rw-r--r--Modules/CheckFortranSourceRuns.cmake6
-rw-r--r--Modules/CheckFunctionExists.cmake6
-rw-r--r--Modules/CheckIncludeFile.cmake6
-rw-r--r--Modules/CheckIncludeFileCXX.cmake6
-rw-r--r--Modules/CheckIncludeFiles.cmake6
-rw-r--r--Modules/CheckLanguage.cmake6
-rw-r--r--Modules/CheckLibraryExists.cmake6
-rw-r--r--Modules/CheckOBJCSourceCompiles.cmake6
-rw-r--r--Modules/CheckOBJCSourceRuns.cmake6
-rw-r--r--Modules/CheckOBJCXXSourceCompiles.cmake6
-rw-r--r--Modules/CheckOBJCXXSourceRuns.cmake6
-rw-r--r--Modules/CheckPrototypeDefinition.cmake7
-rw-r--r--Modules/CheckSymbolExists.cmake6
-rw-r--r--Modules/CheckTypeSize.cmake6
-rw-r--r--Modules/CheckVariableExists.cmake6
-rw-r--r--Modules/Compiler/NAG-Fortran.cmake6
-rw-r--r--Modules/CompilerId/VS-10.vcxproj.in2
-rw-r--r--Modules/ExternalProject.cmake27
-rw-r--r--Modules/FindCUDA.cmake9
-rw-r--r--Modules/FindCURL.cmake28
-rw-r--r--Modules/FindDCMTK.cmake6
-rw-r--r--Modules/FindMFC.cmake6
-rw-r--r--Modules/FindPython/Support.cmake50
-rw-r--r--Modules/FindThreads.cmake6
-rw-r--r--Modules/FindwxWidgets.cmake10
-rw-r--r--Modules/FortranCInterface.cmake6
-rw-r--r--Modules/FortranCInterface/Detect.cmake6
-rw-r--r--Modules/Internal/CPack/NSIS.template.in8
-rw-r--r--Modules/Platform/Android-Clang.cmake8
-rw-r--r--Modules/Platform/Android-Determine.cmake6
-rw-r--r--Modules/Platform/Android-Initialize.cmake6
-rw-r--r--Modules/Platform/Android.cmake5
-rw-r--r--Modules/Platform/Android/Determine-Compiler.cmake10
-rw-r--r--Modules/Platform/Apple-GNU.cmake12
-rw-r--r--Modules/TestBigEndian.cmake17
-rw-r--r--Modules/TestCXXAcceptsFlag.cmake6
-rw-r--r--Modules/TestForANSIForScope.cmake6
-rw-r--r--Modules/TestForSSTREAM.cmake6
-rw-r--r--Modules/TestForSTDNamespace.cmake6
61 files changed, 423 insertions, 231 deletions
diff --git a/Modules/CMakeDetermineCompileFeatures.cmake b/Modules/CMakeDetermineCompileFeatures.cmake
index 01a81a1..6adebae 100644
--- a/Modules/CMakeDetermineCompileFeatures.cmake
+++ b/Modules/CMakeDetermineCompileFeatures.cmake
@@ -5,7 +5,7 @@
function(cmake_determine_compile_features lang)
if(lang STREQUAL C AND COMMAND cmake_record_c_compile_features)
- message(STATUS "Detecting ${lang} compile features")
+ message(CHECK_START "Detecting ${lang} compile features")
set(CMAKE_C90_COMPILE_FEATURES)
set(CMAKE_C99_COMPILE_FEATURES)
@@ -16,7 +16,7 @@ function(cmake_determine_compile_features lang)
cmake_record_c_compile_features()
if(NOT _result EQUAL 0)
- message(STATUS "Detecting ${lang} compile features - failed")
+ message(CHECK_FAIL "failed")
return()
endif()
@@ -40,10 +40,10 @@ function(cmake_determine_compile_features lang)
set(CMAKE_C99_COMPILE_FEATURES ${CMAKE_C99_COMPILE_FEATURES} PARENT_SCOPE)
set(CMAKE_C11_COMPILE_FEATURES ${CMAKE_C11_COMPILE_FEATURES} PARENT_SCOPE)
- message(STATUS "Detecting ${lang} compile features - done")
+ message(CHECK_PASS "done")
elseif(lang STREQUAL CXX AND COMMAND cmake_record_cxx_compile_features)
- message(STATUS "Detecting ${lang} compile features")
+ message(CHECK_START "Detecting ${lang} compile features")
set(CMAKE_CXX98_COMPILE_FEATURES)
set(CMAKE_CXX11_COMPILE_FEATURES)
@@ -56,7 +56,7 @@ function(cmake_determine_compile_features lang)
cmake_record_cxx_compile_features()
if(NOT _result EQUAL 0)
- message(STATUS "Detecting ${lang} compile features - failed")
+ message(CHECK_FAIL "failed")
return()
endif()
@@ -90,7 +90,7 @@ function(cmake_determine_compile_features lang)
set(CMAKE_CXX17_COMPILE_FEATURES ${CMAKE_CXX17_COMPILE_FEATURES} PARENT_SCOPE)
set(CMAKE_CXX20_COMPILE_FEATURES ${CMAKE_CXX20_COMPILE_FEATURES} PARENT_SCOPE)
- message(STATUS "Detecting ${lang} compile features - done")
+ message(CHECK_PASS "done")
endif()
endfunction()
diff --git a/Modules/CMakeDetermineCompilerABI.cmake b/Modules/CMakeDetermineCompilerABI.cmake
index 06f3ba2..c5611b5 100644
--- a/Modules/CMakeDetermineCompilerABI.cmake
+++ b/Modules/CMakeDetermineCompilerABI.cmake
@@ -12,7 +12,7 @@ include(CMakeTestCompilerCommon)
function(CMAKE_DETERMINE_COMPILER_ABI lang src)
if(NOT DEFINED CMAKE_${lang}_ABI_COMPILED)
- message(STATUS "Detecting ${lang} compiler ABI info")
+ message(CHECK_START "Detecting ${lang} compiler ABI info")
# Compile the ABI identification source.
set(BIN "${CMAKE_PLATFORM_INFO_DIR}/CMakeDetermineCompilerABI_${lang}.bin")
@@ -66,7 +66,7 @@ function(CMAKE_DETERMINE_COMPILER_ABI lang src)
# Load the resulting information strings.
if(CMAKE_${lang}_ABI_COMPILED AND NOT _copy_error)
- message(STATUS "Detecting ${lang} compiler ABI info - done")
+ message(CHECK_PASS "done")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Detecting ${lang} compiler ABI info compiled with the following output:\n${OUTPUT}\n\n")
file(STRINGS "${BIN}" ABI_STRINGS LIMIT_COUNT 2 REGEX "INFO:[A-Za-z0-9_]+\\[[^]]*\\]")
@@ -124,8 +124,7 @@ function(CMAKE_DETERMINE_COMPILER_ABI lang src)
# a try-compile
if("${lang}" MATCHES "Fortran"
AND "${CMAKE_GENERATOR}" MATCHES "Visual Studio")
- set(_desc "Determine Intel Fortran Compiler Implicit Link Path")
- message(STATUS "${_desc}")
+ message(CHECK_START "Determine Intel Fortran Compiler Implicit Link Path")
# Build a sample project which reports symbols.
try_compile(IFORT_LIB_PATH_COMPILED
${CMAKE_BINARY_DIR}/CMakeFiles/IntelVSImplicitPath
@@ -138,8 +137,7 @@ function(CMAKE_DETERMINE_COMPILER_ABI lang src)
"${CMAKE_BINARY_DIR}/CMakeFiles/IntelVSImplicitPath/output.txt"
"${_output}")
include(${CMAKE_BINARY_DIR}/CMakeFiles/IntelVSImplicitPath/output.cmake OPTIONAL)
- set(_desc "Determine Intel Fortran Compiler Implicit Link Path -- done")
- message(STATUS "${_desc}")
+ message(CHECK_PASS "done")
endif()
# Implicit link libraries cannot be used explicitly for multiple
@@ -166,7 +164,7 @@ function(CMAKE_DETERMINE_COMPILER_ABI lang src)
endif()
else()
- message(STATUS "Detecting ${lang} compiler ABI info - failed")
+ message(CHECK_FAIL "failed")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Detecting ${lang} compiler ABI info failed to compile with the following output:\n${OUTPUT}\n${_copy_error}\n\n")
endif()
diff --git a/Modules/CMakeDetermineCompilerId.cmake b/Modules/CMakeDetermineCompilerId.cmake
index 908e530..f7ef755 100644
--- a/Modules/CMakeDetermineCompilerId.cmake
+++ b/Modules/CMakeDetermineCompilerId.cmake
@@ -317,6 +317,15 @@ Id flags: ${testflags} ${CMAKE_${lang}_COMPILER_ID_FLAGS_ALWAYS}
if(CMAKE_VS_WINDOWS_TARGET_PLATFORM_VERSION)
set(id_WindowsTargetPlatformVersion "<WindowsTargetPlatformVersion>${CMAKE_VS_WINDOWS_TARGET_PLATFORM_VERSION}</WindowsTargetPlatformVersion>")
endif()
+ if(CMAKE_VS_PLATFORM_TOOLSET_VCTARGETS_CUSTOM_DIR)
+ set(id_ToolsetVCTargetsDir "<VCTargetsPath>${CMAKE_VS_PLATFORM_TOOLSET_VCTARGETS_CUSTOM_DIR}</VCTargetsPath>")
+ endif()
+ set(id_CustomGlobals "")
+ foreach(pair IN LISTS CMAKE_VS_GLOBALS)
+ if("${pair}" MATCHES "([^=]+)=(.*)$")
+ string(APPEND id_CustomGlobals "<${CMAKE_MATCH_1}>${CMAKE_MATCH_2}</${CMAKE_MATCH_1}>\n ")
+ endif()
+ endforeach()
if(id_platform STREQUAL ARM64)
set(id_WindowsSDKDesktopARMSupport "<WindowsSDKDesktopARM64Support>true</WindowsSDKDesktopARM64Support>")
elseif(id_platform STREQUAL ARM)
diff --git a/Modules/CMakeDetermineSystem.cmake b/Modules/CMakeDetermineSystem.cmake
index dc208c6..f3ec4da 100644
--- a/Modules/CMakeDetermineSystem.cmake
+++ b/Modules/CMakeDetermineSystem.cmake
@@ -43,7 +43,7 @@ if(CMAKE_HOST_UNIX)
else()
exec_program(${CMAKE_UNAME} ARGS -r OUTPUT_VARIABLE CMAKE_HOST_SYSTEM_VERSION)
endif()
- if(CMAKE_HOST_SYSTEM_NAME MATCHES "Linux|CYGWIN.*|Darwin|^GNU$")
+ if(CMAKE_HOST_SYSTEM_NAME MATCHES "Linux|CYGWIN.*|Darwin|^GNU$|Android")
exec_program(${CMAKE_UNAME} ARGS -m OUTPUT_VARIABLE CMAKE_HOST_SYSTEM_PROCESSOR
RETURN_VALUE val)
if(CMAKE_HOST_SYSTEM_NAME STREQUAL "Darwin" AND
diff --git a/Modules/CMakeGenericSystem.cmake b/Modules/CMakeGenericSystem.cmake
index 77d8cfd..7efe5c4 100644
--- a/Modules/CMakeGenericSystem.cmake
+++ b/Modules/CMakeGenericSystem.cmake
@@ -51,16 +51,16 @@ if(CMAKE_GENERATOR MATCHES "Make")
set_property(GLOBAL PROPERTY TARGET_MESSAGES ${CMAKE_TARGET_MESSAGES})
endif()
if(CMAKE_GENERATOR MATCHES "Unix Makefiles")
- set(CMAKE_EXPORT_COMPILE_COMMANDS OFF CACHE BOOL
- "Enable/Disable output of compile commands during generation."
+ set(CMAKE_EXPORT_COMPILE_COMMANDS "$ENV{CMAKE_EXPORT_COMPILE_COMMANDS}"
+ CACHE BOOL "Enable/Disable output of compile commands during generation."
)
mark_as_advanced(CMAKE_EXPORT_COMPILE_COMMANDS)
endif()
endif()
if(CMAKE_GENERATOR MATCHES "Ninja")
- set(CMAKE_EXPORT_COMPILE_COMMANDS OFF CACHE BOOL
- "Enable/Disable output of compile commands during generation."
+ set(CMAKE_EXPORT_COMPILE_COMMANDS "$ENV{CMAKE_EXPORT_COMPILE_COMMANDS}"
+ CACHE BOOL "Enable/Disable output of compile commands during generation."
)
mark_as_advanced(CMAKE_EXPORT_COMPILE_COMMANDS)
endif()
diff --git a/Modules/CMakeGraphVizOptions.cmake b/Modules/CMakeGraphVizOptions.cmake
index 1911e73..be4a3be 100644
--- a/Modules/CMakeGraphVizOptions.cmake
+++ b/Modules/CMakeGraphVizOptions.cmake
@@ -5,119 +5,145 @@
CMakeGraphVizOptions
--------------------
-The builtin graphviz support of CMake.
+The builtin Graphviz support of CMake.
-Variables specific to the graphviz support
-^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+Generating Graphviz files
+^^^^^^^^^^^^^^^^^^^^^^^^^
-CMake
-can generate `graphviz <http://www.graphviz.org/>`_ files, showing the dependencies between the
-targets in a project and also external libraries which are linked
-against. When CMake is run with the ``--graphviz=foo.dot`` option, it will
-produce:
+CMake can generate `Graphviz <https://www.graphviz.org/>`_ files showing the
+dependencies between the targets in a project, as well as external libraries
+which are linked against.
-* a ``foo.dot`` file showing all dependencies in the project
-* a ``foo.dot.<target>`` file for each target, file showing on which other targets the respective target depends
-* a ``foo.dot.<target>.dependers`` file, showing which other targets depend on the respective target
+When running CMake with the ``--graphviz=foo.dot`` option, it produces:
-The different dependency types ``PUBLIC``, ``PRIVATE`` and ``INTERFACE``
-are represented as solid, dashed and dotted edges.
+* a ``foo.dot`` file, showing all dependencies in the project
+* a ``foo.dot.<target>`` file for each target, showing on which other targets
+ it depends
+* a ``foo.dot.<target>.dependers`` file for each target, showing which other
+ targets depend on it
-This can result in huge graphs. Using the file
-``CMakeGraphVizOptions.cmake`` the look and content of the generated
-graphs can be influenced. This file is searched first in
-:variable:`CMAKE_BINARY_DIR` and then in :variable:`CMAKE_SOURCE_DIR`. If found, it is
-read and the variables set in it are used to adjust options for the
-generated graphviz files.
+Those .dot files can be converted to images using the *dot* command from the
+Graphviz package:
-.. variable:: GRAPHVIZ_GRAPH_TYPE
+.. code-block:: shell
- The graph type.
+ dot -Tpng -o foo.png foo.dot
- * Mandatory : NO
- * Default : "digraph"
+The different dependency types ``PUBLIC``, ``INTERFACE`` and ``PRIVATE``
+are represented as solid, dashed and dotted edges.
- Valid graph types are:
+Variables specific to the Graphviz support
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
- * "graph" : Nodes are joined with lines
- * "digraph" : Nodes are joined with arrows showing direction
- * "strict graph" : Like "graph" but max one line between each node
- * "strict digraph" : Like "graph" but max one line between each node in each direction
+The resulting graphs can be huge. The look and content of the generated graphs
+can be controlled using the file ``CMakeGraphVizOptions.cmake``. This file is
+first searched in :variable:`CMAKE_BINARY_DIR`, and then in
+:variable:`CMAKE_SOURCE_DIR`. If found, the variables set in it are used to
+adjust options for the generated Graphviz files.
.. variable:: GRAPHVIZ_GRAPH_NAME
The graph name.
- * Mandatory : NO
- * Default : "GG"
+ * Mandatory: NO
+ * Default: value of :variable:`CMAKE_PROJECT_NAME`
.. variable:: GRAPHVIZ_GRAPH_HEADER
- The header written at the top of the graphviz file.
+ The header written at the top of the Graphviz files.
- * Mandatory : NO
- * Default : "node [n fontsize = "12"];"
+ * Mandatory: NO
+ * Default: "node [ fontsize = "12" ];"
.. variable:: GRAPHVIZ_NODE_PREFIX
- The prefix for each node in the graphviz file.
+ The prefix for each node in the Graphviz files.
- * Mandatory : NO
- * Default : "node"
+ * Mandatory: NO
+ * Default: "node"
.. variable:: GRAPHVIZ_EXECUTABLES
- Set this to FALSE to exclude executables from the generated graphs.
+ Set to FALSE to exclude executables from the generated graphs.
- * Mandatory : NO
- * Default : TRUE
+ * Mandatory: NO
+ * Default: TRUE
.. variable:: GRAPHVIZ_STATIC_LIBS
- Set this to FALSE to exclude static libraries from the generated graphs.
+ Set to FALSE to exclude static libraries from the generated graphs.
- * Mandatory : NO
- * Default : TRUE
+ * Mandatory: NO
+ * Default: TRUE
.. variable:: GRAPHVIZ_SHARED_LIBS
- Set this to FALSE to exclude shared libraries from the generated graphs.
+ Set to FALSE to exclude shared libraries from the generated graphs.
- * Mandatory : NO
- * Default : TRUE
+ * Mandatory: NO
+ * Default: TRUE
.. variable:: GRAPHVIZ_MODULE_LIBS
- Set this to FALSE to exclude module libraries from the generated graphs.
+ Set to FALSE to exclude module libraries from the generated graphs.
+
+ * Mandatory: NO
+ * Default: TRUE
+
+.. variable:: GRAPHVIZ_INTERFACE_LIBS
+
+ Set to FALSE to exclude interface libraries from the generated graphs.
+
+ * Mandatory: NO
+ * Default: TRUE
- * Mandatory : NO
- * Default : TRUE
+.. variable:: GRAPHVIZ_OBJECT_LIBS
+
+ Set to FALSE to exclude object libraries from the generated graphs.
+
+ * Mandatory: NO
+ * Default: TRUE
+
+.. variable:: GRAPHVIZ_UNKNOWN_LIBS
+
+ Set to FALSE to exclude unknown libraries from the generated graphs.
+
+ * Mandatory: NO
+ * Default: TRUE
.. variable:: GRAPHVIZ_EXTERNAL_LIBS
- Set this to FALSE to exclude external libraries from the generated graphs.
+ Set to FALSE to exclude external libraries from the generated graphs.
+
+ * Mandatory: NO
+ * Default: TRUE
+
+.. variable:: GRAPHVIZ_CUSTOM_TARGETS
+
+ Set to TRUE to include custom targets in the generated graphs.
- * Mandatory : NO
- * Default : TRUE
+ * Mandatory: NO
+ * Default: FALSE
.. variable:: GRAPHVIZ_IGNORE_TARGETS
- A list of regular expressions for ignoring targets.
+ A list of regular expressions for names of targets to exclude from the
+ generated graphs.
- * Mandatory : NO
- * Default : empty
+ * Mandatory: NO
+ * Default: empty
.. variable:: GRAPHVIZ_GENERATE_PER_TARGET
- Set this to FALSE to exclude per target graphs ``foo.dot.<target>``.
+ Set to FALSE to not generate per-target graphs ``foo.dot.<target>``.
- * Mandatory : NO
- * Default : TRUE
+ * Mandatory: NO
+ * Default: TRUE
.. variable:: GRAPHVIZ_GENERATE_DEPENDERS
- Set this to FALSE to exclude depender graphs ``foo.dot.<target>.dependers``.
+ Set to FALSE to not generate depender graphs ``foo.dot.<target>.dependers``.
- * Mandatory : NO
- * Default : TRUE
+ * Mandatory: NO
+ * Default: TRUE
#]=======================================================================]
diff --git a/Modules/CMakeTestCCompiler.cmake b/Modules/CMakeTestCCompiler.cmake
index 7bf6fde..eadea89 100644
--- a/Modules/CMakeTestCCompiler.cmake
+++ b/Modules/CMakeTestCCompiler.cmake
@@ -27,7 +27,7 @@ unset(CMAKE_C_COMPILER_WORKS CACHE)
# is set and cmake stops processing commands and will not generate
# any makefiles or projects.
if(NOT CMAKE_C_COMPILER_WORKS)
- PrintTestCompilerStatus("C" "")
+ PrintTestCompilerStatus("C")
__TestCompiler_setTryCompileTargetType()
file(WRITE ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/testCCompiler.c
"#ifdef __cplusplus\n"
@@ -52,7 +52,7 @@ if(NOT CMAKE_C_COMPILER_WORKS)
endif()
if(NOT CMAKE_C_COMPILER_WORKS)
- PrintTestCompilerStatus("C" " -- broken")
+ PrintTestCompilerResult(CHECK_FAIL "broken")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if the C compiler works failed with "
"the following output:\n${__CMAKE_C_COMPILER_OUTPUT}\n\n")
@@ -63,7 +63,7 @@ if(NOT CMAKE_C_COMPILER_WORKS)
"CMake will not be able to correctly generate this project.")
else()
if(C_TEST_WAS_RUN)
- PrintTestCompilerStatus("C" " -- works")
+ PrintTestCompilerResult(CHECK_PASS "works")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the C compiler works passed with "
"the following output:\n${__CMAKE_C_COMPILER_OUTPUT}\n\n")
diff --git a/Modules/CMakeTestCSharpCompiler.cmake b/Modules/CMakeTestCSharpCompiler.cmake
index 6715c30..1119a45 100644
--- a/Modules/CMakeTestCSharpCompiler.cmake
+++ b/Modules/CMakeTestCSharpCompiler.cmake
@@ -20,7 +20,9 @@ set(test_compile_file "${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/test
# is set and cmake stops processing commands and will not generate
# any makefiles or projects.
if(NOT CMAKE_CSharp_COMPILER_WORKS)
- PrintTestCompilerStatus("C#" "${CMAKE_CSharp_COMPILER}")
+ # Don't call PrintTestCompilerStatus() because the "C#" we want to pass
+ # as the LANG doesn't match with the variable name "CMAKE_CSharp_COMPILER"
+ message(CHECK_START "Check for working C# compiler: ${CMAKE_CSharp_COMPILER}")
file(WRITE "${test_compile_file}"
"namespace Test {"
" public class CSharp {"
@@ -38,7 +40,7 @@ if(NOT CMAKE_CSharp_COMPILER_WORKS)
endif()
if(NOT CMAKE_CSharp_COMPILER_WORKS)
- PrintTestCompilerStatus("C#" "${CMAKE_CSharp_COMPILER} -- broken")
+ PrintTestCompilerResult(CHECK_FAIL "broken")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if the C# compiler works failed with "
"the following output:\n${__CMAKE_CSharp_COMPILER_OUTPUT}\n\n")
@@ -49,7 +51,7 @@ if(NOT CMAKE_CSharp_COMPILER_WORKS)
"CMake will not be able to correctly generate this project.")
else()
if(CSharp_TEST_WAS_RUN)
- PrintTestCompilerStatus("C#" "${CMAKE_CSharp_COMPILER} -- works")
+ PrintTestCompilerResult(CHECK_PASS "works")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the C# compiler works passed with "
"the following output:\n${__CMAKE_CSharp_COMPILER_OUTPUT}\n\n")
diff --git a/Modules/CMakeTestCUDACompiler.cmake b/Modules/CMakeTestCUDACompiler.cmake
index f0454da..c145813 100644
--- a/Modules/CMakeTestCUDACompiler.cmake
+++ b/Modules/CMakeTestCUDACompiler.cmake
@@ -20,7 +20,7 @@ unset(CMAKE_CUDA_COMPILER_WORKS CACHE)
# is set and cmake stops processing commands and will not generate
# any makefiles or projects.
if(NOT CMAKE_CUDA_COMPILER_WORKS)
- PrintTestCompilerStatus("CUDA" "")
+ PrintTestCompilerStatus("CUDA")
file(WRITE ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/main.cu
"#ifndef __CUDACC__\n"
"# error \"The CMAKE_CUDA_COMPILER is set to an invalid CUDA compiler\"\n"
@@ -38,7 +38,7 @@ if(NOT CMAKE_CUDA_COMPILER_WORKS)
endif()
if(NOT CMAKE_CUDA_COMPILER_WORKS)
- PrintTestCompilerStatus("CUDA" " -- broken")
+ PrintTestCompilerResult(CHECK_FAIL "broken")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if the CUDA compiler works failed with "
"the following output:\n${__CMAKE_CUDA_COMPILER_OUTPUT}\n\n")
@@ -49,7 +49,7 @@ if(NOT CMAKE_CUDA_COMPILER_WORKS)
"CMake will not be able to correctly generate this project.")
else()
if(CUDA_TEST_WAS_RUN)
- PrintTestCompilerStatus("CUDA" " -- works")
+ PrintTestCompilerResult(CHECK_PASS "works")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the CUDA compiler works passed with "
"the following output:\n${__CMAKE_CUDA_COMPILER_OUTPUT}\n\n")
diff --git a/Modules/CMakeTestCXXCompiler.cmake b/Modules/CMakeTestCXXCompiler.cmake
index 7e595b7..bd42153 100644
--- a/Modules/CMakeTestCXXCompiler.cmake
+++ b/Modules/CMakeTestCXXCompiler.cmake
@@ -27,7 +27,7 @@ unset(CMAKE_CXX_COMPILER_WORKS CACHE)
# is set and cmake stops processing commands and will not generate
# any makefiles or projects.
if(NOT CMAKE_CXX_COMPILER_WORKS)
- PrintTestCompilerStatus("CXX" "")
+ PrintTestCompilerStatus("CXX")
__TestCompiler_setTryCompileTargetType()
file(WRITE ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/testCXXCompiler.cxx
"#ifndef __cplusplus\n"
@@ -45,7 +45,7 @@ if(NOT CMAKE_CXX_COMPILER_WORKS)
endif()
if(NOT CMAKE_CXX_COMPILER_WORKS)
- PrintTestCompilerStatus("CXX" " -- broken")
+ PrintTestCompilerResult(CHECK_FAIL "broken")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if the CXX compiler works failed with "
"the following output:\n${__CMAKE_CXX_COMPILER_OUTPUT}\n\n")
@@ -56,7 +56,7 @@ if(NOT CMAKE_CXX_COMPILER_WORKS)
"CMake will not be able to correctly generate this project.")
else()
if(CXX_TEST_WAS_RUN)
- PrintTestCompilerStatus("CXX" " -- works")
+ PrintTestCompilerResult(CHECK_PASS "works")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the CXX compiler works passed with "
"the following output:\n${__CMAKE_CXX_COMPILER_OUTPUT}\n\n")
diff --git a/Modules/CMakeTestCompilerCommon.cmake b/Modules/CMakeTestCompilerCommon.cmake
index 6ee5175..da7c007 100644
--- a/Modules/CMakeTestCompilerCommon.cmake
+++ b/Modules/CMakeTestCompilerCommon.cmake
@@ -2,8 +2,15 @@
# file Copyright.txt or https://cmake.org/licensing for details.
-function(PrintTestCompilerStatus LANG MSG)
- message(STATUS "Check for working ${LANG} compiler: ${CMAKE_${LANG}_COMPILER}${MSG}")
+function(PrintTestCompilerStatus LANG)
+ # ARGN shouldn't be needed now, but it is there to preserve backward
+ # compatibility in case this function is called from project code or
+ # custom toolchains (they shouldn't, but we can easily support it)
+ message(CHECK_START "Check for working ${LANG} compiler: ${CMAKE_${LANG}_COMPILER}${ARGN}")
+endfunction()
+
+function(PrintTestCompilerResult TYPE MSG)
+ message(${TYPE} "${MSG}")
endfunction()
# if required set the target type if not already explicitly set
diff --git a/Modules/CMakeTestFortranCompiler.cmake b/Modules/CMakeTestFortranCompiler.cmake
index e9860e9..7461f9c 100644
--- a/Modules/CMakeTestFortranCompiler.cmake
+++ b/Modules/CMakeTestFortranCompiler.cmake
@@ -21,7 +21,7 @@ unset(CMAKE_Fortran_COMPILER_WORKS CACHE)
# is set and cmake stops processing commands and will not generate
# any makefiles or projects.
if(NOT CMAKE_Fortran_COMPILER_WORKS)
- PrintTestCompilerStatus("Fortran" "")
+ PrintTestCompilerStatus("Fortran")
file(WRITE ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/testFortranCompiler.f "
PROGRAM TESTFortran
PRINT *, 'Hello'
@@ -37,7 +37,7 @@ if(NOT CMAKE_Fortran_COMPILER_WORKS)
endif()
if(NOT CMAKE_Fortran_COMPILER_WORKS)
- PrintTestCompilerStatus("Fortran" " -- broken")
+ PrintTestCompilerResult(CHECK_FAIL "broken")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if the Fortran compiler works failed with "
"the following output:\n${OUTPUT}\n\n")
@@ -48,7 +48,7 @@ if(NOT CMAKE_Fortran_COMPILER_WORKS)
"CMake will not be able to correctly generate this project.")
else()
if(FORTRAN_TEST_WAS_RUN)
- PrintTestCompilerStatus("Fortran" " -- works")
+ PrintTestCompilerResult(CHECK_PASS "works")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the Fortran compiler works passed with "
"the following output:\n${OUTPUT}\n\n")
@@ -60,7 +60,7 @@ else()
# Test for Fortran 90 support by using an f90-specific construct.
if(NOT DEFINED CMAKE_Fortran_COMPILER_SUPPORTS_F90)
- message(STATUS "Checking whether ${CMAKE_Fortran_COMPILER} supports Fortran 90")
+ message(CHECK_START "Checking whether ${CMAKE_Fortran_COMPILER} supports Fortran 90")
file(WRITE ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/testFortranCompilerF90.f90 "
PROGRAM TESTFortran90
integer stop ; stop = 1 ; do while ( stop .eq. 0 ) ; end do
@@ -70,13 +70,13 @@ else()
${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/testFortranCompilerF90.f90
OUTPUT_VARIABLE OUTPUT)
if(CMAKE_Fortran_COMPILER_SUPPORTS_F90)
- message(STATUS "Checking whether ${CMAKE_Fortran_COMPILER} supports Fortran 90 -- yes")
+ message(CHECK_PASS "yes")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the Fortran compiler supports Fortran 90 passed with "
"the following output:\n${OUTPUT}\n\n")
set(CMAKE_Fortran_COMPILER_SUPPORTS_F90 1)
else()
- message(STATUS "Checking whether ${CMAKE_Fortran_COMPILER} supports Fortran 90 -- no")
+ message(CHECK_FAIL "no")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if the Fortran compiler supports Fortran 90 failed with "
"the following output:\n${OUTPUT}\n\n")
diff --git a/Modules/CMakeTestOBJCCompiler.cmake b/Modules/CMakeTestOBJCCompiler.cmake
index 0030683..bcc6fae 100644
--- a/Modules/CMakeTestOBJCCompiler.cmake
+++ b/Modules/CMakeTestOBJCCompiler.cmake
@@ -27,7 +27,7 @@ unset(CMAKE_OBJC_COMPILER_WORKS CACHE)
# is set and cmake stops processing commands and will not generate
# any makefiles or projects.
if(NOT CMAKE_OBJC_COMPILER_WORKS)
- PrintTestCompilerStatus("OBJC" "")
+ PrintTestCompilerStatus("OBJC")
__TestCompiler_setTryCompileTargetType()
file(WRITE ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/testOBJCCompiler.m
"#ifdef __cplusplus\n"
@@ -49,7 +49,7 @@ if(NOT CMAKE_OBJC_COMPILER_WORKS)
endif()
if(NOT CMAKE_OBJC_COMPILER_WORKS)
- PrintTestCompilerStatus("OBJC" " -- broken")
+ PrintTestCompilerResult(CHECK_FAIL "broken")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if the Objective-C compiler works failed with "
"the following output:\n${__CMAKE_OBJC_COMPILER_OUTPUT}\n\n")
@@ -60,7 +60,7 @@ if(NOT CMAKE_OBJC_COMPILER_WORKS)
"CMake will not be able to correctly generate this project.")
else()
if(OBJC_TEST_WAS_RUN)
- PrintTestCompilerStatus("OBJC" " -- works")
+ PrintTestCompilerResult(CHECK_PASS "works")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the Objective-C compiler works passed with "
"the following output:\n${__CMAKE_OBJC_COMPILER_OUTPUT}\n\n")
diff --git a/Modules/CMakeTestOBJCXXCompiler.cmake b/Modules/CMakeTestOBJCXXCompiler.cmake
index bcce2f1..83227d5 100644
--- a/Modules/CMakeTestOBJCXXCompiler.cmake
+++ b/Modules/CMakeTestOBJCXXCompiler.cmake
@@ -27,7 +27,7 @@ unset(CMAKE_OBJCXX_COMPILER_WORKS CACHE)
# is set and cmake stops processing commands and will not generate
# any makefiles or projects.
if(NOT CMAKE_OBJCXX_COMPILER_WORKS)
- PrintTestCompilerStatus("OBJCXX" "")
+ PrintTestCompilerStatus("OBJCXX")
__TestCompiler_setTryCompileTargetType()
file(WRITE ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/testOBJCXXCompiler.mm
"#ifndef __cplusplus\n"
@@ -48,7 +48,7 @@ if(NOT CMAKE_OBJCXX_COMPILER_WORKS)
endif()
if(NOT CMAKE_OBJCXX_COMPILER_WORKS)
- PrintTestCompilerStatus("OBJCXX" " -- broken")
+ PrintTestCompilerResult(CHECK_FAIL "broken")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if the Objective-C++ compiler works failed with "
"the following output:\n${__CMAKE_OBJCXX_COMPILER_OUTPUT}\n\n")
@@ -59,7 +59,7 @@ if(NOT CMAKE_OBJCXX_COMPILER_WORKS)
"CMake will not be able to correctly generate this project.")
else()
if(OBJCXX_TEST_WAS_RUN)
- PrintTestCompilerStatus("OBJCXX" " -- works")
+ PrintTestCompilerResult(CHECK_PASS "works")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the Objective-C++ compiler works passed with "
"the following output:\n${__CMAKE_OBJCXX_COMPILER_OUTPUT}\n\n")
diff --git a/Modules/CMakeTestSwiftCompiler.cmake b/Modules/CMakeTestSwiftCompiler.cmake
index 841aee6..3e4ff95 100644
--- a/Modules/CMakeTestSwiftCompiler.cmake
+++ b/Modules/CMakeTestSwiftCompiler.cmake
@@ -20,7 +20,7 @@ unset(CMAKE_Swift_COMPILER_WORKS CACHE)
# is set and cmake stops processing commands and will not generate
# any makefiles or projects.
if(NOT CMAKE_Swift_COMPILER_WORKS)
- PrintTestCompilerStatus("Swift" "")
+ PrintTestCompilerStatus("Swift")
file(WRITE ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/main.swift
"print(\"CMake\")\n")
try_compile(CMAKE_Swift_COMPILER_WORKS ${CMAKE_BINARY_DIR}
@@ -33,7 +33,7 @@ if(NOT CMAKE_Swift_COMPILER_WORKS)
endif()
if(NOT CMAKE_Swift_COMPILER_WORKS)
- PrintTestCompilerStatus("Swift" " -- broken")
+ PrintTestCompilerResult(CHECK_FAIL "broken")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if the Swift compiler works failed with "
"the following output:\n${__CMAKE_Swift_COMPILER_OUTPUT}\n\n")
@@ -44,7 +44,7 @@ if(NOT CMAKE_Swift_COMPILER_WORKS)
"CMake will not be able to correctly generate this project.")
else()
if(Swift_TEST_WAS_RUN)
- PrintTestCompilerStatus("Swift" " -- works")
+ PrintTestCompilerResult(CHECK_PASS "works")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the Swift compiler works passed with "
"the following output:\n${__CMAKE_Swift_COMPILER_OUTPUT}\n\n")
diff --git a/Modules/CPack.cmake b/Modules/CPack.cmake
index 1809846..c912a0a 100644
--- a/Modules/CPack.cmake
+++ b/Modules/CPack.cmake
@@ -688,6 +688,8 @@ endif()
# value of CPACK_NSIS_PACKAGE_NAME instead
# of CPACK_PACKAGE_INSTALL_DIRECTORY
_cpack_set_default(CPACK_NSIS_DISPLAY_NAME "${CPACK_PACKAGE_INSTALL_DIRECTORY}")
+# Specify the name of the Uninstall file in NSIS
+_cpack_set_default(CPACK_NSIS_UNINSTALL_NAME "Uninstall")
if(CPACK_NSIS_DISPLAY_NAME_SET)
_cpack_set_default(CPACK_NSIS_PACKAGE_NAME "${CPACK_NSIS_DISPLAY_NAME}")
diff --git a/Modules/CheckCSourceCompiles.cmake b/Modules/CheckCSourceCompiles.cmake
index 77ba0cc..67fc993 100644
--- a/Modules/CheckCSourceCompiles.cmake
+++ b/Modules/CheckCSourceCompiles.cmake
@@ -104,7 +104,7 @@ macro(CHECK_C_SOURCE_COMPILES SOURCE VAR)
"${SOURCE}\n")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR}")
+ message(CHECK_START "Performing Test ${VAR}")
endif()
try_compile(${VAR}
${CMAKE_BINARY_DIR}
@@ -125,7 +125,7 @@ macro(CHECK_C_SOURCE_COMPILES SOURCE VAR)
if(${VAR})
set(${VAR} 1 CACHE INTERNAL "Test ${VAR}")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Success")
+ message(CHECK_PASS "Success")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Performing C SOURCE FILE Test ${VAR} succeeded with the following output:\n"
@@ -133,7 +133,7 @@ macro(CHECK_C_SOURCE_COMPILES SOURCE VAR)
"Source file was:\n${SOURCE}\n")
else()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Failed")
+ message(CHECK_FAIL "Failed")
endif()
set(${VAR} "" CACHE INTERNAL "Test ${VAR}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
diff --git a/Modules/CheckCSourceRuns.cmake b/Modules/CheckCSourceRuns.cmake
index eba70f2..7d116db 100644
--- a/Modules/CheckCSourceRuns.cmake
+++ b/Modules/CheckCSourceRuns.cmake
@@ -92,7 +92,7 @@ macro(CHECK_C_SOURCE_RUNS SOURCE VAR)
"${SOURCE}\n")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR}")
+ message(CHECK_START "Performing Test ${VAR}")
endif()
try_run(${VAR}_EXITCODE ${VAR}_COMPILED
${CMAKE_BINARY_DIR}
@@ -113,7 +113,7 @@ macro(CHECK_C_SOURCE_RUNS SOURCE VAR)
if("${${VAR}_EXITCODE}" EQUAL 0)
set(${VAR} 1 CACHE INTERNAL "Test ${VAR}")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Success")
+ message(CHECK_PASS "Success")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Performing C SOURCE FILE Test ${VAR} succeeded with the following compile output:\n"
@@ -130,7 +130,7 @@ macro(CHECK_C_SOURCE_RUNS SOURCE VAR)
endif()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Failed")
+ message(CHECK_FAIL "Failed")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Performing C SOURCE FILE Test ${VAR} failed with the following compile output:\n"
diff --git a/Modules/CheckCXXSourceCompiles.cmake b/Modules/CheckCXXSourceCompiles.cmake
index cc457a5..c693d32 100644
--- a/Modules/CheckCXXSourceCompiles.cmake
+++ b/Modules/CheckCXXSourceCompiles.cmake
@@ -105,7 +105,7 @@ macro(CHECK_CXX_SOURCE_COMPILES SOURCE VAR)
"${SOURCE}\n")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR}")
+ message(CHECK_START "Performing Test ${VAR}")
endif()
try_compile(${VAR}
${CMAKE_BINARY_DIR}
@@ -126,7 +126,7 @@ macro(CHECK_CXX_SOURCE_COMPILES SOURCE VAR)
if(${VAR})
set(${VAR} 1 CACHE INTERNAL "Test ${VAR}")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Success")
+ message(CHECK_PASS "Success")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Performing C++ SOURCE FILE Test ${VAR} succeeded with the following output:\n"
@@ -134,7 +134,7 @@ macro(CHECK_CXX_SOURCE_COMPILES SOURCE VAR)
"Source file was:\n${SOURCE}\n")
else()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Failed")
+ message(CHECK_FAIL "Failed")
endif()
set(${VAR} "" CACHE INTERNAL "Test ${VAR}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
diff --git a/Modules/CheckCXXSourceRuns.cmake b/Modules/CheckCXXSourceRuns.cmake
index 5e3f195..408e183 100644
--- a/Modules/CheckCXXSourceRuns.cmake
+++ b/Modules/CheckCXXSourceRuns.cmake
@@ -92,7 +92,7 @@ macro(CHECK_CXX_SOURCE_RUNS SOURCE VAR)
"${SOURCE}\n")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR}")
+ message(CHECK_START "Performing Test ${VAR}")
endif()
try_run(${VAR}_EXITCODE ${VAR}_COMPILED
${CMAKE_BINARY_DIR}
@@ -114,7 +114,7 @@ macro(CHECK_CXX_SOURCE_RUNS SOURCE VAR)
if("${${VAR}_EXITCODE}" EQUAL 0)
set(${VAR} 1 CACHE INTERNAL "Test ${VAR}")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Success")
+ message(CHECK_PASS "Success")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Performing C++ SOURCE FILE Test ${VAR} succeeded with the following output:\n"
@@ -131,7 +131,7 @@ macro(CHECK_CXX_SOURCE_RUNS SOURCE VAR)
endif()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Failed")
+ message(CHECK_FAIL "Failed")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Performing C++ SOURCE FILE Test ${VAR} failed with the following output:\n"
diff --git a/Modules/CheckFortranFunctionExists.cmake b/Modules/CheckFortranFunctionExists.cmake
index 7ca205a..d06203f 100644
--- a/Modules/CheckFortranFunctionExists.cmake
+++ b/Modules/CheckFortranFunctionExists.cmake
@@ -38,7 +38,7 @@ include_guard(GLOBAL)
macro(CHECK_FORTRAN_FUNCTION_EXISTS FUNCTION VARIABLE)
if(NOT DEFINED ${VARIABLE})
- message(STATUS "Looking for Fortran ${FUNCTION}")
+ message(CHECK_START "Looking for Fortran ${FUNCTION}")
if(CMAKE_REQUIRED_LINK_OPTIONS)
set(CHECK_FUNCTION_EXISTS_ADD_LINK_OPTIONS
LINK_OPTIONS ${CMAKE_REQUIRED_LINK_OPTIONS})
@@ -61,21 +61,20 @@ macro(CHECK_FORTRAN_FUNCTION_EXISTS FUNCTION VARIABLE)
"
)
try_compile(${VARIABLE}
- ${CMAKE_BINARY_DIR}
- ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/testFortranCompiler.f
- ${CHECK_FUNCTION_EXISTS_ADD_LINK_OPTIONS}
- ${CHECK_FUNCTION_EXISTS_ADD_LIBRARIES}
- OUTPUT_VARIABLE OUTPUT
+ ${CMAKE_BINARY_DIR}
+ ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/testFortranCompiler.f
+ ${CHECK_FUNCTION_EXISTS_ADD_LINK_OPTIONS}
+ ${CHECK_FUNCTION_EXISTS_ADD_LIBRARIES}
+ OUTPUT_VARIABLE OUTPUT
)
-# message(STATUS "${OUTPUT}")
if(${VARIABLE})
set(${VARIABLE} 1 CACHE INTERNAL "Have Fortran function ${FUNCTION}")
- message(STATUS "Looking for Fortran ${FUNCTION} - found")
+ message(CHECK_PASS "found")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the Fortran ${FUNCTION} exists passed with the following output:\n"
"${OUTPUT}\n\n")
else()
- message(STATUS "Looking for Fortran ${FUNCTION} - not found")
+ message(CHECK_FAIL "not found")
set(${VARIABLE} "" CACHE INTERNAL "Have Fortran function ${FUNCTION}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if the Fortran ${FUNCTION} exists failed with the following output:\n"
diff --git a/Modules/CheckFortranSourceCompiles.cmake b/Modules/CheckFortranSourceCompiles.cmake
index f94b254..f0fde8d 100644
--- a/Modules/CheckFortranSourceCompiles.cmake
+++ b/Modules/CheckFortranSourceCompiles.cmake
@@ -127,7 +127,7 @@ macro(CHECK_Fortran_SOURCE_COMPILES SOURCE VAR)
"${SOURCE}\n")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR}")
+ message(CHECK_START "Performing Test ${VAR}")
endif()
try_compile(${VAR}
${CMAKE_BINARY_DIR}
@@ -148,7 +148,7 @@ macro(CHECK_Fortran_SOURCE_COMPILES SOURCE VAR)
if(${VAR})
set(${VAR} 1 CACHE INTERNAL "Test ${VAR}")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Success")
+ message(CHECK_PASS "Success")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Performing Fortran SOURCE FILE Test ${VAR} succeeded with the following output:\n"
@@ -156,7 +156,7 @@ macro(CHECK_Fortran_SOURCE_COMPILES SOURCE VAR)
"Source file was:\n${SOURCE}\n")
else()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Failed")
+ message(CHECK_FAIL "Failed")
endif()
set(${VAR} "" CACHE INTERNAL "Test ${VAR}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
diff --git a/Modules/CheckFortranSourceRuns.cmake b/Modules/CheckFortranSourceRuns.cmake
index a80c13d..a3e5d5d 100644
--- a/Modules/CheckFortranSourceRuns.cmake
+++ b/Modules/CheckFortranSourceRuns.cmake
@@ -122,7 +122,7 @@ macro(CHECK_Fortran_SOURCE_RUNS SOURCE VAR)
"${SOURCE}\n")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR}")
+ message(CHECK_START "Performing Test ${VAR}")
endif()
try_run(${VAR}_EXITCODE ${VAR}_COMPILED
${CMAKE_BINARY_DIR}
@@ -144,7 +144,7 @@ macro(CHECK_Fortran_SOURCE_RUNS SOURCE VAR)
if("${${VAR}_EXITCODE}" EQUAL 0)
set(${VAR} 1 CACHE INTERNAL "Test ${VAR}")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Success")
+ message(CHECK_PASS "Success")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Performing Fortran SOURCE FILE Test ${VAR} succeeded with the following output:\n"
@@ -161,7 +161,7 @@ macro(CHECK_Fortran_SOURCE_RUNS SOURCE VAR)
endif()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Failed")
+ message(CHECK_FAIL "Failed")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Performing Fortran SOURCE FILE Test ${VAR} failed with the following output:\n"
diff --git a/Modules/CheckFunctionExists.cmake b/Modules/CheckFunctionExists.cmake
index c39144f..136da89 100644
--- a/Modules/CheckFunctionExists.cmake
+++ b/Modules/CheckFunctionExists.cmake
@@ -57,7 +57,7 @@ macro(CHECK_FUNCTION_EXISTS FUNCTION VARIABLE)
set(MACRO_CHECK_FUNCTION_DEFINITIONS
"-DCHECK_FUNCTION_EXISTS=${FUNCTION} ${CMAKE_REQUIRED_FLAGS}")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${FUNCTION}")
+ message(CHECK_START "Looking for ${FUNCTION}")
endif()
if(CMAKE_REQUIRED_LINK_OPTIONS)
set(CHECK_FUNCTION_EXISTS_ADD_LINK_OPTIONS
@@ -101,14 +101,14 @@ macro(CHECK_FUNCTION_EXISTS FUNCTION VARIABLE)
if(${VARIABLE})
set(${VARIABLE} 1 CACHE INTERNAL "Have function ${FUNCTION}")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${FUNCTION} - found")
+ message(CHECK_PASS "found")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the function ${FUNCTION} exists passed with the following output:\n"
"${OUTPUT}\n\n")
else()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${FUNCTION} - not found")
+ message(CHECK_FAIL "not found")
endif()
set(${VARIABLE} "" CACHE INTERNAL "Have function ${FUNCTION}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
diff --git a/Modules/CheckIncludeFile.cmake b/Modules/CheckIncludeFile.cmake
index d7b9481..3a10473 100644
--- a/Modules/CheckIncludeFile.cmake
+++ b/Modules/CheckIncludeFile.cmake
@@ -55,7 +55,7 @@ macro(CHECK_INCLUDE_FILE INCLUDE VARIABLE)
configure_file(${CMAKE_ROOT}/Modules/CheckIncludeFile.c.in
${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/CheckIncludeFile.c)
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${INCLUDE}")
+ message(CHECK_START "Looking for ${INCLUDE}")
endif()
if(${ARGC} EQUAL 3)
set(CMAKE_C_FLAGS_SAVE ${CMAKE_C_FLAGS})
@@ -109,7 +109,7 @@ macro(CHECK_INCLUDE_FILE INCLUDE VARIABLE)
if(${VARIABLE})
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${INCLUDE} - found")
+ message(CHECK_PASS "found")
endif()
set(${VARIABLE} 1 CACHE INTERNAL "Have include ${INCLUDE}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
@@ -118,7 +118,7 @@ macro(CHECK_INCLUDE_FILE INCLUDE VARIABLE)
"${OUTPUT}\n\n")
else()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${INCLUDE} - not found")
+ message(CHECK_FAIL "not found")
endif()
set(${VARIABLE} "" CACHE INTERNAL "Have include ${INCLUDE}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
diff --git a/Modules/CheckIncludeFileCXX.cmake b/Modules/CheckIncludeFileCXX.cmake
index de5a83b..496550f 100644
--- a/Modules/CheckIncludeFileCXX.cmake
+++ b/Modules/CheckIncludeFileCXX.cmake
@@ -54,7 +54,7 @@ macro(CHECK_INCLUDE_FILE_CXX INCLUDE VARIABLE)
configure_file(${CMAKE_ROOT}/Modules/CheckIncludeFile.cxx.in
${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/CheckIncludeFile.cxx)
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for C++ include ${INCLUDE}")
+ message(CHECK_START "Looking for C++ include ${INCLUDE}")
endif()
if(${ARGC} EQUAL 3)
set(CMAKE_CXX_FLAGS_SAVE ${CMAKE_CXX_FLAGS})
@@ -108,7 +108,7 @@ macro(CHECK_INCLUDE_FILE_CXX INCLUDE VARIABLE)
if(${VARIABLE})
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for C++ include ${INCLUDE} - found")
+ message(CHECK_PASS "found")
endif()
set(${VARIABLE} 1 CACHE INTERNAL "Have include ${INCLUDE}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
@@ -117,7 +117,7 @@ macro(CHECK_INCLUDE_FILE_CXX INCLUDE VARIABLE)
"${OUTPUT}\n\n")
else()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for C++ include ${INCLUDE} - not found")
+ message(CHECK_FAIL "not found")
endif()
set(${VARIABLE} "" CACHE INTERNAL "Have include ${INCLUDE}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
diff --git a/Modules/CheckIncludeFiles.cmake b/Modules/CheckIncludeFiles.cmake
index f52ab55..8e10cd6 100644
--- a/Modules/CheckIncludeFiles.cmake
+++ b/Modules/CheckIncludeFiles.cmake
@@ -131,7 +131,7 @@ macro(CHECK_INCLUDE_FILES INCLUDE VARIABLE)
endif()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${_description}")
+ message(CHECK_START "Looking for ${_description}")
endif()
try_compile(${VARIABLE}
${CMAKE_BINARY_DIR}
@@ -147,7 +147,7 @@ macro(CHECK_INCLUDE_FILES INCLUDE VARIABLE)
unset(_CIF_LINK_LIBRARIES)
if(${VARIABLE})
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${_description} - found")
+ message(CHECK_PASS "found")
endif()
set(${VARIABLE} 1 CACHE INTERNAL "Have include ${INCLUDE}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
@@ -156,7 +156,7 @@ macro(CHECK_INCLUDE_FILES INCLUDE VARIABLE)
"${OUTPUT}\n\n")
else()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${_description} - not found")
+ message(CHECK_FAIL "not found")
endif()
set(${VARIABLE} "" CACHE INTERNAL "Have includes ${INCLUDE}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
diff --git a/Modules/CheckLanguage.cmake b/Modules/CheckLanguage.cmake
index a1a3a7a..a337926 100644
--- a/Modules/CheckLanguage.cmake
+++ b/Modules/CheckLanguage.cmake
@@ -39,7 +39,7 @@ include_guard(GLOBAL)
macro(check_language lang)
if(NOT DEFINED CMAKE_${lang}_COMPILER)
set(_desc "Looking for a ${lang} compiler")
- message(STATUS ${_desc})
+ message(CHECK_START "${_desc}")
file(REMOVE_RECURSE ${CMAKE_CURRENT_BINARY_DIR}/CMakeFiles/Check${lang})
set(extra_compiler_variables)
@@ -78,13 +78,15 @@ file(WRITE \"\${CMAKE_CURRENT_BINARY_DIR}/result.cmake\"
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"${_desc} passed with the following output:\n"
"${output}\n")
+ set(_CHECK_COMPILER_STATUS CHECK_PASS)
else()
set(CMAKE_${lang}_COMPILER NOTFOUND)
+ set(_CHECK_COMPILER_STATUS CHECK_FAIL)
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"${_desc} failed with the following output:\n"
"${output}\n")
endif()
- message(STATUS "${_desc} - ${CMAKE_${lang}_COMPILER}")
+ message(${_CHECK_COMPILER_STATUS} "${CMAKE_${lang}_COMPILER}")
set(CMAKE_${lang}_COMPILER "${CMAKE_${lang}_COMPILER}" CACHE FILEPATH "${lang} compiler")
mark_as_advanced(CMAKE_${lang}_COMPILER)
diff --git a/Modules/CheckLibraryExists.cmake b/Modules/CheckLibraryExists.cmake
index 6504df5..6470dfd 100644
--- a/Modules/CheckLibraryExists.cmake
+++ b/Modules/CheckLibraryExists.cmake
@@ -42,7 +42,7 @@ macro(CHECK_LIBRARY_EXISTS LIBRARY FUNCTION LOCATION VARIABLE)
set(MACRO_CHECK_LIBRARY_EXISTS_DEFINITION
"-DCHECK_FUNCTION_EXISTS=${FUNCTION} ${CMAKE_REQUIRED_FLAGS}")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${FUNCTION} in ${LIBRARY}")
+ message(CHECK_START "Looking for ${FUNCTION} in ${LIBRARY}")
endif()
set(CHECK_LIBRARY_EXISTS_LINK_OPTIONS)
if(CMAKE_REQUIRED_LINK_OPTIONS)
@@ -78,7 +78,7 @@ macro(CHECK_LIBRARY_EXISTS LIBRARY FUNCTION LOCATION VARIABLE)
if(${VARIABLE})
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${FUNCTION} in ${LIBRARY} - found")
+ message(CHECK_PASS "found")
endif()
set(${VARIABLE} 1 CACHE INTERNAL "Have library ${LIBRARY}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
@@ -87,7 +87,7 @@ macro(CHECK_LIBRARY_EXISTS LIBRARY FUNCTION LOCATION VARIABLE)
"${OUTPUT}\n\n")
else()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${FUNCTION} in ${LIBRARY} - not found")
+ message(CHECK_FAIL "not found")
endif()
set(${VARIABLE} "" CACHE INTERNAL "Have library ${LIBRARY}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
diff --git a/Modules/CheckOBJCSourceCompiles.cmake b/Modules/CheckOBJCSourceCompiles.cmake
index a4676ad..601f1fa 100644
--- a/Modules/CheckOBJCSourceCompiles.cmake
+++ b/Modules/CheckOBJCSourceCompiles.cmake
@@ -104,7 +104,7 @@ macro(CHECK_OBJC_SOURCE_COMPILES SOURCE VAR)
"${SOURCE}\n")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR}")
+ message(CHECK_START "Performing Test ${VAR}")
endif()
try_compile(${VAR}
${CMAKE_BINARY_DIR}
@@ -125,7 +125,7 @@ macro(CHECK_OBJC_SOURCE_COMPILES SOURCE VAR)
if(${VAR})
set(${VAR} 1 CACHE INTERNAL "Test ${VAR}")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Success")
+ message(CHECK_PASS "Success")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Performing Objective-C SOURCE FILE Test ${VAR} succeeded with the following output:\n"
@@ -133,7 +133,7 @@ macro(CHECK_OBJC_SOURCE_COMPILES SOURCE VAR)
"Source file was:\n${SOURCE}\n")
else()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Failed")
+ message(CHECK_FAIL "Failed")
endif()
set(${VAR} "" CACHE INTERNAL "Test ${VAR}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
diff --git a/Modules/CheckOBJCSourceRuns.cmake b/Modules/CheckOBJCSourceRuns.cmake
index 00a1ebd..6684693 100644
--- a/Modules/CheckOBJCSourceRuns.cmake
+++ b/Modules/CheckOBJCSourceRuns.cmake
@@ -92,7 +92,7 @@ macro(CHECK_OBJC_SOURCE_RUNS SOURCE VAR)
"${SOURCE}\n")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR}")
+ message(CHECK_START "Performing Test ${VAR}")
endif()
try_run(${VAR}_EXITCODE ${VAR}_COMPILED
${CMAKE_BINARY_DIR}
@@ -113,7 +113,7 @@ macro(CHECK_OBJC_SOURCE_RUNS SOURCE VAR)
if("${${VAR}_EXITCODE}" EQUAL 0)
set(${VAR} 1 CACHE INTERNAL "Test ${VAR}")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Success")
+ message(CHECK_PASS "Success")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Performing Objective-C SOURCE FILE Test ${VAR} succeeded with the following compile output:\n"
@@ -130,7 +130,7 @@ macro(CHECK_OBJC_SOURCE_RUNS SOURCE VAR)
endif()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Failed")
+ message(CHECK_FAIL "Failed")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Performing Objective-C SOURCE FILE Test ${VAR} failed with the following compile output:\n"
diff --git a/Modules/CheckOBJCXXSourceCompiles.cmake b/Modules/CheckOBJCXXSourceCompiles.cmake
index 4c0fdd0..2ee79f4 100644
--- a/Modules/CheckOBJCXXSourceCompiles.cmake
+++ b/Modules/CheckOBJCXXSourceCompiles.cmake
@@ -105,7 +105,7 @@ macro(CHECK_OBJCXX_SOURCE_COMPILES SOURCE VAR)
"${SOURCE}\n")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR}")
+ message(CHECK_START "Performing Test ${VAR}")
endif()
try_compile(${VAR}
${CMAKE_BINARY_DIR}
@@ -126,7 +126,7 @@ macro(CHECK_OBJCXX_SOURCE_COMPILES SOURCE VAR)
if(${VAR})
set(${VAR} 1 CACHE INTERNAL "Test ${VAR}")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Success")
+ message(CHECK_PASS "Success")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Performing Objective-C++ SOURCE FILE Test ${VAR} succeeded with the following output:\n"
@@ -134,7 +134,7 @@ macro(CHECK_OBJCXX_SOURCE_COMPILES SOURCE VAR)
"Source file was:\n${SOURCE}\n")
else()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Failed")
+ message(CHECK_FAIL "Failed")
endif()
set(${VAR} "" CACHE INTERNAL "Test ${VAR}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
diff --git a/Modules/CheckOBJCXXSourceRuns.cmake b/Modules/CheckOBJCXXSourceRuns.cmake
index a3d5923..7f7e04f 100644
--- a/Modules/CheckOBJCXXSourceRuns.cmake
+++ b/Modules/CheckOBJCXXSourceRuns.cmake
@@ -92,7 +92,7 @@ macro(CHECK_OBJCXX_SOURCE_RUNS SOURCE VAR)
"${SOURCE}\n")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR}")
+ message(CHECK_START "Performing Test ${VAR}")
endif()
try_run(${VAR}_EXITCODE ${VAR}_COMPILED
${CMAKE_BINARY_DIR}
@@ -114,7 +114,7 @@ macro(CHECK_OBJCXX_SOURCE_RUNS SOURCE VAR)
if("${${VAR}_EXITCODE}" EQUAL 0)
set(${VAR} 1 CACHE INTERNAL "Test ${VAR}")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Success")
+ message(CHECK_PASS "Success")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Performing Objective-C++ SOURCE FILE Test ${VAR} succeeded with the following output:\n"
@@ -131,7 +131,7 @@ macro(CHECK_OBJCXX_SOURCE_RUNS SOURCE VAR)
endif()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Performing Test ${VAR} - Failed")
+ message(CHECK_FAIL "Failed")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Performing Objective-C++ SOURCE FILE Test ${VAR} failed with the following output:\n"
diff --git a/Modules/CheckPrototypeDefinition.cmake b/Modules/CheckPrototypeDefinition.cmake
index a7b020c..8b06403 100644
--- a/Modules/CheckPrototypeDefinition.cmake
+++ b/Modules/CheckPrototypeDefinition.cmake
@@ -54,6 +54,9 @@ include_guard(GLOBAL)
function(check_prototype_definition _FUNCTION _PROTOTYPE _RETURN _HEADER _VARIABLE)
if (NOT DEFINED ${_VARIABLE})
+ if(NOT CMAKE_REQUIRED_QUIET)
+ message(CHECK_START "Checking prototype ${_FUNCTION} for ${_VARIABLE}")
+ endif()
set(CHECK_PROTOTYPE_DEFINITION_CONTENT "/* */\n")
set(CHECK_PROTOTYPE_DEFINITION_FLAGS ${CMAKE_REQUIRED_FLAGS})
@@ -103,14 +106,14 @@ function(check_prototype_definition _FUNCTION _PROTOTYPE _RETURN _HEADER _VARIAB
if (${_VARIABLE})
set(${_VARIABLE} 1 CACHE INTERNAL "Have correct prototype for ${_FUNCTION}")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Checking prototype ${_FUNCTION} for ${_VARIABLE} - True")
+ message(CHECK_PASS "True")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the prototype ${_FUNCTION} exists for ${_VARIABLE} passed with the following output:\n"
"${OUTPUT}\n\n")
else ()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Checking prototype ${_FUNCTION} for ${_VARIABLE} - False")
+ message(CHECK_FAIL "False")
endif()
set(${_VARIABLE} 0 CACHE INTERNAL "Have correct prototype for ${_FUNCTION}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
diff --git a/Modules/CheckSymbolExists.cmake b/Modules/CheckSymbolExists.cmake
index 1053383..4f202c4 100644
--- a/Modules/CheckSymbolExists.cmake
+++ b/Modules/CheckSymbolExists.cmake
@@ -126,7 +126,7 @@ int main(int argc, char** argv)
"${SOURCEFILE}" @ONLY)
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${SYMBOL}")
+ message(CHECK_START "Looking for ${SYMBOL}")
endif()
try_compile(${VARIABLE}
${CMAKE_BINARY_DIR}
@@ -140,7 +140,7 @@ int main(int argc, char** argv)
OUTPUT_VARIABLE OUTPUT)
if(${VARIABLE})
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${SYMBOL} - found")
+ message(CHECK_PASS "found")
endif()
set(${VARIABLE} 1 CACHE INTERNAL "Have symbol ${SYMBOL}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
@@ -150,7 +150,7 @@ int main(int argc, char** argv)
"${CMAKE_CONFIGURABLE_FILE_CONTENT}\n")
else()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${SYMBOL} - not found")
+ message(CHECK_FAIL "not found")
endif()
set(${VARIABLE} "" CACHE INTERNAL "Have symbol ${SYMBOL}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
diff --git a/Modules/CheckTypeSize.cmake b/Modules/CheckTypeSize.cmake
index 3727373..2b07b7c 100644
--- a/Modules/CheckTypeSize.cmake
+++ b/Modules/CheckTypeSize.cmake
@@ -86,7 +86,7 @@ cmake_policy(SET CMP0054 NEW)
# Helper function. DO NOT CALL DIRECTLY.
function(__check_type_size_impl type var map builtin language)
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Check size of ${type}")
+ message(CHECK_START "Check size of ${type}")
endif()
# Include header files.
@@ -173,7 +173,7 @@ function(__check_type_size_impl type var map builtin language)
endif()
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Check size of ${type} - done")
+ message(CHECK_PASS "done")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining size of ${type} passed with the following output:\n${output}\n\n")
@@ -181,7 +181,7 @@ function(__check_type_size_impl type var map builtin language)
else()
# The check failed to compile.
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Check size of ${type} - failed")
+ message(CHECK_FAIL "failed")
endif()
file(READ ${src} content)
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
diff --git a/Modules/CheckVariableExists.cmake b/Modules/CheckVariableExists.cmake
index f4953a3..8a93535 100644
--- a/Modules/CheckVariableExists.cmake
+++ b/Modules/CheckVariableExists.cmake
@@ -42,7 +42,7 @@ macro(CHECK_VARIABLE_EXISTS VAR VARIABLE)
set(MACRO_CHECK_VARIABLE_DEFINITIONS
"-DCHECK_VARIABLE_EXISTS=${VAR} ${CMAKE_REQUIRED_FLAGS}")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${VAR}")
+ message(CHECK_START "Looking for ${VAR}")
endif()
if(CMAKE_REQUIRED_LINK_OPTIONS)
set(CHECK_VARIABLE_EXISTS_ADD_LINK_OPTIONS
@@ -67,7 +67,7 @@ macro(CHECK_VARIABLE_EXISTS VAR VARIABLE)
if(${VARIABLE})
set(${VARIABLE} 1 CACHE INTERNAL "Have variable ${VAR}")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${VAR} - found")
+ message(CHECK_PASS "found")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the variable ${VAR} exists passed with the following output:\n"
@@ -75,7 +75,7 @@ macro(CHECK_VARIABLE_EXISTS VAR VARIABLE)
else()
set(${VARIABLE} "" CACHE INTERNAL "Have variable ${VAR}")
if(NOT CMAKE_REQUIRED_QUIET)
- message(STATUS "Looking for ${VAR} - not found")
+ message(CHECK_FAIL "not found")
endif()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if the variable ${VAR} exists failed with the following output:\n"
diff --git a/Modules/Compiler/NAG-Fortran.cmake b/Modules/Compiler/NAG-Fortran.cmake
index 9973feb..c54ab9d 100644
--- a/Modules/Compiler/NAG-Fortran.cmake
+++ b/Modules/Compiler/NAG-Fortran.cmake
@@ -1,6 +1,6 @@
# Help CMAKE_PARSE_IMPLICIT_LINK_INFO detect NAG Fortran object files.
if(NOT CMAKE_Fortran_COMPILER_WORKS AND NOT CMAKE_Fortran_COMPILER_FORCED)
- message(STATUS "Detecting NAG Fortran directory")
+ message(CHECK_START "Detecting NAG Fortran directory")
# Run with -dryrun to see sample "link" line.
execute_process(
COMMAND ${CMAKE_Fortran_COMPILER} dummy.o -dryrun
@@ -20,11 +20,11 @@ if(NOT CMAKE_Fortran_COMPILER_WORKS AND NOT CMAKE_Fortran_COMPILER_FORCED)
" directory: ${_nag_dir}\n"
" regex: ${CMAKE_Fortran_IMPLICIT_OBJECT_REGEX}\n"
"from output:\n${_dryrun}\n\n")
- message(STATUS "Detecting NAG Fortran directory - ${_nag_dir}")
+ message(CHECK_PASS "${_nag_dir}")
else()
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Detecting NAG Fortran directory with -dryrun failed:\n${_dryrun}\n\n")
- message(STATUS "Detecting NAG Fortran directory - failed")
+ message(CHECK_FAIL "failed")
endif()
endif()
diff --git a/Modules/CompilerId/VS-10.vcxproj.in b/Modules/CompilerId/VS-10.vcxproj.in
index d742274..b48a332 100644
--- a/Modules/CompilerId/VS-10.vcxproj.in
+++ b/Modules/CompilerId/VS-10.vcxproj.in
@@ -15,6 +15,8 @@
@id_WindowsTargetPlatformVersion@
@id_WindowsSDKDesktopARMSupport@
@id_CudaToolkitCustomDir@
+ @id_ToolsetVCTargetsDir@
+ @id_CustomGlobals@
</PropertyGroup>
@id_toolset_version_props@
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
diff --git a/Modules/ExternalProject.cmake b/Modules/ExternalProject.cmake
index 66061a1..cd4e22d 100644
--- a/Modules/ExternalProject.cmake
+++ b/Modules/ExternalProject.cmake
@@ -265,6 +265,11 @@ External Project Definition
is set to ``NEW`` if this value is set to an empty string then no submodules
are initialized or updated.
+ ``GIT_SUBMODULES_RECURSE <bool>``
+ Specify whether git submodules (if any) should update recursively by
+ passing the ``--recursive`` flag to ``git submodule update``.
+ If not specified, the default is on.
+
``GIT_SHALLOW <bool>``
When this option is enabled, the ``git clone`` operation will be given
the ``--depth 1`` option. This performs a shallow clone, which avoids
@@ -1065,7 +1070,7 @@ define_property(DIRECTORY PROPERTY "EP_UPDATE_DISCONNECTED" INHERITED
"ExternalProject module."
)
-function(_ep_write_gitclone_script script_filename source_dir git_EXECUTABLE git_repository git_tag git_remote_name init_submodules git_submodules git_shallow git_progress git_config src_name work_dir gitclone_infofile gitclone_stampfile tls_verify)
+function(_ep_write_gitclone_script script_filename source_dir git_EXECUTABLE git_repository git_tag git_remote_name init_submodules git_submodules_recurse git_submodules git_shallow git_progress git_config src_name work_dir gitclone_infofile gitclone_stampfile tls_verify)
if(NOT GIT_VERSION_STRING VERSION_LESS 1.8.5)
# Use `git checkout <tree-ish> --` to avoid ambiguity with a local path.
set(git_checkout_explicit-- "--")
@@ -1153,7 +1158,7 @@ endif()
set(init_submodules ${init_submodules})
if(init_submodules)
execute_process(
- COMMAND \"${git_EXECUTABLE}\" ${git_options} submodule update --recursive --init ${git_submodules}
+ COMMAND \"${git_EXECUTABLE}\" ${git_options} submodule update ${git_submodules_recurse} --init ${git_submodules}
WORKING_DIRECTORY \"${work_dir}/${src_name}\"
RESULT_VARIABLE error_code
)
@@ -1394,7 +1399,7 @@ if(error_code OR is_remote_ref OR NOT (\"\${tag_sha}\" STREQUAL \"\${head_sha}\"
set(init_submodules ${init_submodules})
if(init_submodules)
execute_process(
- COMMAND \"${git_EXECUTABLE}\" submodule update --recursive --init ${git_submodules}
+ COMMAND \"${git_EXECUTABLE}\" submodule update ${git_submodules_recurse} --init ${git_submodules}
WORKING_DIRECTORY \"${work_dir}/${src_name}\"
RESULT_VARIABLE error_code
)
@@ -2421,9 +2426,21 @@ function(_ep_add_download_command name)
message(FATAL_ERROR "error: could not find git for clone of ${name}")
endif()
+ get_property(git_submodules_recurse_set TARGET ${name} PROPERTY _EP_GIT_SUBMODULES_RECURSE SET)
+ if(NOT git_submodules_recurse_set)
+ set(git_submodules_recurse "--recursive")
+ else()
+ get_property(git_submodules_recurse_value TARGET ${name} PROPERTY _EP_GIT_SUBMODULES_RECURSE)
+ if(git_submodules_recurse_value)
+ set(git_submodules_recurse "--recursive")
+ else()
+ set(git_submodules_recurse "")
+ endif()
+ endif()
+
# The git submodule update '--recursive' flag requires git >= v1.6.5
#
- if(GIT_VERSION_STRING VERSION_LESS 1.6.5)
+ if(git_submodules_recurse AND GIT_VERSION_STRING VERSION_LESS 1.6.5)
message(FATAL_ERROR "error: git version 1.6.5 or later required for 'git submodule update --recursive': GIT_VERSION_STRING='${GIT_VERSION_STRING}'")
endif()
@@ -2477,7 +2494,7 @@ function(_ep_add_download_command name)
# The script will delete the source directory and then call git clone.
#
_ep_write_gitclone_script(${tmp_dir}/${name}-gitclone.cmake ${source_dir}
- ${GIT_EXECUTABLE} ${git_repository} ${git_tag} ${git_remote_name} ${git_init_submodules} "${git_submodules}" "${git_shallow}" "${git_progress}" "${git_config}" ${src_name} ${work_dir}
+ ${GIT_EXECUTABLE} ${git_repository} ${git_tag} ${git_remote_name} ${git_init_submodules} "${git_submodules_recurse}" "${git_submodules}" "${git_shallow}" "${git_progress}" "${git_config}" ${src_name} ${work_dir}
${stamp_dir}/${name}-gitinfo.txt ${stamp_dir}/${name}-gitclone-lastrun.txt "${tls_verify}"
)
set(comment "Performing download step (git clone) for '${name}'")
diff --git a/Modules/FindCUDA.cmake b/Modules/FindCUDA.cmake
index b6859aa..85d705c 100644
--- a/Modules/FindCUDA.cmake
+++ b/Modules/FindCUDA.cmake
@@ -676,7 +676,7 @@ endif()
# Search for the cuda distribution.
if(NOT CUDA_TOOLKIT_ROOT_DIR AND NOT CMAKE_CROSSCOMPILING)
# Search in the CUDA_BIN_PATH first.
- find_path(CUDA_TOOLKIT_ROOT_DIR
+ find_program(CUDA_TOOLKIT_ROOT_DIR_NVCC
NAMES nvcc nvcc.exe
PATHS
ENV CUDA_TOOLKIT_ROOT
@@ -688,19 +688,22 @@ if(NOT CUDA_TOOLKIT_ROOT_DIR AND NOT CMAKE_CROSSCOMPILING)
)
# Now search default paths
- find_path(CUDA_TOOLKIT_ROOT_DIR
+ find_program(CUDA_TOOLKIT_ROOT_DIR_NVCC
NAMES nvcc nvcc.exe
PATHS /opt/cuda/bin
PATH_SUFFIXES cuda/bin
DOC "Toolkit location."
)
- if (CUDA_TOOLKIT_ROOT_DIR)
+ if (CUDA_TOOLKIT_ROOT_DIR_NVCC)
+ get_filename_component(CUDA_TOOLKIT_ROOT_DIR_NVCC_PAR "${CUDA_TOOLKIT_ROOT_DIR_NVCC}" DIRECTORY)
+ get_filename_component(CUDA_TOOLKIT_ROOT_DIR "${CUDA_TOOLKIT_ROOT_DIR_NVCC_PAR}" DIRECTORY CACHE)
string(REGEX REPLACE "[/\\\\]?bin[64]*[/\\\\]?$" "" CUDA_TOOLKIT_ROOT_DIR ${CUDA_TOOLKIT_ROOT_DIR})
# We need to force this back into the cache.
set(CUDA_TOOLKIT_ROOT_DIR ${CUDA_TOOLKIT_ROOT_DIR} CACHE PATH "Toolkit location." FORCE)
set(CUDA_TOOLKIT_TARGET_DIR ${CUDA_TOOLKIT_ROOT_DIR})
endif()
+ unset(CUDA_TOOLKIT_ROOT_DIR_NVCC CACHE)
if (NOT EXISTS ${CUDA_TOOLKIT_ROOT_DIR})
if(CUDA_FIND_REQUIRED)
diff --git a/Modules/FindCURL.cmake b/Modules/FindCURL.cmake
index aeebc84..919babc 100644
--- a/Modules/FindCURL.cmake
+++ b/Modules/FindCURL.cmake
@@ -37,8 +37,35 @@ This module defines the following variables:
``CURL_VERSION_STRING``
The version of ``curl`` found.
+
+CURL CMake
+^^^^^^^^^^
+
+If CURL was built using the CMake buildsystem then it provides its own
+``CURLConfig.cmake`` file for use with the :command:`find_package` command's
+config mode. This module looks for this file and, if found,
+returns its results with no further action.
+
+Set ``CURL_NO_CURL_CMAKE`` to ``ON`` to disable this search.
+
#]=======================================================================]
+include(${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake)
+
+if(NOT CURL_NO_CURL_CMAKE)
+ # do a find package call to specifically look for the CMake version
+ # of curl
+ find_package(CURL QUIET NO_MODULE)
+ mark_as_advanced(CURL_DIR)
+
+ # if we found the CURL cmake package then we are done, and
+ # can print what we found and return.
+ if(CURL_FOUND)
+ find_package_handle_standard_args(CURL HANDLE_COMPONENTS CONFIG_MODE)
+ return()
+ endif()
+endif()
+
find_package(PkgConfig QUIET)
if(PKG_CONFIG_FOUND)
pkg_check_modules(PC_CURL QUIET libcurl)
@@ -139,7 +166,6 @@ if(CURL_FIND_COMPONENTS)
endforeach()
endif()
-include(${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake)
find_package_handle_standard_args(CURL
REQUIRED_VARS CURL_LIBRARY CURL_INCLUDE_DIR
VERSION_VAR CURL_VERSION_STRING
diff --git a/Modules/FindDCMTK.cmake b/Modules/FindDCMTK.cmake
index d48de08..b2e00df 100644
--- a/Modules/FindDCMTK.cmake
+++ b/Modules/FindDCMTK.cmake
@@ -102,7 +102,7 @@ set(_SAVED_DCMTK_DIR ${DCMTK_DIR})
# Step1: Attempt to find a version of DCMTK providing a DCMTKConfig.cmake file.
#
if(NOT DCMTK_FIND_QUIETLY)
- message(STATUS "Trying to find DCMTK expecting DCMTKConfig.cmake")
+ message(CHECK_START "Trying to find DCMTK expecting DCMTKConfig.cmake")
endif()
find_package(DCMTK QUIET NO_MODULE)
if(DCMTK_FOUND
@@ -110,12 +110,12 @@ if(DCMTK_FOUND
AND NOT "x" STREQUAL "x${DCMTK_INCLUDE_DIRS}")
if(NOT DCMTK_FIND_QUIETLY)
- message(STATUS "Trying to find DCMTK expecting DCMTKConfig.cmake - ok")
+ message(CHECK_PASS "ok")
endif()
return()
else()
if(NOT DCMTK_FIND_QUIETLY)
- message(STATUS "Trying to find DCMTK expecting DCMTKConfig.cmake - failed")
+ message(CHECK_FAIL "failed")
endif()
endif()
diff --git a/Modules/FindMFC.cmake b/Modules/FindMFC.cmake
index e366619..b8ca71b 100644
--- a/Modules/FindMFC.cmake
+++ b/Modules/FindMFC.cmake
@@ -31,7 +31,7 @@ if(MFC_ATTEMPT_TRY_COMPILE)
set(CHECK_INCLUDE_FILE_VAR "afxwin.h")
configure_file(${CMAKE_ROOT}/Modules/CheckIncludeFile.cxx.in
${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/CheckIncludeFile.cxx)
- message(STATUS "Looking for MFC")
+ message(CHECK_START "Looking for MFC")
# Try both shared and static as the root project may have set the /MT flag
try_compile(MFC_HAVE_MFC
${CMAKE_BINARY_DIR}
@@ -51,13 +51,13 @@ if(MFC_ATTEMPT_TRY_COMPILE)
OUTPUT_VARIABLE OUTPUT)
endif()
if(MFC_HAVE_MFC)
- message(STATUS "Looking for MFC - found")
+ message(CHECK_PASS "found")
set(MFC_HAVE_MFC 1 CACHE INTERNAL "Have MFC?")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if MFC exists passed with the following output:\n"
"${OUTPUT}\n\n")
else()
- message(STATUS "Looking for MFC - not found")
+ message(CHECK_FAIL "not found")
set(MFC_HAVE_MFC 0 CACHE INTERNAL "Have MFC?")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if MFC exists failed with the following output:\n"
diff --git a/Modules/FindPython/Support.cmake b/Modules/FindPython/Support.cmake
index b67d563..0d6d2fc 100644
--- a/Modules/FindPython/Support.cmake
+++ b/Modules/FindPython/Support.cmake
@@ -409,6 +409,7 @@ function (_PYTHON_VALIDATE_INTERPRETER)
if (_PVI_CHECK_EXISTS AND NOT EXISTS "${_${_PYTHON_PREFIX}_EXECUTABLE}")
# interpreter does not exist anymore
+ set (_${_PYTHON_PREFIX}_Interpreter_REASON_FAILURE "Cannot find the interpreter \"${_${_PYTHON_PREFIX}_EXECUTABLE}\"")
set_property (CACHE _${_PYTHON_PREFIX}_EXECUTABLE PROPERTY VALUE "_${_PYTHON_PREFIX}_EXECUTABLE-NOTFOUND")
return()
endif()
@@ -427,6 +428,7 @@ function (_PYTHON_VALIDATE_INTERPRETER)
endif()
if (NOT abi IN_LIST _${_PYTHON_PREFIX}_ABIFLAGS)
# incompatible ABI
+ set (_${_PYTHON_PREFIX}_Interpreter_REASON_FAILURE "Wrong ABI for the interpreter \"${_${_PYTHON_PREFIX}_EXECUTABLE}\"")
set_property (CACHE _${_PYTHON_PREFIX}_EXECUTABLE PROPERTY VALUE "_${_PYTHON_PREFIX}_EXECUTABLE-NOTFOUND")
return()
endif()
@@ -444,6 +446,11 @@ function (_PYTHON_VALIDATE_INTERPRETER)
OUTPUT_STRIP_TRAILING_WHITESPACE)
if (result OR (_PVI_EXACT AND NOT version VERSION_EQUAL expected_version) OR (version VERSION_LESS expected_version))
# interpreter not usable or has wrong major version
+ if (result)
+ set (_${_PYTHON_PREFIX}_Interpreter_REASON_FAILURE "Cannot use the interpreter \"${_${_PYTHON_PREFIX}_EXECUTABLE}\"")
+ else()
+ set (_${_PYTHON_PREFIX}_Interpreter_REASON_FAILURE "Wrong major version for the interpreter \"${_${_PYTHON_PREFIX}_EXECUTABLE}\"")
+ endif()
set_property (CACHE _${_PYTHON_PREFIX}_EXECUTABLE PROPERTY VALUE "_${_PYTHON_PREFIX}_EXECUTABLE-NOTFOUND")
return()
endif()
@@ -459,6 +466,11 @@ function (_PYTHON_VALIDATE_INTERPRETER)
OUTPUT_STRIP_TRAILING_WHITESPACE)
if (result OR NOT version EQUAL _${_PYTHON_PREFIX}_REQUIRED_VERSION_MAJOR)
# interpreter not usable or has wrong major version
+ if (result)
+ set (_${_PYTHON_PREFIX}_Interpreter_REASON_FAILURE "Cannot use the interpreter \"${_${_PYTHON_PREFIX}_EXECUTABLE}\"")
+ else()
+ set (_${_PYTHON_PREFIX}_Interpreter_REASON_FAILURE "Wrong major version for the interpreter \"${_${_PYTHON_PREFIX}_EXECUTABLE}\"")
+ endif()
set_property (CACHE _${_PYTHON_PREFIX}_EXECUTABLE PROPERTY VALUE "_${_PYTHON_PREFIX}_EXECUTABLE-NOTFOUND")
return()
endif()
@@ -476,6 +488,11 @@ function (_PYTHON_VALIDATE_INTERPRETER)
OUTPUT_STRIP_TRAILING_WHITESPACE)
if (result OR NOT size EQUAL CMAKE_SIZEOF_VOID_P)
# interpreter not usable or has wrong architecture
+ if (result)
+ set (_${_PYTHON_PREFIX}_Interpreter_REASON_FAILURE "Cannot use the interpreter \"${_${_PYTHON_PREFIX}_EXECUTABLE}\"")
+ else()
+ set (_${_PYTHON_PREFIX}_Interpreter_REASON_FAILURE "Wrong architecture for the interpreter \"${_${_PYTHON_PREFIX}_EXECUTABLE}\"")
+ endif()
set_property (CACHE _${_PYTHON_PREFIX}_EXECUTABLE PROPERTY VALUE "_${_PYTHON_PREFIX}_EXECUTABLE-NOTFOUND")
return()
endif()
@@ -500,6 +517,7 @@ function (_PYTHON_VALIDATE_COMPILER expected_version)
if (_PVC_CHECK_EXISTS AND NOT EXISTS "${_${_PYTHON_PREFIX}_COMPILER}")
# Compiler does not exist anymore
+ set (_${_PYTHON_PREFIX}_Compiler_REASON_FAILURE "Cannot find the compiler \"${_${_PYTHON_PREFIX}_COMPILER}\"")
set_property (CACHE _${_PYTHON_PREFIX}_COMPILER PROPERTY VALUE "_${_PYTHON_PREFIX}_COMPILER-NOTFOUND")
return()
endif()
@@ -526,6 +544,11 @@ function (_PYTHON_VALIDATE_COMPILER expected_version)
if (result OR (_PVC_EXACT AND NOT version VERSION_EQUAL expected_version) OR (version VERSION_LESS expected_version))
# Compiler not usable or has wrong version
+ if (result)
+ set (_${_PYTHON_PREFIX}_Compiler_REASON_FAILURE "Cannot use the compiler \"${_${_PYTHON_PREFIX}_COMPILER}\"")
+ else()
+ set (_${_PYTHON_PREFIX}_Compiler_REASON_FAILURE "Wrong version for the compiler \"${_${_PYTHON_PREFIX}_COMPILER}\"")
+ endif()
set_property (CACHE _${_PYTHON_PREFIX}_COMPILER PROPERTY VALUE "_${_PYTHON_PREFIX}_COMPILER-NOTFOUND")
endif()
endfunction()
@@ -545,6 +568,7 @@ function (_PYTHON_VALIDATE_LIBRARY)
if (_PVL_CHECK_EXISTS AND NOT EXISTS "${_${_PYTHON_PREFIX}_LIBRARY_RELEASE}")
# library does not exist anymore
+ set (_${_PYTHON_PREFIX}_Development_REASON_FAILURE "Cannot find the library \"${_${_PYTHON_PREFIX}_LIBRARY_RELEASE}\"")
set_property (CACHE _${_PYTHON_PREFIX}_LIBRARY_RELEASE PROPERTY VALUE "_${_PYTHON_PREFIX}_LIBRARY_RELEASE-NOTFOUND")
if (WIN32)
set_property (CACHE _${_PYTHON_PREFIX}_LIBRARY_DEBUG PROPERTY VALUE "_${_PYTHON_PREFIX}_LIBRARY_DEBUG-NOTFOUND")
@@ -558,16 +582,19 @@ function (_PYTHON_VALIDATE_LIBRARY)
if (DEFINED _${_PYTHON_PREFIX}_FIND_ABI AND NOT lib_ABI IN_LIST _${_PYTHON_PREFIX}_ABIFLAGS)
# incompatible ABI
+ set (_${_PYTHON_PREFIX}_Development_REASON_FAILURE "Wrong ABI for the library \"${_${_PYTHON_PREFIX}_LIBRARY_RELEASE}\"")
set_property (CACHE _${_PYTHON_PREFIX}_LIBRARY_RELEASE PROPERTY VALUE "_${_PYTHON_PREFIX}_LIBRARY_RELEASE-NOTFOUND")
else()
if (expected_version)
if ((_PVL_EXACT AND NOT lib_VERSION VERSION_EQUAL expected_version) OR (lib_VERSION VERSION_LESS expected_version))
# library has wrong version
+ set (_${_PYTHON_PREFIX}_Development_REASON_FAILURE "Wrong version for the library \"${_${_PYTHON_PREFIX}_LIBRARY_RELEASE}\"")
set_property (CACHE _${_PYTHON_PREFIX}_LIBRARY_RELEASE PROPERTY VALUE "_${_PYTHON_PREFIX}_LIBRARY_RELEASE-NOTFOUND")
endif()
else()
if (NOT lib_VERSION_MAJOR VERSION_EQUAL _${_PYTHON_PREFIX}_REQUIRED_VERSION_MAJOR)
# library has wrong major version
+ set (_${_PYTHON_PREFIX}_Development_REASON_FAILURE "Wrong major version for the library \"${_${_PYTHON_PREFIX}_LIBRARY_RELEASE}\"")
set_property (CACHE _${_PYTHON_PREFIX}_LIBRARY_RELEASE PROPERTY VALUE "_${_PYTHON_PREFIX}_LIBRARY_RELEASE-NOTFOUND")
endif()
endif()
@@ -596,6 +623,7 @@ function (_PYTHON_VALIDATE_INCLUDE_DIR)
if (_PVID_CHECK_EXISTS AND NOT EXISTS "${_${_PYTHON_PREFIX}_INCLUDE_DIR}")
# include file does not exist anymore
+ set (_${_PYTHON_PREFIX}_Development_REASON_FAILURE "Cannot find the directory \"${_${_PYTHON_PREFIX}_INCLUDE_DIR}\"")
set_property (CACHE _${_PYTHON_PREFIX}_INCLUDE_DIR PROPERTY VALUE "_${_PYTHON_PREFIX}_INCLUDE_DIR-NOTFOUND")
return()
endif()
@@ -605,16 +633,19 @@ function (_PYTHON_VALIDATE_INCLUDE_DIR)
if (DEFINED _${_PYTHON_PREFIX}_FIND_ABI AND NOT inc_ABI IN_LIST _${_PYTHON_PREFIX}_ABIFLAGS)
# incompatible ABI
+ set (_${_PYTHON_PREFIX}_Development_REASON_FAILURE "Wrong ABI for the directory \"${_${_PYTHON_PREFIX}_INCLUDE_DIR}\"")
set_property (CACHE _${_PYTHON_PREFIX}_INCLUDE_DIR PROPERTY VALUE "_${_PYTHON_PREFIX}_INCLUDE_DIR-NOTFOUND")
else()
if (expected_version)
if ((_PVID_EXACT AND NOT inc_VERSION VERSION_EQUAL expected_version) OR (inc_VERSION VERSION_LESS expected_version))
# include dir has wrong version
+ set (_${_PYTHON_PREFIX}_Development_REASON_FAILURE "Wrong version for the directory \"${_${_PYTHON_PREFIX}_INCLUDE_DIR}\"")
set_property (CACHE _${_PYTHON_PREFIX}_INCLUDE_DIR PROPERTY VALUE "_${_PYTHON_PREFIX}_INCLUDE_DIR-NOTFOUND")
endif()
else()
if (NOT inc_VERSION_MAJOR VERSION_EQUAL _${_PYTHON_PREFIX}_REQUIRED_VERSION_MAJOR)
# include dir has wrong major version
+ set (_${_PYTHON_PREFIX}_Development_REASON_FAILURE "Wrong major version for the directory \"${_${_PYTHON_PREFIX}_INCLUDE_DIR}\"")
set_property (CACHE _${_PYTHON_PREFIX}_INCLUDE_DIR PROPERTY VALUE "_${_PYTHON_PREFIX}_INCLUDE_DIR-NOTFOUND")
endif()
endif()
@@ -836,6 +867,10 @@ endif()
unset (_${_PYTHON_PREFIX}_REQUIRED_VARS)
unset (_${_PYTHON_PREFIX}_CACHED_VARS)
+unset (_${_PYTHON_PREFIX}_Interpreter_REASON_FAILURE)
+unset (_${_PYTHON_PREFIX}_Compiler_REASON_FAILURE)
+unset (_${_PYTHON_PREFIX}_Development_REASON_FAILURE)
+unset (_${_PYTHON_PREFIX}_NumPy_REASON_FAILURE)
# first step, search for the interpreter
@@ -1161,6 +1196,7 @@ if ("Interpreter" IN_LIST ${_PYTHON_PREFIX}_FIND_COMPONENTS)
# Interpreter is not usable
set (_${_PYTHON_PREFIX}_EXECUTABLE_USABLE FALSE)
unset (${_PYTHON_PREFIX}_VERSION)
+ set (_${_PYTHON_PREFIX}_Interpreter_REASON_FAILURE "Cannot run the interpreter \"${_${_PYTHON_PREFIX}_EXECUTABLE}\"")
endif()
endif()
@@ -1416,6 +1452,7 @@ if ("Compiler" IN_LIST ${_PYTHON_PREFIX}_FIND_COMPONENTS)
else()
# compiler not usable
set (_${_PYTHON_PREFIX}_COMPILER_USABLE FALSE)
+ set (_${_PYTHON_PREFIX}_Compiler_REASON_FAILURE "Cannot run the compiler \"${_${_PYTHON_PREFIX}_COMPILER}\"")
endif()
file (REMOVE_RECURSE "${_${_PYTHON_PREFIX}_VERSION_DIR}")
endif()
@@ -1914,6 +1951,7 @@ if ("Development" IN_LIST ${_PYTHON_PREFIX}_FIND_COMPONENTS
set (${_PYTHON_PREFIX}_LIBRARY_RELEASE "${_${_PYTHON_PREFIX}_LIBRARY_RELEASE}" CACHE FILEPATH "Path to a library." FORCE)
if (_${_PYTHON_PREFIX}_LIBRARY_RELEASE AND NOT EXISTS "${_${_PYTHON_PREFIX}_LIBRARY_RELEASE}")
+ set (_${_PYTHON_PREFIX}_Development_REASON_FAILURE "Cannot find the library \"${_${_PYTHON_PREFIX}_LIBRARY_RELEASE}\"")
set_property (CACHE _${_PYTHON_PREFIX}_LIBRARY_RELEASE PROPERTY VALUE "_${_PYTHON_PREFIX}_LIBRARY_RELEASE-NOTFOUND")
endif()
@@ -2046,6 +2084,7 @@ if ("Development" IN_LIST ${_PYTHON_PREFIX}_FIND_COMPONENTS
set (${_PYTHON_PREFIX}_INCLUDE_DIRS "${_${_PYTHON_PREFIX}_INCLUDE_DIR}")
if (_${_PYTHON_PREFIX}_INCLUDE_DIR AND NOT EXISTS "${_${_PYTHON_PREFIX}_INCLUDE_DIR}")
+ set (_${_PYTHON_PREFIX}_Development_REASON_FAILURE "Cannot find the directory \"${_${_PYTHON_PREFIX}_INCLUDE_DIR}\"")
set_property (CACHE _${_PYTHON_PREFIX}_INCLUDE_DIR PROPERTY VALUE "_${_PYTHON_PREFIX}_INCLUDE_DIR-NOTFOUND")
endif()
@@ -2169,6 +2208,7 @@ if ("NumPy" IN_LIST ${_PYTHON_PREFIX}_FIND_COMPONENTS AND ${_PYTHON_PREFIX}_Inte
set (${_PYTHON_PREFIX}_NumPy_INCLUDE_DIRS "${_${_PYTHON_PREFIX}_NumPy_INCLUDE_DIR}")
if(_${_PYTHON_PREFIX}_NumPy_INCLUDE_DIR AND NOT EXISTS "${_${_PYTHON_PREFIX}_NumPy_INCLUDE_DIR}")
+ set (_${_PYTHON_PREFIX}_NumPy_REASON_FAILURE "Cannot find the directory \"${_${_PYTHON_PREFIX}_NumPy_INCLUDE_DIR}\"")
set_property (CACHE _${_PYTHON_PREFIX}_NumPy_INCLUDE_DIR PROPERTY VALUE "_${_PYTHON_PREFIX}_NumPy_INCLUDE_DIR-NOTFOUND")
endif()
@@ -2207,11 +2247,19 @@ if (${_PYTHON_PREFIX}_VERSION_MAJOR AND
_python_display_failure ("Could NOT find ${_PYTHON_PREFIX}: Found unsuitable major version \"${${_PYTHON_PREFIX}_VERSION_MAJOR}\", but required major version is exact version \"${_${_PYTHON_PREFIX}_REQUIRED_VERSION_MAJOR}\"")
endif()
+unset (_${_PYTHON_PREFIX}_REASON_FAILURE)
+foreach (_${_PYTHON_PREFIX}_COMPONENT IN ITEMS Interpreter Compiler Development NumPy)
+ if (_${_PYTHON_PREFIX}_${_${_PYTHON_PREFIX}_COMPONENT}_REASON_FAILURE)
+ string (APPEND _${_PYTHON_PREFIX}_REASON_FAILURE "\n ${_${_PYTHON_PREFIX}_COMPONENT}: ${_${_PYTHON_PREFIX}_${_${_PYTHON_PREFIX}_COMPONENT}_REASON_FAILURE}")
+ endif()
+endforeach()
+
include (${CMAKE_CURRENT_LIST_DIR}/../FindPackageHandleStandardArgs.cmake)
find_package_handle_standard_args (${_PYTHON_PREFIX}
REQUIRED_VARS ${_${_PYTHON_PREFIX}_REQUIRED_VARS}
VERSION_VAR ${_PYTHON_PREFIX}_VERSION
- HANDLE_COMPONENTS)
+ HANDLE_COMPONENTS
+ REASON_FAILURE_MESSAGE "${_${_PYTHON_PREFIX}_REASON_FAILURE}")
# Create imported targets and helper functions
if(_${_PYTHON_PREFIX}_CMAKE_ROLE STREQUAL "PROJECT")
diff --git a/Modules/FindThreads.cmake b/Modules/FindThreads.cmake
index d39fe33..1780511 100644
--- a/Modules/FindThreads.cmake
+++ b/Modules/FindThreads.cmake
@@ -90,7 +90,7 @@ macro(_check_pthreads_flag)
if(NOT Threads_FOUND)
# If we did not find a thread library look for -pthread compiler option.
if(NOT DEFINED THREADS_HAVE_PTHREAD_ARG)
- message(STATUS "Check if compiler accepts -pthread")
+ message(CHECK_START "Check if compiler accepts -pthread")
if(CMAKE_C_COMPILER_LOADED)
set(_threads_src ${CMAKE_CURRENT_LIST_DIR}/CheckForPthreads.c)
elseif(CMAKE_CXX_COMPILER_LOADED)
@@ -106,9 +106,9 @@ macro(_check_pthreads_flag)
if(THREADS_HAVE_PTHREAD_ARG)
set(Threads_FOUND TRUE)
- message(STATUS "Check if compiler accepts -pthread - yes")
+ message(CHECK_PASS "yes")
else()
- message(STATUS "Check if compiler accepts -pthread - no")
+ message(CHECK_FAIL "no")
file(APPEND
${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if compiler accepts -pthread failed with the following output:\n${OUTPUT}\n\n")
diff --git a/Modules/FindwxWidgets.cmake b/Modules/FindwxWidgets.cmake
index c813ead..fd69e21 100644
--- a/Modules/FindwxWidgets.cmake
+++ b/Modules/FindwxWidgets.cmake
@@ -505,6 +505,8 @@ if(wxWidgets_FIND_STYLE STREQUAL "win32")
elseif(MSVC)
set(_WX_TOOL vc)
set(_WX_TOOLVER ${MSVC_TOOLSET_VERSION})
+ # support for a lib/vc14x_x64_dll/ path from wxW 3.1.3 distribution
+ string(REGEX REPLACE ".$" "x" _WX_TOOLVERx ${_WX_TOOLVER})
if(CMAKE_SIZEOF_VOID_P EQUAL 8)
set(_WX_ARCH _x64)
endif()
@@ -523,9 +525,13 @@ if(wxWidgets_FIND_STYLE STREQUAL "win32")
PATHS
${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_TOOLVER}_xp${_WX_ARCH}_dll # prefer shared
${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_TOOLVER}${_WX_ARCH}_dll # prefer shared
+ ${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_TOOLVERx}_xp${_WX_ARCH}_dll # prefer shared
+ ${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_TOOLVERx}${_WX_ARCH}_dll # prefer shared
${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_ARCH}_dll # prefer shared
${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_TOOLVER}_xp${_WX_ARCH}_lib
${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_TOOLVER}${_WX_ARCH}_lib
+ ${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_TOOLVERx}_xp${_WX_ARCH}_lib
+ ${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_TOOLVERx}${_WX_ARCH}_lib
${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_ARCH}_lib
DOC "Path to wxWidgets libraries"
NO_DEFAULT_PATH
@@ -544,9 +550,13 @@ if(wxWidgets_FIND_STYLE STREQUAL "win32")
PATHS
${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_TOOLVER}_xp${_WX_ARCH}_lib # prefer static
${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_TOOLVER}${_WX_ARCH}_lib # prefer static
+ ${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_TOOLVERx}_xp${_WX_ARCH}_lib # prefer static
+ ${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_TOOLVERx}${_WX_ARCH}_lib # prefer static
${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_ARCH}_lib # prefer static
${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_TOOLVER}_xp${_WX_ARCH}_dll
${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_TOOLVER}${_WX_ARCH}_dll
+ ${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_TOOLVERx}_xp${_WX_ARCH}_dll
+ ${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_TOOLVERx}${_WX_ARCH}_dll
${WX_ROOT_DIR}/lib/${_WX_TOOL}${_WX_ARCH}_dll
DOC "Path to wxWidgets libraries"
NO_DEFAULT_PATH
diff --git a/Modules/FortranCInterface.cmake b/Modules/FortranCInterface.cmake
index 893a96f..547346b 100644
--- a/Modules/FortranCInterface.cmake
+++ b/Modules/FortranCInterface.cmake
@@ -341,7 +341,7 @@ function(FortranCInterface_VERIFY)
# Build the verification project if not yet built.
if(NOT DEFINED FortranCInterface_VERIFIED_${lang})
set(_desc "Verifying Fortran/${lang} Compiler Compatibility")
- message(STATUS "${_desc}")
+ message(CHECK_START "${_desc}")
# Build a sample project which reports symbols.
set(CMAKE_TRY_COMPILE_CONFIGURATION Release)
@@ -363,12 +363,12 @@ function(FortranCInterface_VERIFY)
# Report results.
if(FortranCInterface_VERIFY_${lang}_COMPILED)
- message(STATUS "${_desc} - Success")
+ message(CHECK_PASS "Success")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"${_desc} passed with the following output:\n${_output}\n\n")
set(FortranCInterface_VERIFIED_${lang} 1 CACHE INTERNAL "Fortran/${lang} compatibility")
else()
- message(STATUS "${_desc} - Failed")
+ message(CHECK_FAIL "Failed")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"${_desc} failed with the following output:\n${_output}\n\n")
set(FortranCInterface_VERIFIED_${lang} 0 CACHE INTERNAL "Fortran/${lang} compatibility")
diff --git a/Modules/FortranCInterface/Detect.cmake b/Modules/FortranCInterface/Detect.cmake
index 7789785..33de6c6 100644
--- a/Modules/FortranCInterface/Detect.cmake
+++ b/Modules/FortranCInterface/Detect.cmake
@@ -15,7 +15,7 @@ if(${FortranCInterface_BINARY_DIR}/Input.cmake
OR ${CMAKE_CURRENT_LIST_FILE}
IS_NEWER_THAN ${FortranCInterface_BINARY_DIR}/Output.cmake
)
- message(STATUS "Detecting Fortran/C Interface")
+ message(CHECK_START "Detecting Fortran/C Interface")
else()
return()
endif()
@@ -172,7 +172,9 @@ if(FortranCInterface_GLOBAL_FOUND)
else()
set(_result "Found GLOBAL but not MODULE mangling")
endif()
+ set(_result_type CHECK_PASS)
elseif(NOT _result)
set(_result "Failed to recognize symbols")
+ set(_result_type CHECK_FAIL)
endif()
-message(STATUS "Detecting Fortran/C Interface - ${_result}")
+message(${_result_type} "${_result}")
diff --git a/Modules/Internal/CPack/NSIS.template.in b/Modules/Internal/CPack/NSIS.template.in
index f75ae78..c1db769 100644
--- a/Modules/Internal/CPack/NSIS.template.in
+++ b/Modules/Internal/CPack/NSIS.template.in
@@ -642,7 +642,7 @@ Section "-Core installation"
WriteRegStr SHCTX "Software\@CPACK_PACKAGE_VENDOR@\@CPACK_PACKAGE_INSTALL_REGISTRY_KEY@" "" $INSTDIR
;Create uninstaller
- WriteUninstaller "$INSTDIR\Uninstall.exe"
+ WriteUninstaller "$INSTDIR\@CPACK_NSIS_UNINSTALL_NAME@.exe"
Push "DisplayName"
Push "@CPACK_NSIS_DISPLAY_NAME@"
Call ConditionalAddToRegisty
@@ -653,7 +653,7 @@ Section "-Core installation"
Push "@CPACK_PACKAGE_VENDOR@"
Call ConditionalAddToRegisty
Push "UninstallString"
- Push "$INSTDIR\Uninstall.exe"
+ Push "$INSTDIR\@CPACK_NSIS_UNINSTALL_NAME@.exe"
Call ConditionalAddToRegisty
Push "NoRepair"
Push "1"
@@ -690,7 +690,7 @@ Section "-Core installation"
CreateDirectory "$SMPROGRAMS\$STARTMENU_FOLDER"
@CPACK_NSIS_CREATE_ICONS@
@CPACK_NSIS_CREATE_ICONS_EXTRA@
- CreateShortCut "$SMPROGRAMS\$STARTMENU_FOLDER\Uninstall.lnk" "$INSTDIR\Uninstall.exe"
+ CreateShortCut "$SMPROGRAMS\$STARTMENU_FOLDER\Uninstall.lnk" "$INSTDIR\@CPACK_NSIS_UNINSTALL_NAME@.exe"
;Read a value from an InstallOptions INI file
!insertmacro MUI_INSTALLOPTIONS_READ $DO_NOT_ADD_TO_PATH "NSIS.InstallOptions.ini" "Field 2" "State"
@@ -829,7 +829,7 @@ Section "Uninstall"
!endif
;Remove the uninstaller itself.
- Delete "$INSTDIR\Uninstall.exe"
+ Delete "$INSTDIR\@CPACK_NSIS_UNINSTALL_NAME@.exe"
DeleteRegKey SHCTX "Software\Microsoft\Windows\CurrentVersion\Uninstall\@CPACK_PACKAGE_INSTALL_REGISTRY_KEY@"
;Remove the installation directory if it is empty.
diff --git a/Modules/Platform/Android-Clang.cmake b/Modules/Platform/Android-Clang.cmake
index 847178f..759448b 100644
--- a/Modules/Platform/Android-Clang.cmake
+++ b/Modules/Platform/Android-Clang.cmake
@@ -24,6 +24,14 @@ if(CMAKE_SYSTEM_VERSION EQUAL 1)
return()
endif()
+# Natively compiling on an Android host doesn't use the NDK cross-compilation
+# tools.
+if(CMAKE_HOST_SYSTEM_NAME STREQUAL "Android")
+ macro(__android_compiler_clang lang)
+ endmacro()
+ return()
+endif()
+
include(Platform/Android-Common)
# The NDK toolchain configuration files at:
diff --git a/Modules/Platform/Android-Determine.cmake b/Modules/Platform/Android-Determine.cmake
index e7c1b48..2225897 100644
--- a/Modules/Platform/Android-Determine.cmake
+++ b/Modules/Platform/Android-Determine.cmake
@@ -18,6 +18,12 @@ if(CMAKE_SYSTEM_VERSION EQUAL 1)
return()
endif()
+# Natively compiling on an Android host doesn't use the NDK cross-compilation
+# tools.
+if(CMAKE_HOST_SYSTEM_NAME STREQUAL "Android")
+ return()
+endif()
+
cmake_policy(PUSH)
cmake_policy(SET CMP0057 NEW) # if IN_LIST
diff --git a/Modules/Platform/Android-Initialize.cmake b/Modules/Platform/Android-Initialize.cmake
index a5d2820..b90dd7a 100644
--- a/Modules/Platform/Android-Initialize.cmake
+++ b/Modules/Platform/Android-Initialize.cmake
@@ -24,6 +24,12 @@ if(CMAKE_ANDROID_NDK_TOOLCHAIN_UNIFIED)
return()
endif()
+# Natively compiling on an Android host doesn't use the NDK cross-compilation
+# tools.
+if(CMAKE_HOST_SYSTEM_NAME STREQUAL "Android")
+ return()
+endif()
+
if(NOT CMAKE_SYSROOT)
if(CMAKE_ANDROID_NDK)
set(CMAKE_SYSROOT "${CMAKE_ANDROID_NDK}/platforms/android-${CMAKE_SYSTEM_VERSION}/arch-${CMAKE_ANDROID_ARCH}")
diff --git a/Modules/Platform/Android.cmake b/Modules/Platform/Android.cmake
index f08f841..8ffa1b2 100644
--- a/Modules/Platform/Android.cmake
+++ b/Modules/Platform/Android.cmake
@@ -2,6 +2,11 @@ include(Platform/Linux)
set(ANDROID 1)
+# Natively compiling on an Android host doesn't need these flags to be reset.
+if(CMAKE_HOST_SYSTEM_NAME STREQUAL "Android")
+ return()
+endif()
+
# Conventionally Android does not use versioned soname
# But in modern versions it is acceptable
if(NOT DEFINED CMAKE_PLATFORM_NO_VERSIONED_SONAME)
diff --git a/Modules/Platform/Android/Determine-Compiler.cmake b/Modules/Platform/Android/Determine-Compiler.cmake
index 5c6b97b..f9c2d89 100644
--- a/Modules/Platform/Android/Determine-Compiler.cmake
+++ b/Modules/Platform/Android/Determine-Compiler.cmake
@@ -31,6 +31,16 @@ elseif(CMAKE_HOST_SYSTEM_NAME STREQUAL "Linux")
set(_ANDROID_HOST_EXT "")
elseif(CMAKE_HOST_SYSTEM_NAME STREQUAL "Windows")
set(_ANDROID_HOST_EXT ".exe")
+elseif(CMAKE_HOST_SYSTEM_NAME STREQUAL "Android")
+ # Natively compiling on an Android host doesn't use the NDK cross-compilation
+ # tools.
+ macro(__android_determine_compiler lang)
+ # Do nothing
+ endmacro()
+ if(NOT CMAKE_CXX_COMPILER_NAMES)
+ set(CMAKE_CXX_COMPILER_NAMES c++)
+ endif()
+ return()
else()
message(FATAL_ERROR "Android: Builds hosted on '${CMAKE_HOST_SYSTEM_NAME}' not supported.")
endif()
diff --git a/Modules/Platform/Apple-GNU.cmake b/Modules/Platform/Apple-GNU.cmake
index 0eb8168..9572736 100644
--- a/Modules/Platform/Apple-GNU.cmake
+++ b/Modules/Platform/Apple-GNU.cmake
@@ -19,17 +19,17 @@ endmacro()
macro(cmake_gnu_set_sysroot_flag lang)
if(NOT DEFINED CMAKE_${lang}_SYSROOT_FLAG)
set(_doc "${lang} compiler has -isysroot")
- message(STATUS "Checking whether ${_doc}")
+ message(CHECK_START "Checking whether ${_doc}")
execute_process(
COMMAND ${CMAKE_${lang}_COMPILER} "-v" "--help"
OUTPUT_VARIABLE _gcc_help
ERROR_VARIABLE _gcc_help
)
if("${_gcc_help}" MATCHES "isysroot")
- message(STATUS "Checking whether ${_doc} - yes")
+ message(CHECK_PASS "yes")
set(CMAKE_${lang}_SYSROOT_FLAG "-isysroot")
else()
- message(STATUS "Checking whether ${_doc} - no")
+ message(CHECK_FAIL "no")
set(CMAKE_${lang}_SYSROOT_FLAG "")
endif()
set(CMAKE_${lang}_SYSROOT_FLAG_CODE "set(CMAKE_${lang}_SYSROOT_FLAG \"${CMAKE_${lang}_SYSROOT_FLAG}\")")
@@ -39,17 +39,17 @@ endmacro()
macro(cmake_gnu_set_osx_deployment_target_flag lang)
if(NOT DEFINED CMAKE_${lang}_OSX_DEPLOYMENT_TARGET_FLAG)
set(_doc "${lang} compiler supports OSX deployment target flag")
- message(STATUS "Checking whether ${_doc}")
+ message(CHECK_START "Checking whether ${_doc}")
execute_process(
COMMAND ${CMAKE_${lang}_COMPILER} "-v" "--help"
OUTPUT_VARIABLE _gcc_help
ERROR_VARIABLE _gcc_help
)
if("${_gcc_help}" MATCHES "macosx-version-min")
- message(STATUS "Checking whether ${_doc} - yes")
+ message(CHECK_PASS "yes")
set(CMAKE_${lang}_OSX_DEPLOYMENT_TARGET_FLAG "-mmacosx-version-min=")
else()
- message(STATUS "Checking whether ${_doc} - no")
+ message(CHECK_FAIL "no")
set(CMAKE_${lang}_OSX_DEPLOYMENT_TARGET_FLAG "")
endif()
set(CMAKE_${lang}_OSX_DEPLOYMENT_TARGET_FLAG_CODE "set(CMAKE_${lang}_OSX_DEPLOYMENT_TARGET_FLAG \"${CMAKE_${lang}_OSX_DEPLOYMENT_TARGET_FLAG}\")")
diff --git a/Modules/TestBigEndian.cmake b/Modules/TestBigEndian.cmake
index 0c6e188..8a769b7 100644
--- a/Modules/TestBigEndian.cmake
+++ b/Modules/TestBigEndian.cmake
@@ -19,8 +19,8 @@ include(CheckTypeSize)
macro(TEST_BIG_ENDIAN VARIABLE)
if(NOT DEFINED HAVE_${VARIABLE})
- message(STATUS "Check if the system is big endian")
- message(STATUS "Searching 16 bit integer")
+ message(CHECK_START "Check if the system is big endian")
+ message(CHECK_START "Searching 16 bit integer")
if(CMAKE_C_COMPILER_LOADED)
set(_test_language "C")
@@ -32,19 +32,19 @@ macro(TEST_BIG_ENDIAN VARIABLE)
CHECK_TYPE_SIZE("unsigned short" CMAKE_SIZEOF_UNSIGNED_SHORT LANGUAGE ${_test_language})
if(CMAKE_SIZEOF_UNSIGNED_SHORT EQUAL 2)
- message(STATUS "Using unsigned short")
+ message(CHECK_PASS "Using unsigned short")
set(CMAKE_16BIT_TYPE "unsigned short")
else()
CHECK_TYPE_SIZE("unsigned int" CMAKE_SIZEOF_UNSIGNED_INT LANGUAGE ${_test_language})
if(CMAKE_SIZEOF_UNSIGNED_INT)
- message(STATUS "Using unsigned int")
+ message(CHECK_PASS "Using unsigned int")
set(CMAKE_16BIT_TYPE "unsigned int")
else()
CHECK_TYPE_SIZE("unsigned long" CMAKE_SIZEOF_UNSIGNED_LONG LANGUAGE ${_test_language})
if(CMAKE_SIZEOF_UNSIGNED_LONG)
- message(STATUS "Using unsigned long")
+ message(CHECK_PASS "Using unsigned long")
set(CMAKE_16BIT_TYPE "unsigned long")
else()
message(FATAL_ERROR "no suitable type found")
@@ -95,15 +95,16 @@ macro(TEST_BIG_ENDIAN VARIABLE)
if(CMAKE_TEST_ENDIANESS_STRINGS_LE)
set(${VARIABLE} 0 CACHE INTERNAL "Result of TEST_BIG_ENDIAN" FORCE)
- message(STATUS "Check if the system is big endian - little endian")
+ message(CHECK_PASS "little endian")
endif()
if(CMAKE_TEST_ENDIANESS_STRINGS_BE)
set(${VARIABLE} 1 CACHE INTERNAL "Result of TEST_BIG_ENDIAN" FORCE)
- message(STATUS "Check if the system is big endian - big endian")
+ message(CHECK_PASS "big endian")
endif()
if(NOT CMAKE_TEST_ENDIANESS_STRINGS_BE AND NOT CMAKE_TEST_ENDIANESS_STRINGS_LE)
+ message(CHECK_FAIL "TEST_BIG_ENDIAN found no result!")
message(SEND_ERROR "TEST_BIG_ENDIAN found no result!")
endif()
@@ -111,7 +112,7 @@ macro(TEST_BIG_ENDIAN VARIABLE)
"Determining if the system is big endian passed with the following output:\n${OUTPUT}\nTestEndianess.c:\n${TEST_ENDIANESS_FILE_CONTENT}\n\n")
else()
- message(STATUS "Check if the system is big endian - failed")
+ message(CHECK_FAIL "failed")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if the system is big endian failed with the following output:\n${OUTPUT}\nTestEndianess.c:\n${TEST_ENDIANESS_FILE_CONTENT}\n\n")
set(${VARIABLE})
diff --git a/Modules/TestCXXAcceptsFlag.cmake b/Modules/TestCXXAcceptsFlag.cmake
index 92a362e..ce505f3 100644
--- a/Modules/TestCXXAcceptsFlag.cmake
+++ b/Modules/TestCXXAcceptsFlag.cmake
@@ -23,19 +23,19 @@ Check if the CXX compiler accepts a flag.
macro(CHECK_CXX_ACCEPTS_FLAG FLAGS VARIABLE)
if(NOT DEFINED ${VARIABLE})
- message(STATUS "Checking to see if CXX compiler accepts flag ${FLAGS}")
+ message(CHECK_START "Checking to see if CXX compiler accepts flag ${FLAGS}")
try_compile(${VARIABLE}
${CMAKE_BINARY_DIR}
${CMAKE_ROOT}/Modules/DummyCXXFile.cxx
CMAKE_FLAGS -DCOMPILE_DEFINITIONS:STRING=${FLAGS}
OUTPUT_VARIABLE OUTPUT)
if(${VARIABLE})
- message(STATUS "Checking to see if CXX compiler accepts flag ${FLAGS} - yes")
+ message(CHECK_PASS "yes")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the CXX compiler accepts the flag ${FLAGS} passed with "
"the following output:\n${OUTPUT}\n\n")
else()
- message(STATUS "Checking to see if CXX compiler accepts flag ${FLAGS} - no")
+ message(CHECK_FAIL "no")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if the CXX compiler accepts the flag ${FLAGS} failed with "
"the following output:\n${OUTPUT}\n\n")
diff --git a/Modules/TestForANSIForScope.cmake b/Modules/TestForANSIForScope.cmake
index 272e4ec..0f2dc01 100644
--- a/Modules/TestForANSIForScope.cmake
+++ b/Modules/TestForANSIForScope.cmake
@@ -16,19 +16,19 @@ for-init-statement to the loop body.
#]=======================================================================]
if(NOT DEFINED CMAKE_ANSI_FOR_SCOPE)
- message(STATUS "Check for ANSI scope")
+ message(CHECK_START "Check for ANSI scope")
try_compile(CMAKE_ANSI_FOR_SCOPE ${CMAKE_BINARY_DIR}
${CMAKE_ROOT}/Modules/TestForAnsiForScope.cxx
OUTPUT_VARIABLE OUTPUT)
if (CMAKE_ANSI_FOR_SCOPE)
- message(STATUS "Check for ANSI scope - found")
+ message(CHECK_PASS "found")
set (CMAKE_NO_ANSI_FOR_SCOPE 0 CACHE INTERNAL
"Does the compiler support ansi for scope.")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the CXX compiler understands ansi for scopes passed with "
"the following output:\n${OUTPUT}\n\n")
else ()
- message(STATUS "Check for ANSI scope - not found")
+ message(CHECK_FAIL "not found")
set (CMAKE_NO_ANSI_FOR_SCOPE 1 CACHE INTERNAL
"Does the compiler support ansi for scope.")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
diff --git a/Modules/TestForSSTREAM.cmake b/Modules/TestForSSTREAM.cmake
index e70df00..545b7ec 100644
--- a/Modules/TestForSSTREAM.cmake
+++ b/Modules/TestForSSTREAM.cmake
@@ -15,19 +15,19 @@ check if the compiler supports the standard ANSI sstream header
#]=======================================================================]
if(NOT DEFINED CMAKE_HAS_ANSI_STRING_STREAM)
- message(STATUS "Check for sstream")
+ message(CHECK_START "Check for sstream")
try_compile(CMAKE_HAS_ANSI_STRING_STREAM ${CMAKE_BINARY_DIR}
${CMAKE_ROOT}/Modules/TestForSSTREAM.cxx
OUTPUT_VARIABLE OUTPUT)
if (CMAKE_HAS_ANSI_STRING_STREAM)
- message(STATUS "Check for sstream - found")
+ message(CHECK_PASS "found")
set (CMAKE_NO_ANSI_STRING_STREAM 0 CACHE INTERNAL
"Does the compiler support sstream")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the CXX compiler has sstream passed with "
"the following output:\n${OUTPUT}\n\n")
else ()
- message(STATUS "Check for sstream - not found")
+ message(CHECK_FAIL "not found")
set (CMAKE_NO_ANSI_STRING_STREAM 1 CACHE INTERNAL
"Does the compiler support sstream")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
diff --git a/Modules/TestForSTDNamespace.cmake b/Modules/TestForSTDNamespace.cmake
index 703e631..d101c83 100644
--- a/Modules/TestForSTDNamespace.cmake
+++ b/Modules/TestForSTDNamespace.cmake
@@ -15,19 +15,19 @@ check if the compiler supports std:: on stl classes
#]=======================================================================]
if(NOT DEFINED CMAKE_STD_NAMESPACE)
- message(STATUS "Check for STD namespace")
+ message(CHECK_START "Check for STD namespace")
try_compile(CMAKE_STD_NAMESPACE ${CMAKE_BINARY_DIR}
${CMAKE_ROOT}/Modules/TestForSTDNamespace.cxx
OUTPUT_VARIABLE OUTPUT)
if (CMAKE_STD_NAMESPACE)
- message(STATUS "Check for STD namespace - found")
+ message(CHECK_PASS "found")
set (CMAKE_NO_STD_NAMESPACE 0 CACHE INTERNAL
"Does the compiler support std::.")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the CXX compiler has std namespace passed with "
"the following output:\n${OUTPUT}\n\n")
else ()
- message(STATUS "Check for STD namespace - not found")
+ message(CHECK_FAIL "not found")
set (CMAKE_NO_STD_NAMESPACE 1 CACHE INTERNAL
"Does the compiler support std::.")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log