Skip to content

Commit

Permalink
Update CMakeLists.txt
Browse files Browse the repository at this point in the history
  • Loading branch information
vgvassilev authored Nov 7, 2023
1 parent bb49e99 commit 6d3eb83
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions lib/Interpreter/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,18 @@ add_llvm_library(clangCppInterOp
dl
)


# Get rid of libLLVM-X.so which is appended to the list of static libraries.
if (LLVM_LINK_LLVM_DYLIB)
get_target_property(deps clangCppInterOp LINK_LIBRARIES)
message (STATUS "L:${deps}")
list(REMOVE_ITEM deps "LLVM")
message (STATUS "K:${deps}")
set_target_properties(clangCppInterOp PROPERTIES LINK_LIBRARIES ${deps})
get_target_property(iface_deps clangCppInterOp INTERFACE_LINK_LIBRARIES)
message (STATUS "I:${iface_deps}")
endif(LLVM_LINK_LLVM_DYLIB)

string(REPLACE ";" "\;" _VER CPPINTEROP_VERSION)
set_source_files_properties(CppInterOp.cpp PROPERTIES COMPILE_DEFINITIONS
"LLVM_BINARY_DIR=\"${LLVM_BINARY_DIR}\";CPPINTEROP_VERSION=\"${_VAR}\""
Expand Down

0 comments on commit 6d3eb83

Please sign in to comment.