[cmake-developers] Probable bug in message output from Modules/Platform/CYGWIN.cmake
Brad King
brad.king at kitware.com
Tue Apr 28 16:44:48 EDT 2015
On 04/28/2015 04:15 PM, Alan W. Irwin wrote:
> The problem is I am reporting the problem second-hand, and I don't
> have access to a Cygwin platform myself. But from the report I
> received the incorrect warning message occurs each time a different
> compiler is enabled.
The patch to plplot below removes most of the warnings for me.
-Brad
diff --git a/cmake/modules/language_support.cmake b/cmake/modules/language_support.cmake
index 2cf5c95..333eb99 100644
--- a/cmake/modules/language_support.cmake
+++ b/cmake/modules/language_support.cmake
@@ -12,7 +12,8 @@ if(ENABLE_workaround_9220)
function(workaround_9220 language language_works)
#message("DEBUG: language = ${language}")
set(text
- "project(test C)
+ "cmake_minimum_required(VERSION 3.0.2 FATAL_ERROR)
+project(test C)
# Locations where PLplot cmake build system first looks for cmake modules.
set(CMAKE_MODULE_PATH
${PROJECT_SOURCE_DIR}/cmake/modules
@@ -26,7 +27,6 @@ if(NOT CMAKE_PLATFORM_INFO_DIR)
message(STATUS 'CMAKE_PLATFORM_INFO_DIR = \${CMAKE_PLATFORM_INFO_DIR}')
endif(NOT CMAKE_PLATFORM_INFO_DIR)
-cmake_minimum_required(VERSION 3.0.2 FATAL_ERROR)
message(STATUS \"CMAKE_GENERATOR = ${CMAKE_GENERATOR}\")
#enable_language(${language} OPTIONAL)
enable_language(${language})
More information about the cmake-developers
mailing list