Imported Upstream version 3.16.2 upstream/3.16.2
authorDongHun Kwak <dh0128.kwak@samsung.com>
Fri, 8 Oct 2021 00:14:22 +0000 (09:14 +0900)
committerDongHun Kwak <dh0128.kwak@samsung.com>
Fri, 8 Oct 2021 00:14:22 +0000 (09:14 +0900)
14 files changed:
CTestCustom.cmake.in
Modules/CMakeDetermineCompilerId.cmake
Modules/FindBLAS.cmake
Modules/FindBoost.cmake
Modules/FindLAPACK.cmake
Source/CMakeVersion.cmake
Source/cmGlobalVisualStudioVersionedGenerator.cxx
Source/cmQtAutoGenInitializer.cxx
Source/cmVisualStudio10TargetGenerator.cxx
Tests/CMakeLib/testCTestResourceSpec.cxx
Tests/QtAutogen/SameName/CMakeLists.txt
Tests/QtAutogen/SameName/main.cpp
Tests/QtAutogen/SameName/object.hh [deleted file]
Tests/RunCMake/VS10Project/VsPrecompileHeaders-check.cmake

index 823ee3c..d3ab9d3 100644 (file)
@@ -49,6 +49,7 @@ list(APPEND CTEST_CUSTOM_WARNING_EXCEPTION
   "WarningMessagesDialog\\.cxx"
   "warning.*directory name.*CMake-Xcode.*/bin/.*does not exist.*"
   "stl_deque.h:1051"
+  "Tests/CMakeLib/testCTestResourceSpec.cxx:.*warning: missing initializer for member.*cmCTestResourceSpec::.*" # GCC 4.8 disagrees with later compilers on C++11 initializer list conversion
   "(Lexer|Parser).*warning.*conversion.*may (alter its value|change the sign)"
   "(Lexer|Parser).*warning.*(statement is unreachable|will never be executed)"
   "(Lexer|Parser).*warning.*variable.*was set but never used"
index 908e530..7b571c3 100644 (file)
@@ -284,10 +284,11 @@ Id flags: ${testflags} ${CMAKE_${lang}_COMPILER_ID_FLAGS_ALWAYS}
           set(id_cl icl.exe)
         endif()
         if(CMAKE_VS_PLATFORM_TOOLSET_VERSION)
+          set(id_sep "\\")
           if(CMAKE_VS_PLATFORM_TOOLSET_VERSION VERSION_GREATER_EQUAL "14.20")
-            set(id_sep ".")
-          else()
-            set(id_sep "\\")
+            if(EXISTS "${CMAKE_GENERATOR_INSTANCE}/VC/Auxiliary/Build.${CMAKE_VS_PLATFORM_TOOLSET_VERSION}/Microsoft.VCToolsVersion.${CMAKE_VS_PLATFORM_TOOLSET_VERSION}.props")
+              set(id_sep ".")
+            endif()
           endif()
           set(id_toolset_version_props "<Import Project=\"${CMAKE_GENERATOR_INSTANCE}\\VC\\Auxiliary\\Build${id_sep}${CMAKE_VS_PLATFORM_TOOLSET_VERSION}\\Microsoft.VCToolsVersion.${CMAKE_VS_PLATFORM_TOOLSET_VERSION}.props\" />")
           unset(id_sep)
index 77f9d0e..d3acafc 100644 (file)
@@ -481,8 +481,12 @@ if (BLA_VENDOR STREQUAL "OpenBLAS" OR BLA_VENDOR STREQUAL "All")
       ""
       )
   endif()
-  if(NOT BLAS_LIBRARIES)
-    find_package(Threads)
+  if(NOT BLAS_LIBRARIES AND (CMAKE_C_COMPILER_LOADED OR CMAKE_CXX_COMPILER_LOADED))
+    if(BLAS_FIND_QUIETLY OR NOT BLAS_FIND_REQUIRED)
+      find_package(Threads)
+    else()
+      find_package(Threads REQUIRED)
+    endif()
     # OpenBLAS (http://www.openblas.net)
     check_fortran_libraries(
       BLAS_LIBRARIES
index ef962bc..0e84fab 100644 (file)
@@ -1129,7 +1129,7 @@ function(_Boost_COMPONENT_DEPENDENCIES component _ret)
     set(_Boost_TIMER_DEPENDENCIES chrono system)
     set(_Boost_WAVE_DEPENDENCIES filesystem serialization thread chrono date_time atomic)
     set(_Boost_WSERIALIZATION_DEPENDENCIES serialization)
-  elseif(NOT Boost_VERSION_STRING VERSION_LESS 1.70.0)
+  elseif(NOT Boost_VERSION_STRING VERSION_LESS 1.70.0 AND Boost_VERSION_STRING VERSION_LESS 1.72.0)
     set(_Boost_CONTRACT_DEPENDENCIES thread chrono date_time)
     set(_Boost_COROUTINE_DEPENDENCIES context)
     set(_Boost_FIBER_DEPENDENCIES context)
@@ -1143,7 +1143,21 @@ function(_Boost_COMPONENT_DEPENDENCIES component _ret)
     set(_Boost_TIMER_DEPENDENCIES chrono)
     set(_Boost_WAVE_DEPENDENCIES filesystem serialization thread chrono date_time atomic)
     set(_Boost_WSERIALIZATION_DEPENDENCIES serialization)
-    if(NOT Boost_VERSION_STRING VERSION_LESS 1.72.0)
+  elseif(NOT Boost_VERSION_STRING VERSION_LESS 1.72.0)
+    set(_Boost_CONTRACT_DEPENDENCIES thread chrono date_time)
+    set(_Boost_COROUTINE_DEPENDENCIES context)
+    set(_Boost_FIBER_DEPENDENCIES context)
+    set(_Boost_IOSTREAMS_DEPENDENCIES regex)
+    set(_Boost_LOG_DEPENDENCIES date_time log_setup filesystem thread regex chrono atomic)
+    set(_Boost_MATH_DEPENDENCIES math_c99 math_c99f math_c99l math_tr1 math_tr1f math_tr1l chrono atomic)
+    set(_Boost_MPI_DEPENDENCIES serialization)
+    set(_Boost_MPI_PYTHON_DEPENDENCIES python${component_python_version} mpi serialization)
+    set(_Boost_NUMPY_DEPENDENCIES python${component_python_version})
+    set(_Boost_THREAD_DEPENDENCIES chrono date_time atomic)
+    set(_Boost_TIMER_DEPENDENCIES chrono)
+    set(_Boost_WAVE_DEPENDENCIES filesystem serialization thread chrono date_time atomic)
+    set(_Boost_WSERIALIZATION_DEPENDENCIES serialization)
+    if(NOT Boost_VERSION_STRING VERSION_LESS 1.73.0)
       message(WARNING "New Boost version may have incorrect or missing dependencies and imported targets")
     endif()
   endif()
@@ -1415,7 +1429,7 @@ else()
   # _Boost_COMPONENT_HEADERS.  See the instructions at the top of
   # _Boost_COMPONENT_DEPENDENCIES.
   set(_Boost_KNOWN_VERSIONS ${Boost_ADDITIONAL_VERSIONS}
-    "1.71.0" "1.71" "1.70.0" "1.70" "1.69.0" "1.69"
+    "1.72.0" "1.72" "1.71.0" "1.71" "1.70.0" "1.70" "1.69.0" "1.69"
     "1.68.0" "1.68" "1.67.0" "1.67" "1.66.0" "1.66" "1.65.1" "1.65.0" "1.65"
     "1.64.0" "1.64" "1.63.0" "1.63" "1.62.0" "1.62" "1.61.0" "1.61" "1.60.0" "1.60"
     "1.59.0" "1.59" "1.58.0" "1.58" "1.57.0" "1.57" "1.56.0" "1.56" "1.55.0" "1.55"
index 844d36d..3cb3653 100644 (file)
@@ -174,7 +174,7 @@ if(_libraries_work)
 endif()
 
  if(_libraries_work)
-   if("${_list}" STREQUAL "")
+   if("${_list}${_blas}" STREQUAL "")
      set(${LIBRARIES} "${LIBRARIES}-PLACEHOLDER-FOR-EMPTY-LIBRARIES")
    else()
      set(${LIBRARIES} ${${LIBRARIES}} ${_blas} ${_threads})
index 7020a52..468df13 100644 (file)
@@ -1,7 +1,7 @@
 # CMake version number components.
 set(CMake_VERSION_MAJOR 3)
 set(CMake_VERSION_MINOR 16)
-set(CMake_VERSION_PATCH 1)
+set(CMake_VERSION_PATCH 2)
 #set(CMake_VERSION_RC 0)
 set(CMake_VERSION_IS_DIRTY 0)
 
@@ -21,7 +21,7 @@ endif()
 
 if(NOT CMake_VERSION_NO_GIT)
   # If this source was exported by 'git archive', use its commit info.
-  set(git_info [==[4771c4e447 CMake 3.16.1]==])
+  set(git_info [==[512ab500f0 CMake 3.16.2]==])
 
   # Otherwise, try to identify the current development source version.
   if(NOT git_info MATCHES "^([0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f]?[0-9a-f]?)[0-9a-f]* "
index 1eca1f6..a371633 100644 (file)
@@ -6,6 +6,7 @@
 #include "cmDocumentationEntry.h"
 #include "cmLocalVisualStudio10Generator.h"
 #include "cmMakefile.h"
+#include "cmStringAlgorithms.h"
 #include "cmVSSetupHelper.h"
 #include "cmake.h"
 
@@ -388,15 +389,19 @@ std::string cmGlobalVisualStudioVersionedGenerator::GetAuxiliaryToolset() const
   if (version) {
     std::string instancePath;
     GetVSInstance(instancePath);
-    std::stringstream path;
-    path << instancePath;
-    path << "/VC/Auxiliary/Build";
-    path << (cmSystemTools::VersionCompareGreaterEq(version, "14.20") ? '.'
-                                                                      : '/');
-    path << version;
-    path << "/Microsoft.VCToolsVersion." << version << ".props";
-
-    std::string toolsetPath = path.str();
+    std::string toolsetDir = instancePath + "/VC/Auxiliary/Build";
+    char sep = '/';
+    if (cmSystemTools::VersionCompareGreaterEq(version, "14.20")) {
+      std::string toolsetDot =
+        cmStrCat(toolsetDir, '.', version, "/Microsoft.VCToolsVersion.",
+                 version, ".props");
+      if (cmSystemTools::PathExists(toolsetDot)) {
+        sep = '.';
+      }
+    }
+    std::string toolsetPath =
+      cmStrCat(toolsetDir, sep, version, "/Microsoft.VCToolsVersion.", version,
+               ".props");
     cmSystemTools::ConvertToUnixSlashes(toolsetPath);
     return toolsetPath;
   }
index a20f106..6b0fc1e 100644 (file)
@@ -764,7 +764,8 @@ bool cmQtAutoGenInitializer::InitScanFiles()
 
       // Register files that will be scanned by moc or uic
       if (this->MocOrUicEnabled()) {
-        if (cm->IsHeaderExtension(extLower)) {
+        // FIXME: Add a policy to include .hh files.
+        if (cm->IsHeaderExtension(extLower) && extLower != "hh") {
           addMUFile(makeMUFile(sf, fullPath, true), true);
         } else if (cm->IsSourceExtension(extLower)) {
           addMUFile(makeMUFile(sf, fullPath, true), false);
@@ -876,7 +877,8 @@ bool cmQtAutoGenInitializer::InitScanFiles()
       std::string const& extLower =
         cmSystemTools::LowerCase(sf->GetExtension());
 
-      if (cm->IsHeaderExtension(extLower)) {
+      // FIXME: Add a policy to include .hh files.
+      if (cm->IsHeaderExtension(extLower) && extLower != "hh") {
         if (!cmContains(this->AutogenTarget.Headers, sf)) {
           auto muf = makeMUFile(sf, fullPath, false);
           if (muf->SkipMoc || muf->SkipUic) {
index 5c0b881..53fc93c 100644 (file)
@@ -2399,6 +2399,9 @@ void cmVisualStudio10TargetGenerator::OutputSourceSpecificFlags(
         clOptions.AppendFlag("DisableSpecificWarnings",
                              "%(DisableSpecificWarnings)");
       }
+      if (clOptions.HasFlag("ForcedIncludeFiles")) {
+        clOptions.AppendFlag("ForcedIncludeFiles", "%(ForcedIncludeFiles)");
+      }
       if (configDependentDefines) {
         clOptions.AddDefines(
           genexInterpreter.Evaluate(configDefines, "COMPILE_DEFINITIONS"));
index b69003d..99bee56 100644 (file)
@@ -21,43 +21,42 @@ static const std::vector<ExpectedSpec> expectedResourceSpecs = {
     {"threads", {
     }},
   }}}},
-  {"spec2.json", true, {{{
-  }}}},
-  {"spec3.json", false, {{{}}}},
-  {"spec4.json", false, {{{}}}},
-  {"spec5.json", false, {{{}}}},
-  {"spec6.json", false, {{{}}}},
-  {"spec7.json", false, {{{}}}},
-  {"spec8.json", false, {{{}}}},
-  {"spec9.json", false, {{{}}}},
-  {"spec10.json", false, {{{}}}},
-  {"spec11.json", false, {{{}}}},
-  {"spec12.json", false, {{{}}}},
-  {"spec13.json", false, {{{}}}},
-  {"spec14.json", true, {{{}}}},
-  {"spec15.json", true, {{{}}}},
-  {"spec16.json", true, {{{}}}},
-  {"spec17.json", false, {{{}}}},
-  {"spec18.json", false, {{{}}}},
-  {"spec19.json", false, {{{}}}},
-  {"spec20.json", true, {{{}}}},
-  {"spec21.json", false, {{{}}}},
-  {"spec22.json", false, {{{}}}},
-  {"spec23.json", false, {{{}}}},
-  {"spec24.json", false, {{{}}}},
-  {"spec25.json", false, {{{}}}},
-  {"spec26.json", false, {{{}}}},
-  {"spec27.json", false, {{{}}}},
-  {"spec28.json", false, {{{}}}},
-  {"spec29.json", false, {{{}}}},
-  {"spec30.json", false, {{{}}}},
-  {"spec31.json", false, {{{}}}},
-  {"spec32.json", false, {{{}}}},
-  {"spec33.json", false, {{{}}}},
-  {"spec34.json", false, {{{}}}},
-  {"spec35.json", false, {{{}}}},
-  {"spec36.json", false, {{{}}}},
-  {"noexist.json", false, {{{}}}},
+  {"spec2.json", true, {}},
+  {"spec3.json", false, {}},
+  {"spec4.json", false, {}},
+  {"spec5.json", false, {}},
+  {"spec6.json", false, {}},
+  {"spec7.json", false, {}},
+  {"spec8.json", false, {}},
+  {"spec9.json", false, {}},
+  {"spec10.json", false, {}},
+  {"spec11.json", false, {}},
+  {"spec12.json", false, {}},
+  {"spec13.json", false, {}},
+  {"spec14.json", true, {}},
+  {"spec15.json", true, {}},
+  {"spec16.json", true, {}},
+  {"spec17.json", false, {}},
+  {"spec18.json", false, {}},
+  {"spec19.json", false, {}},
+  {"spec20.json", true, {}},
+  {"spec21.json", false, {}},
+  {"spec22.json", false, {}},
+  {"spec23.json", false, {}},
+  {"spec24.json", false, {}},
+  {"spec25.json", false, {}},
+  {"spec26.json", false, {}},
+  {"spec27.json", false, {}},
+  {"spec28.json", false, {}},
+  {"spec29.json", false, {}},
+  {"spec30.json", false, {}},
+  {"spec31.json", false, {}},
+  {"spec32.json", false, {}},
+  {"spec33.json", false, {}},
+  {"spec34.json", false, {}},
+  {"spec35.json", false, {}},
+  {"spec36.json", false, {}},
+  {"noexist.json", false, {}},
   /* clang-format on */
 };
 
index 1919cc7..cd29a2a 100644 (file)
@@ -18,7 +18,6 @@ add_executable(sameName
   ccc/data.qrc
   item.cpp
   object.h
-  object.hh
   object.h++
   object.hpp
   object.hxx
index 725f4cd..19a6f6d 100644 (file)
@@ -6,7 +6,6 @@
 #include "item.hpp"
 #include "object.h"
 #include "object.h++"
-#include "object.hh"
 #include "object.hpp"
 #include "object.hxx"
 #include "object_upper_ext.H"
@@ -22,7 +21,6 @@ int main(int argv, char** args)
   ::ccc::Item ccc_item;
   // Object instances
   ::Object_h obj_h;
-  ::Object_hh obj_hh;
   ::Object_hplpl obj_hplpl;
   ::Object_hpp obj_hpp;
   ::Object_hxx obj_hxx;
diff --git a/Tests/QtAutogen/SameName/object.hh b/Tests/QtAutogen/SameName/object.hh
deleted file mode 100644 (file)
index 3e16f83..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-#ifndef OBJECT_HH
-#define OBJECT_HH
-
-#include <QObject>
-
-class Object_hh : public QObject
-{
-  Q_OBJECT
-  Q_SLOT
-  void go(){};
-};
-
-#endif
index 27842f9..91cea0e 100644 (file)
@@ -31,7 +31,7 @@ foreach(line IN LISTS tgt_projects_strings)
     set(have_pch_header ON)
   endif()
 
-  if (line MATCHES "<ForcedIncludeFiles.*>.*${pch_header}</ForcedIncludeFiles>")
+  if (line MATCHES "<ForcedIncludeFiles.*>.*${pch_header}.*</ForcedIncludeFiles>")
     set(have_force_pch_header ON)
   endif()