diff options
author | Brad King <brad.king@kitware.com> | 2020-04-28 11:09:03 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2020-04-28 11:10:07 (GMT) |
commit | 9db6583531df4814a6162c21744da095116d3bba (patch) | |
tree | 2172bdcb20b5ce92287529e6dabce663b332a9a0 /Source | |
parent | 41d37e45e9e2d5758c19a8b09c72f54d63f9827d (diff) | |
parent | c4d09fdc6d563570ef779244751e0088c83ea096 (diff) | |
download | CMake-9db6583531df4814a6162c21744da095116d3bba.zip CMake-9db6583531df4814a6162c21744da095116d3bba.tar.gz CMake-9db6583531df4814a6162c21744da095116d3bba.tar.bz2 |
Merge topic 'makefile-objc' into release-3.17
c4d09fdc6d Makefiles: Add Objective C/C++ compilations to compile_commands.json
98aa628f0b Makefiles: Scan Objective C/C++ preprocessor dependencies
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4675
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmLocalUnixMakefileGenerator3.cxx | 2 | ||||
-rw-r--r-- | Source/cmMakefileTargetGenerator.cxx | 5 |
2 files changed, 4 insertions, 3 deletions
diff --git a/Source/cmLocalUnixMakefileGenerator3.cxx b/Source/cmLocalUnixMakefileGenerator3.cxx index 24a6351..c9c656c 100644 --- a/Source/cmLocalUnixMakefileGenerator3.cxx +++ b/Source/cmLocalUnixMakefileGenerator3.cxx @@ -1472,7 +1472,7 @@ bool cmLocalUnixMakefileGenerator3::ScanDependencies( // Create the scanner for this language std::unique_ptr<cmDepends> scanner; if (lang == "C" || lang == "CXX" || lang == "RC" || lang == "ASM" || - lang == "CUDA") { + lang == "OBJC" || lang == "OBJCXX" || lang == "CUDA") { // TODO: Handle RC (resource files) dependencies correctly. scanner = cm::make_unique<cmDependsC>(this, targetDir, lang, &validDeps); } diff --git a/Source/cmMakefileTargetGenerator.cxx b/Source/cmMakefileTargetGenerator.cxx index d7e2de6..a8769d8 100644 --- a/Source/cmMakefileTargetGenerator.cxx +++ b/Source/cmMakefileTargetGenerator.cxx @@ -677,8 +677,9 @@ void cmMakefileTargetGenerator::WriteObjectRuleFiles( // At the moment, it is assumed that C, C++, Fortran, and CUDA have both // assembly and preprocessor capabilities. The same is true for the // ability to export compile commands - bool lang_has_preprocessor = ((lang == "C") || (lang == "CXX") || - (lang == "Fortran") || (lang == "CUDA")); + bool lang_has_preprocessor = + ((lang == "C") || (lang == "CXX") || (lang == "OBJC") || + (lang == "OBJCXX") || (lang == "Fortran") || (lang == "CUDA")); bool const lang_has_assembly = lang_has_preprocessor; bool const lang_can_export_cmds = lang_has_preprocessor; |