summaryrefslogtreecommitdiffstats
path: root/Source/cmLocalGenerator.h
diff options
context:
space:
mode:
authorGregor Jasny <gjasny@googlemail.com>2020-04-21 14:34:57 (GMT)
committerBrad King <brad.king@kitware.com>2020-04-21 15:18:12 (GMT)
commit3a7d1e9592af743a6bb538111e603d7f10666e0c (patch)
treedb7267219d3d36a5174df9a2b868543b31ce5bd8 /Source/cmLocalGenerator.h
parentbe88264abecf73cb363a62b0c2bcd71613699543 (diff)
downloadCMake-3a7d1e9592af743a6bb538111e603d7f10666e0c.zip
CMake-3a7d1e9592af743a6bb538111e603d7f10666e0c.tar.gz
CMake-3a7d1e9592af743a6bb538111e603d7f10666e0c.tar.bz2
Apple: Merge per-arch sysroot parameters if all are the same
Since commit a9b41195d2 (Handle multi-arch sysroots on Apple platforms, 2019-07-26, v3.17.0-rc1~287^2), CMake supports "fat" builds with different sysroots. Those are passed to the compiler with the `-Xarch_<xyz>` parameter. Unfortunately this breaks the Compiler Cache (ccache) because it does not support those compiler flags: https://github.com/ccache/ccache/blob/v3.7.9/src/ccache.c#L2700-L2705 Restore the caching ability for certain "fat" build configurations (e.g. `arm64` and `armv7`) where the sysroot is the same for all selected architectures and thus a plain `-isysroot` parameter could be used.
Diffstat (limited to 'Source/cmLocalGenerator.h')
-rw-r--r--Source/cmLocalGenerator.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/Source/cmLocalGenerator.h b/Source/cmLocalGenerator.h
index 5377be9..a459384 100644
--- a/Source/cmLocalGenerator.h
+++ b/Source/cmLocalGenerator.h
@@ -528,6 +528,8 @@ private:
int targetType);
void ComputeObjectMaxPath();
+ bool AllAppleArchSysrootsAreTheSame(const std::vector<std::string>& archs,
+ const char* sysroot);
};
#if !defined(CMAKE_BOOTSTRAP)