diff options
author | Marc Chevrier <marc.chevrier@gmail.com> | 2020-12-04 17:35:04 (GMT) |
---|---|---|
committer | Marc Chevrier <marc.chevrier@gmail.com> | 2020-12-23 14:47:46 (GMT) |
commit | cfd8a5ac1f443725342517ddbaee51692d8d0324 (patch) | |
tree | bf2224cb9c6b6ba1a7aed1eb2fbcaf31799cbc17 /Source/cmAddCustomCommandCommand.cxx | |
parent | a526f71266c2fed017c65a3d90b63286221476c0 (diff) | |
download | CMake-cfd8a5ac1f443725342517ddbaee51692d8d0324.zip CMake-cfd8a5ac1f443725342517ddbaee51692d8d0324.tar.gz CMake-cfd8a5ac1f443725342517ddbaee51692d8d0324.tar.bz2 |
Makefiles: Add support of DEPFILE for add_custom_command
Issue: #20286
Fixes: #21415
Diffstat (limited to 'Source/cmAddCustomCommandCommand.cxx')
-rw-r--r-- | Source/cmAddCustomCommandCommand.cxx | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/Source/cmAddCustomCommandCommand.cxx b/Source/cmAddCustomCommandCommand.cxx index ccd7255..ff2cc3e 100644 --- a/Source/cmAddCustomCommandCommand.cxx +++ b/Source/cmAddCustomCommandCommand.cxx @@ -296,6 +296,12 @@ bool cmAddCustomCommandCommand(std::vector<std::string> const& args, status.SetError("given APPEND option with no OUTPUT."); return false; } + if (!implicit_depends.empty() && !depfile.empty() && + mf.GetGlobalGenerator()->GetName() != "Ninja") { + // Makefiles generators does not support both at the same time + status.SetError("IMPLICIT_DEPENDS and DEPFILE can not both be specified."); + return false; + } // Check for an append request. if (append) { |