diff options
author | Marc Chevrier <marc.chevrier@gmail.com> | 2022-01-31 15:43:41 (GMT) |
---|---|---|
committer | Marc Chevrier <marc.chevrier@gmail.com> | 2022-02-28 09:26:26 (GMT) |
commit | 0a81ea1f12cbaf60ec60b8e4a27c5ea476a655de (patch) | |
tree | 8491b1ae05b5c252b1165244c6976d81c87397ee /Source/cmGeneratorTarget.cxx | |
parent | a9928eb4a54431780d589f70460e5715258f1d27 (diff) | |
download | CMake-0a81ea1f12cbaf60ec60b8e4a27c5ea476a655de.zip CMake-0a81ea1f12cbaf60ec60b8e4a27c5ea476a655de.tar.gz CMake-0a81ea1f12cbaf60ec60b8e4a27c5ea476a655de.tar.bz2 |
Genex-LINK_GROUP: Add possibility to group libraries at link step
Fixes: #23121
Diffstat (limited to 'Source/cmGeneratorTarget.cxx')
-rw-r--r-- | Source/cmGeneratorTarget.cxx | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx index a246c12..e893b44 100644 --- a/Source/cmGeneratorTarget.cxx +++ b/Source/cmGeneratorTarget.cxx @@ -6341,7 +6341,8 @@ cm::string_view missingTargetPossibleReasons = bool cmGeneratorTarget::VerifyLinkItemColons(LinkItemRole role, cmLinkItem const& item) const { - if (item.Target || item.AsStr().find("::") == std::string::npos) { + if (item.Target || cmHasPrefix(item.AsStr(), "<LINK_GROUP:"_s) || + item.AsStr().find("::") == std::string::npos) { return true; } MessageType messageType = MessageType::FATAL_ERROR; @@ -6388,7 +6389,8 @@ bool cmGeneratorTarget::VerifyLinkItemIsTarget(LinkItemRole role, if (!str.empty() && (str[0] == '-' || str[0] == '$' || str[0] == '`' || str.find_first_of("/\\") != std::string::npos || - cmHasPrefix(str, "<LINK_LIBRARY:"_s))) { + cmHasPrefix(str, "<LINK_LIBRARY:"_s) || + cmHasPrefix(str, "<LINK_GROUP:"_s))) { return true; } |