summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Help/release/dev/wix-root-description.rst7
-rw-r--r--Modules/CPackWIX.cmake11
-rw-r--r--Modules/Compiler/Intel-C.cmake8
-rw-r--r--Modules/ExternalProject.cmake1
-rw-r--r--Modules/FindCUDA.cmake5
-rw-r--r--Modules/FindHDF5.cmake2
-rw-r--r--Source/CMakeVersion.cmake2
-rw-r--r--Source/CPack/WiX/cmCPackWIXGenerator.cxx9
-rw-r--r--Source/kwsys/Directory.cxx31
-rw-r--r--Source/kwsys/SystemTools.cxx9
-rw-r--r--Source/kwsys/SystemTools.hxx.in1
-rw-r--r--Utilities/Sphinx/CMakeLists.txt19
12 files changed, 76 insertions, 29 deletions
diff --git a/Help/release/dev/wix-root-description.rst b/Help/release/dev/wix-root-description.rst
new file mode 100644
index 0000000..24afed2
--- /dev/null
+++ b/Help/release/dev/wix-root-description.rst
@@ -0,0 +1,7 @@
+wix-root-description
+--------------------
+
+* The CPack WIX generator now supports
+ :variable:`CPACK_WIX_ROOT_FEATURE_TITLE` and
+ :variable:`CPACK_WIX_ROOT_FEATURE_DESCRIPTION` to allow the specification
+ of a custom title and description for the root feature element.
diff --git a/Modules/CPackWIX.cmake b/Modules/CPackWIX.cmake
index 3c90561..10926c0 100644
--- a/Modules/CPackWIX.cmake
+++ b/Modules/CPackWIX.cmake
@@ -237,6 +237,17 @@
# * ARPURLUPDATEINFO - Update information URL
# * ARPHELPTELEPHONE - Help and support telephone number
# * ARPSIZE - Size (in kilobytes) of the application
+#
+# .. variable:: CPACK_WIX_ROOT_FEATURE_TITLE
+#
+# Sets the name of the root install feature in the WIX installer. Same as
+# CPACK_COMPONENT_<compName>_DISPLAY_NAME for components.
+#
+# .. variable:: CPACK_WIX_ROOT_FEATURE_DESCRIPTION
+#
+# Sets the description of the root install feature in the WIX installer. Same as
+# CPACK_COMPONENT_<compName>_DESCRIPTION for components.
+#
#=============================================================================
# Copyright 2014-2015 Kitware, Inc.
diff --git a/Modules/Compiler/Intel-C.cmake b/Modules/Compiler/Intel-C.cmake
index cf366da..1d09bd5 100644
--- a/Modules/Compiler/Intel-C.cmake
+++ b/Modules/Compiler/Intel-C.cmake
@@ -15,14 +15,14 @@ endif()
if (NOT CMAKE_C_COMPILER_VERSION VERSION_LESS 15.0.0)
set(CMAKE_C11_STANDARD_COMPILE_OPTION "${_std}=c11")
- set(CMAKE_C11_EXTENSION_COMPILE_OPTION "${_std}=c11")
+ set(CMAKE_C11_EXTENSION_COMPILE_OPTION "${_std}=gnu11")
endif()
-if (NOT CMAKE_C_COMPILER_VERSION VERSION_LESS 12.1)
+if (NOT CMAKE_C_COMPILER_VERSION VERSION_LESS 12.0)
set(CMAKE_C90_STANDARD_COMPILE_OPTION "${_std}=c89")
- set(CMAKE_C90_EXTENSION_COMPILE_OPTION "${_std}=c89")
+ set(CMAKE_C90_EXTENSION_COMPILE_OPTION "${_std}=gnu89")
set(CMAKE_C99_STANDARD_COMPILE_OPTION "${_std}=c99")
- set(CMAKE_C99_EXTENSION_COMPILE_OPTION "${_std}=c99")
+ set(CMAKE_C99_EXTENSION_COMPILE_OPTION "${_std}=gnu99")
endif()
if(NOT CMAKE_C_COMPILER_VERSION VERSION_LESS 12.1)
diff --git a/Modules/ExternalProject.cmake b/Modules/ExternalProject.cmake
index 755b4fb..44bf957 100644
--- a/Modules/ExternalProject.cmake
+++ b/Modules/ExternalProject.cmake
@@ -993,6 +993,7 @@ endif()
#
message(STATUS \"extracting... [analysis]\")
file(GLOB contents \"\${ut_dir}/*\")
+list(REMOVE_ITEM contents \"\${ut_dir}/.DS_Store\")
list(LENGTH contents n)
if(NOT n EQUAL 1 OR NOT IS_DIRECTORY \"\${contents}\")
set(contents \"\${ut_dir}\")
diff --git a/Modules/FindCUDA.cmake b/Modules/FindCUDA.cmake
index 6d9b833..d7c9d8a 100644
--- a/Modules/FindCUDA.cmake
+++ b/Modules/FindCUDA.cmake
@@ -621,7 +621,8 @@ if(NOT CUDA_TOOLKIT_ROOT_DIR AND NOT CMAKE_CROSSCOMPILING)
# Now search default paths
find_path(CUDA_TOOLKIT_ROOT_DIR
NAMES nvcc nvcc.exe
- PATHS /usr/local/bin
+ PATHS /opt/cuda/bin
+ /usr/local/bin
/usr/local/cuda/bin
DOC "Toolkit location."
)
@@ -817,7 +818,7 @@ if(CUDA_USE_STATIC_CUDA_RUNTIME)
unset(CMAKE_THREAD_PREFER_PTHREAD)
endif()
endif()
- if (NOT APPLE AND CUDA_VERSION VERSION_LESS "7.0")
+ if (UNIX AND NOT APPLE AND CUDA_VERSION VERSION_LESS "7.0")
# Before CUDA 7.0, there was librt that has things such as, clock_gettime, shm_open, and shm_unlink.
find_library(CUDA_rt_LIBRARY rt)
if (NOT CUDA_rt_LIBRARY)
diff --git a/Modules/FindHDF5.cmake b/Modules/FindHDF5.cmake
index 50e1892..a898386 100644
--- a/Modules/FindHDF5.cmake
+++ b/Modules/FindHDF5.cmake
@@ -332,7 +332,7 @@ macro( _HDF5_parse_compile_line
set( RE " -D([^ ]*)")
string( REGEX MATCHALL "${RE}" definition_flags "${${compile_line_var}}" )
foreach( DEF IN LISTS definition_flags )
- string( REGEX REPLACE "${RE}" "\\1" DEF "${DEF}" )
+ string( STRIP "${DEF}" DEF )
list( APPEND ${definitions} ${DEF} )
endforeach()
diff --git a/Source/CMakeVersion.cmake b/Source/CMakeVersion.cmake
index f203b3c..a742e33 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 6)
-set(CMake_VERSION_PATCH 20160802)
+set(CMake_VERSION_PATCH 20160803)
#set(CMake_VERSION_RC 1)
diff --git a/Source/CPack/WiX/cmCPackWIXGenerator.cxx b/Source/CPack/WiX/cmCPackWIXGenerator.cxx
index 97216c3..3ecc14d 100644
--- a/Source/CPack/WiX/cmCPackWIXGenerator.cxx
+++ b/Source/CPack/WiX/cmCPackWIXGenerator.cxx
@@ -464,7 +464,14 @@ bool cmCPackWIXGenerator::CreateWiXSourceFiles()
return false;
}
- featureDefinitions.AddAttribute("Title", cpackPackageName);
+ std::string featureTitle = cpackPackageName;
+ if (const char* title = GetOption("CPACK_WIX_ROOT_FEATURE_TITLE")) {
+ featureTitle = title;
+ }
+ featureDefinitions.AddAttribute("Title", featureTitle);
+ if (const char* desc = GetOption("CPACK_WIX_ROOT_FEATURE_DESCRIPTION")) {
+ featureDefinitions.AddAttribute("Description", desc);
+ }
featureDefinitions.AddAttribute("Level", "1");
this->Patch->ApplyFragment("#PRODUCTFEATURE", featureDefinitions);
diff --git a/Source/kwsys/Directory.cxx b/Source/kwsys/Directory.cxx
index c549792..15480e1 100644
--- a/Source/kwsys/Directory.cxx
+++ b/Source/kwsys/Directory.cxx
@@ -84,9 +84,9 @@ void Directory::Clear()
} // namespace KWSYS_NAMESPACE
-// First microsoft compilers
+// First Windows platforms
-#if defined(_MSC_VER) || defined(__WATCOMC__)
+#if defined(_WIN32) && !defined(__CYGWIN__)
#include <windows.h>
#include <io.h>
#include <ctype.h>
@@ -97,15 +97,25 @@ void Directory::Clear()
#include <sys/stat.h>
#include <sys/types.h>
+// Wide function names can vary depending on compiler:
+#ifdef __BORLANDC__
+# define _wfindfirst_func __wfindfirst
+# define _wfindnext_func __wfindnext
+#else
+# define _wfindfirst_func _wfindfirst
+# define _wfindnext_func _wfindnext
+#endif
+
namespace KWSYS_NAMESPACE
{
bool Directory::Load(const std::string& name)
{
this->Clear();
-#if _MSC_VER < 1300
+#if (defined(_MSC_VER) && _MSC_VER < 1300) || defined(__BORLANDC__)
+ // Older Visual C++ and Embarcadero compilers.
long srchHandle;
-#else
+#else // Newer Visual C++
intptr_t srchHandle;
#endif
char* buf;
@@ -132,7 +142,7 @@ bool Directory::Load(const std::string& name)
struct _wfinddata_t data; // data of current file
// Now put them into the file array
- srchHandle = _wfindfirst((wchar_t*)Encoding::ToWide(buf).c_str(), &data);
+ srchHandle = _wfindfirst_func((wchar_t*)Encoding::ToWide(buf).c_str(), &data);
delete [] buf;
if ( srchHandle == -1 )
@@ -145,16 +155,17 @@ bool Directory::Load(const std::string& name)
{
this->Internal->Files.push_back(Encoding::ToNarrow(data.name));
}
- while ( _wfindnext(srchHandle, &data) != -1 );
+ while ( _wfindnext_func(srchHandle, &data) != -1 );
this->Internal->Path = name;
return _findclose(srchHandle) != -1;
}
unsigned long Directory::GetNumberOfFilesInDirectory(const std::string& name)
{
-#if _MSC_VER < 1300
+#if (defined(_MSC_VER) && _MSC_VER < 1300) || defined(__BORLANDC__)
+ // Older Visual C++ and Embarcadero compilers.
long srchHandle;
-#else
+#else // Newer Visual C++
intptr_t srchHandle;
#endif
char* buf;
@@ -172,7 +183,7 @@ unsigned long Directory::GetNumberOfFilesInDirectory(const std::string& name)
struct _wfinddata_t data; // data of current file
// Now put them into the file array
- srchHandle = _wfindfirst((wchar_t*)Encoding::ToWide(buf).c_str(), &data);
+ srchHandle = _wfindfirst_func((wchar_t*)Encoding::ToWide(buf).c_str(), &data);
delete [] buf;
if ( srchHandle == -1 )
@@ -186,7 +197,7 @@ unsigned long Directory::GetNumberOfFilesInDirectory(const std::string& name)
{
count++;
}
- while ( _wfindnext(srchHandle, &data) != -1 );
+ while ( _wfindnext_func(srchHandle, &data) != -1 );
_findclose(srchHandle);
return count;
}
diff --git a/Source/kwsys/SystemTools.cxx b/Source/kwsys/SystemTools.cxx
index 0526372..9b56db0 100644
--- a/Source/kwsys/SystemTools.cxx
+++ b/Source/kwsys/SystemTools.cxx
@@ -523,7 +523,7 @@ void SystemTools::GetPath(std::vector<std::string>& path, const char* env)
}
}
-const char* SystemTools::GetEnv(const char* key)
+const char* SystemTools::GetEnvImpl(const char* key)
{
const char *v = 0;
#if defined(_WIN32)
@@ -540,9 +540,14 @@ const char* SystemTools::GetEnv(const char* key)
return v;
}
+const char* SystemTools::GetEnv(const char* key)
+{
+ return SystemTools::GetEnvImpl(key);
+}
+
const char* SystemTools::GetEnv(const std::string& key)
{
- return SystemTools::GetEnv(key.c_str());
+ return SystemTools::GetEnvImpl(key.c_str());
}
bool SystemTools::GetEnv(const char* key, std::string& result)
diff --git a/Source/kwsys/SystemTools.hxx.in b/Source/kwsys/SystemTools.hxx.in
index 8f01e75..aa1bf1b 100644
--- a/Source/kwsys/SystemTools.hxx.in
+++ b/Source/kwsys/SystemTools.hxx.in
@@ -984,6 +984,7 @@ private:
std::vector<std::string>(),
bool no_system_path = false);
+ static const char* GetEnvImpl(const char* key);
/**
* Path translation table from dir to refdir
diff --git a/Utilities/Sphinx/CMakeLists.txt b/Utilities/Sphinx/CMakeLists.txt
index 257ba62..45f79dd 100644
--- a/Utilities/Sphinx/CMakeLists.txt
+++ b/Utilities/Sphinx/CMakeLists.txt
@@ -156,18 +156,21 @@ if(SPHINX_MAN)
if("x${m}" MATCHES "^x(.+)\\.([1-9])\\.rst$")
set(name "${CMAKE_MATCH_1}")
set(sec "${CMAKE_MATCH_2}")
+ set(skip FALSE)
if(NOT CMakeHelp_STANDALONE)
if(name STREQUAL "ccmake" AND NOT BUILD_CursesDialog)
- continue()
- endif()
- if(name STREQUAL "cmake-gui" AND NOT BUILD_QtDialog)
- continue()
+ set(skip TRUE)
+ elseif(name STREQUAL "cmake-gui" AND NOT BUILD_QtDialog)
+ set(skip TRUE)
endif()
endif()
- CMake_OPTIONAL_COMPONENT(sphinx-man)
- install(FILES ${CMAKE_CURRENT_BINARY_DIR}/man/${name}.${sec}
- DESTINATION ${CMAKE_MAN_DIR}/man${sec}
- ${COMPONENT})
+ if(NOT skip)
+ CMake_OPTIONAL_COMPONENT(sphinx-man)
+ install(FILES ${CMAKE_CURRENT_BINARY_DIR}/man/${name}.${sec}
+ DESTINATION ${CMAKE_MAN_DIR}/man${sec}
+ ${COMPONENT})
+ endif()
+ unset(skip)
endif()
endforeach()
endif()