diff options
-rw-r--r-- | Source/cmGeneratorTarget.cxx | 3 | ||||
-rw-r--r-- | Tests/SwiftOnly/CMakeLists.txt | 1 |
2 files changed, 4 insertions, 0 deletions
diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx index f2011ee..c7baf2b 100644 --- a/Source/cmGeneratorTarget.cxx +++ b/Source/cmGeneratorTarget.cxx @@ -1309,6 +1309,9 @@ void AddSwiftImplicitIncludeDirectories( for (const cmLinkImplItem& library : libraries->Libraries) { if (const cmGeneratorTarget* dependency = library.Target) { + if (dependency->GetType() == cmStateEnums::INTERFACE_LIBRARY) { + continue; + } if (cm::contains(dependency->GetAllConfigCompileLanguages(), "Swift")) { EvaluatedTargetPropertyEntry entry{ library, library.Backtrace }; diff --git a/Tests/SwiftOnly/CMakeLists.txt b/Tests/SwiftOnly/CMakeLists.txt index e24279b..41d14ea 100644 --- a/Tests/SwiftOnly/CMakeLists.txt +++ b/Tests/SwiftOnly/CMakeLists.txt @@ -35,3 +35,4 @@ target_link_libraries(N PUBLIC # Dummy to make sure generation works with such targets. add_library(SwiftIface INTERFACE) +target_link_libraries(SwiftOnly PRIVATE SwiftIface) |