summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Help/command/add_library.rst7
-rw-r--r--Modules/FindOpenCL.cmake31
-rw-r--r--Modules/FindXercesC.cmake11
-rw-r--r--Source/CMakeVersion.cmake2
-rw-r--r--Source/cmHexFileConverter.cxx10
5 files changed, 38 insertions, 23 deletions
diff --git a/Help/command/add_library.rst b/Help/command/add_library.rst
index 5d31c7c..b7ba724 100644
--- a/Help/command/add_library.rst
+++ b/Help/command/add_library.rst
@@ -83,8 +83,11 @@ about the imported library are specified by setting properties whose names
begin in ``IMPORTED_`` and ``INTERFACE_``. The most important such
property is :prop_tgt:`IMPORTED_LOCATION` (and its per-configuration
variant :prop_tgt:`IMPORTED_LOCATION_<CONFIG>`) which specifies the
-location of the main library file on disk. See documentation of the
-``IMPORTED_*`` and ``INTERFACE_*`` properties for more information.
+location of the main library file on disk. Or, for object libraries,
+:prop_tgt:`IMPORTED_OBJECTS` (and :prop_tgt:`IMPORTED_OBJECTS_<CONFIG>`)
+specifies the locations of object files on disk.
+See documentation of the ``IMPORTED_*`` and ``INTERFACE_*`` properties
+for more information.
Object Libraries
^^^^^^^^^^^^^^^^
diff --git a/Modules/FindOpenCL.cmake b/Modules/FindOpenCL.cmake
index 297a5fb..fe162b4 100644
--- a/Modules/FindOpenCL.cmake
+++ b/Modules/FindOpenCL.cmake
@@ -119,16 +119,27 @@ if(WIN32)
OpenCL/common/lib/x64)
endif()
else()
- find_library(OpenCL_LIBRARY
- NAMES OpenCL
- PATHS
- ENV AMDAPPSDKROOT
- ENV CUDA_PATH
- PATH_SUFFIXES
- lib/x86_64
- lib/x64
- lib
- lib64)
+ if(CMAKE_SIZEOF_VOID_P EQUAL 4)
+ find_library(OpenCL_LIBRARY
+ NAMES OpenCL
+ PATHS
+ ENV AMDAPPSDKROOT
+ ENV CUDA_PATH
+ PATH_SUFFIXES
+ lib/x86
+ lib)
+ elseif(CMAKE_SIZEOF_VOID_P EQUAL 8)
+ find_library(OpenCL_LIBRARY
+ NAMES OpenCL
+ PATHS
+ ENV AMDAPPSDKROOT
+ ENV CUDA_PATH
+ PATH_SUFFIXES
+ lib/x86_64
+ lib/x64
+ lib
+ lib64)
+ endif()
endif()
set(OpenCL_LIBRARIES ${OpenCL_LIBRARY})
diff --git a/Modules/FindXercesC.cmake b/Modules/FindXercesC.cmake
index 51e68d5..267c164 100644
--- a/Modules/FindXercesC.cmake
+++ b/Modules/FindXercesC.cmake
@@ -59,6 +59,9 @@ function(_XercesC_GET_VERSION version_hdr)
endif()
set(XercesC_VERSION "${XercesC_MAJOR}.${XercesC_MINOR}.${XercesC_PATCH}" PARENT_SCOPE)
+ set(XercesC_VERSION_MAJOR "${XercesC_MAJOR}" PARENT_SCOPE)
+ set(XercesC_VERSION_MINOR "${XercesC_MINOR}" PARENT_SCOPE)
+ set(XercesC_VERSION_PATCH "${XercesC_PATCH}" PARENT_SCOPE)
else()
message(FATAL_ERROR "Include file ${version_hdr} does not exist or does not contain expected version information")
endif()
@@ -73,16 +76,20 @@ mark_as_advanced(XercesC_INCLUDE_DIR)
if(NOT XercesC_LIBRARY)
# Find all XercesC libraries
find_library(XercesC_LIBRARY_RELEASE
- NAMES "xerces-c" "xerces-c_3"
+ NAMES "xerces-c" "xerces-c_${XercesC_VERSION_MAJOR}"
DOC "Xerces-C++ libraries (release)")
find_library(XercesC_LIBRARY_DEBUG
- NAMES "xerces-cd" "xerces-c_3D" "xerces-c_3_1D"
+ NAMES "xerces-cd" "xerces-c_${XercesC_VERSION_MAJOR}D" "xerces-c_${XercesC_VERSION_MAJOR}_${XercesC_VERSION_MINOR}D"
DOC "Xerces-C++ libraries (debug)")
include(${CMAKE_CURRENT_LIST_DIR}/SelectLibraryConfigurations.cmake)
select_library_configurations(XercesC)
mark_as_advanced(XercesC_LIBRARY_RELEASE XercesC_LIBRARY_DEBUG)
endif()
+unset(XercesC_VERSION_MAJOR)
+unset(XercesC_VERSION_MINOR)
+unset(XercesC_VERSION_PATCH)
+
if(XercesC_INCLUDE_DIR)
_XercesC_GET_VERSION("${XercesC_INCLUDE_DIR}/xercesc/util/XercesVersion.hpp")
endif()
diff --git a/Source/CMakeVersion.cmake b/Source/CMakeVersion.cmake
index 7d7ef46..7504236 100644
--- a/Source/CMakeVersion.cmake
+++ b/Source/CMakeVersion.cmake
@@ -1,5 +1,5 @@
# CMake version number components.
set(CMake_VERSION_MAJOR 3)
set(CMake_VERSION_MINOR 12)
-set(CMake_VERSION_PATCH 20180716)
+set(CMake_VERSION_PATCH 20180717)
#set(CMake_VERSION_RC 1)
diff --git a/Source/cmHexFileConverter.cxx b/Source/cmHexFileConverter.cxx
index 8deb8c1..4e29f39 100644
--- a/Source/cmHexFileConverter.cxx
+++ b/Source/cmHexFileConverter.cxx
@@ -2,6 +2,7 @@
file Copyright.txt or https://cmake.org/licensing for details. */
#include "cmHexFileConverter.h"
+#include <ctype.h>
#include <stdio.h>
#include <string.h>
@@ -12,13 +13,6 @@
#define MOTOROLA_SREC_MIN_LINE_LENGTH (2 + 2 + 4 + 2)
#define MOTOROLA_SREC_MAX_LINE_LENGTH (2 + 2 + 8 + (256 * 2) + 2)
-// might go to SystemTools ?
-static bool cm_IsHexChar(char c)
-{
- return (((c >= '0') && (c <= '9')) || ((c >= 'a') && (c <= 'f')) ||
- ((c >= 'A') && (c <= 'F')));
-}
-
static unsigned int ChompStrlen(const char* line)
{
if (line == nullptr) {
@@ -169,7 +163,7 @@ cmHexFileConverter::FileType cmHexFileConverter::DetermineFileType(
}
for (unsigned int i = 1; i < slen; i++) {
- if (!cm_IsHexChar(buf[i])) {
+ if (!isxdigit(buf[i])) {
return Binary;
}
}