[Cmake-commits] CMake branch, master, updated. v3.10.0-457-gc5fdd66
Kitware Robot
kwrobot at kitware.com
Thu Nov 30 07:45:06 EST 2017
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".
The branch, master has been updated
via c5fdd66252a843eff182e6f6b773ef11a16e162b (commit)
via 3eee33012e10a77b6b337dc70b2dc6b2320c5ecc (commit)
from 868fdb439a2b984de3247cda5616991f6bf7c839 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=c5fdd66252a843eff182e6f6b773ef11a16e162b
commit c5fdd66252a843eff182e6f6b773ef11a16e162b
Merge: 868fdb4 3eee330
Author: Brad King <brad.king at kitware.com>
AuthorDate: Thu Nov 30 12:42:41 2017 +0000
Commit: Kitware Robot <kwrobot at kitware.com>
CommitDate: Thu Nov 30 07:42:45 2017 -0500
Merge topic 'CheckIncludeFiles-fix-src-name'
3eee3301 CheckIncludeFiles: Fix name of source file used for check
Acked-by: Kitware Robot <kwrobot at kitware.com>
Merge-request: !1538
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=3eee33012e10a77b6b337dc70b2dc6b2320c5ecc
commit 3eee33012e10a77b6b337dc70b2dc6b2320c5ecc
Author: Brad King <brad.king at kitware.com>
AuthorDate: Thu Nov 30 07:33:58 2017 -0500
Commit: Brad King <brad.king at kitware.com>
CommitDate: Thu Nov 30 07:37:35 2017 -0500
CheckIncludeFiles: Fix name of source file used for check
In commit 7669695a74 (CheckIncludeFiles: extend to allow a LANGUAGE
argument, 2017-11-08) the file name used for the check was accidentally
left as `${var}.c`, where `var` is not a variable we define. It was
passing tests by accidentally using just `.c` as the file name, but can
break in real projects that may leave `var` defined to something else.
The reference was taken from similar code in CheckTypeSize where the
variable names are different. Fix our reference to be `${VARIABLE}`.
diff --git a/Modules/CheckIncludeFiles.cmake b/Modules/CheckIncludeFiles.cmake
index 347231c..6cf9c49 100644
--- a/Modules/CheckIncludeFiles.cmake
+++ b/Modules/CheckIncludeFiles.cmake
@@ -60,9 +60,9 @@ macro(CHECK_INCLUDE_FILES INCLUDE VARIABLE)
endif()
if(_lang STREQUAL "C")
- set(src ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CheckIncludeFiles/${var}.c)
+ set(src ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CheckIncludeFiles/${VARIABLE}.c)
elseif(_lang STREQUAL "CXX")
- set(src ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CheckIncludeFiles/${var}.cpp)
+ set(src ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CheckIncludeFiles/${VARIABLE}.cpp)
else()
message(FATAL_ERROR "Unknown language:\n ${_lang}\nSupported languages: C, CXX.\n")
endif()
-----------------------------------------------------------------------
Summary of changes:
Modules/CheckIncludeFiles.cmake | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
hooks/post-receive
--
CMake
More information about the Cmake-commits
mailing list