Skip to content

[cmake] Allow multiple LibEdit_LIBRARIES #93896

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 31, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions llvm/cmake/modules/FindLibEdit.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,7 @@ find_package_handle_standard_args(LibEdit
mark_as_advanced(LibEdit_INCLUDE_DIRS LibEdit_LIBRARIES)

if (LibEdit_FOUND AND NOT TARGET LibEdit::LibEdit)
add_library(LibEdit::LibEdit UNKNOWN IMPORTED)
set_target_properties(LibEdit::LibEdit PROPERTIES
IMPORTED_LOCATION ${LibEdit_LIBRARIES}
INTERFACE_INCLUDE_DIRECTORIES ${LibEdit_INCLUDE_DIRS})
add_library(LibEdit::LibEdit INTERFACE IMPORTED)
target_link_libraries(LibEdit::LibEdit INTERFACE ${LibEdit_LIBRARIES})
target_include_directories(LibEdit::LibEdit INTERFACE ${LibEdit_INCLUDE_DIRS})
endif()
Loading