Merge topic 'implicit-includes-extra-CR' into release-3.16
6d84afc7f2 Merge branch 'backport-implicit-includes-extra-CR' into implicit-includes-extra-CR
4b46523d90 CMakeParseImplicitIncludeInfo: Remove all CR chars from compiler output
2a5e5b25ba CMake 3.15.5
08173075c1 Merge branch 'doc-genex-tweak' into release-3.15
83dbef1135 Merge branch 'InstallRequiredSystemLibraries-redist' into release-3.15
881bca249d Merge branch 'vs-v142-csharp-flags' into release-3.15
dec3e9363e Merge branch 'backport-vs-16.4-global-targets' into release-3.15
ac1a1bf18b VS: Tell VS 16.4 not to verify CMake-provided custom command outputs
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4088
diff --git a/Modules/FindODBC.cmake b/Modules/FindODBC.cmake
index 29d7af9..3f710db 100644
--- a/Modules/FindODBC.cmake
+++ b/Modules/FindODBC.cmake
@@ -92,6 +92,8 @@
# List names of ODBC libraries on Windows
if(NOT MINGW)
set(ODBC_LIBRARY odbc32.lib)
+ else()
+ set(ODBC_LIBRARY libodbc32.a)
endif()
set(_odbc_lib_names odbc32;)
diff --git a/Modules/FindwxWidgets.cmake b/Modules/FindwxWidgets.cmake
index 12c68bb..4334e22 100644
--- a/Modules/FindwxWidgets.cmake
+++ b/Modules/FindwxWidgets.cmake
@@ -517,6 +517,7 @@
find_path(wxWidgets_LIB_DIR
NAMES
qtu/wx/setup.h
+ qtud/wx/setup.h
msw/wx/setup.h
mswd/wx/setup.h
mswu/wx/setup.h
@@ -543,6 +544,7 @@
find_path(wxWidgets_LIB_DIR
NAMES
qtu/wx/setup.h
+ qtud/wx/setup.h
msw/wx/setup.h
mswd/wx/setup.h
mswu/wx/setup.h
@@ -647,7 +649,7 @@
# Find wxWidgets libraries.
WX_FIND_LIBS("${PF}" "${UNV}" "${UCD}" "${DBG}")
if(WX_USE_REL_AND_DBG)
- WX_FIND_LIBS("${UNV}" "${UCD}" "d")
+ WX_FIND_LIBS("${PF}" "${UNV}" "${UCD}" "d")
endif()
# Settings for requested libs (i.e., include dir, libraries, etc.).
diff --git a/Source/cmGlobalXCodeGenerator.cxx b/Source/cmGlobalXCodeGenerator.cxx
index 6cbd4f3..3002b2a 100644
--- a/Source/cmGlobalXCodeGenerator.cxx
+++ b/Source/cmGlobalXCodeGenerator.cxx
@@ -942,6 +942,10 @@
sourcecode += ".cpp.cpp";
} else if (lang == "C") {
sourcecode += ".c.c";
+ } else if (lang == "OBJCXX") {
+ sourcecode += ".cpp.objcpp";
+ } else if (lang == "OBJC") {
+ sourcecode += ".c.objc";
} else if (lang == "Fortran") {
sourcecode += ".fortran.f90";
} else if (lang == "ASM") {
diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx
index 923d2a5..2e499b3 100644
--- a/Source/cmLocalGenerator.cxx
+++ b/Source/cmLocalGenerator.cxx
@@ -3148,6 +3148,22 @@
}
}
+ // Ensure that for the CMakeFiles/<target>.dir/generated_source_file
+ // we don't end up having:
+ // CMakeFiles/<target>.dir/CMakeFiles/<target>.dir/generated_source_file.obj
+ const char* unitySourceFile = source.GetProperty("UNITY_SOURCE_FILE");
+ const char* pchExtension = source.GetProperty("PCH_EXTENSION");
+ if (unitySourceFile || pchExtension) {
+ if (pchExtension) {
+ customOutputExtension = pchExtension;
+ }
+
+ cmsys::RegularExpression var("(CMakeFiles/[^/]+.dir/)");
+ if (var.find(objectName)) {
+ objectName.erase(var.start(), var.end() - var.start());
+ }
+ }
+
// Replace the original source file extension with the object file
// extension.
bool keptSourceExtension = true;
@@ -3164,19 +3180,6 @@
}
}
- const char* pchExtension = source.GetProperty("PCH_EXTENSION");
- if (pchExtension) {
- customOutputExtension = pchExtension;
-
- // Make sure that for the CMakeFiles/<target>.dir/cmake_pch.h|xx.c|xx
- // source file, we don't end up having
- // CMakeFiles/<target>.dir/CMakeFiles/<target>.dir/cmake_pch.h|xx.pch
- cmsys::RegularExpression var("(CMakeFiles/[^/]+.dir/)");
- while (var.find(objectName)) {
- objectName.erase(var.start(), var.end() - var.start());
- }
- }
-
// Remove the source extension if it is to be replaced.
if (replaceExt || customOutputExtension) {
keptSourceExtension = false;