Skip to content
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

Revert "fix cmake dependencies when building together with clang" #1173

Merged
Merged
Show file tree
Hide file tree
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
8 changes: 8 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -286,6 +286,14 @@ if (NOT CLAD_BUILD_STATIC_ONLY AND NOT LLVM_ENABLE_PLUGINS)
message(FATAL_ERROR "LLVM_ENABLE_PLUGINS is set to OFF. Please build clad with -DCLAD_BUILD_STATIC_ONLY=ON.")
endif()

# Add clad deps if we build together with clang.
if (TARGET intrinsics_gen)
list(APPEND LLVM_COMMON_DEPENDS intrinsics_gen)
endif()
if (TARGET clang-headers)
list(APPEND LLVM_COMMON_DEPENDS clang-headers)
endif()

add_subdirectory(lib)
add_subdirectory(tools)

Expand Down
9 changes: 0 additions & 9 deletions tools/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -132,15 +132,6 @@ if (NOT CLAD_BUILD_STATIC_ONLY)
target_link_libraries(clad PUBLIC ${_enzyme_link_flags})

add_dependencies(clad LLVMEnzyme)

# Add clad deps if we build together with clang.
if (TARGET intrinsics_gen)
add_dependencies(clad intrinsics_gen)
endif()
if (TARGET clang-headers)
add_dependencies(clad clang-headers)
endif()

endif(CLAD_ENABLE_ENZYME_BACKEND)
endif()
set_source_files_properties(ClangPlugin.cpp PROPERTIES COMPILE_DEFINITIONS CLANG_MAJOR_VERSION="${LLVM_VERSION_MAJOR}")
Loading