1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 03:02:36 +01:00
llvm-mirror/tools/llvm-jitlink/CMakeLists.txt
Lang Hames 894fb2a5d3 [llvm-jitlink] Link libnetwork on Haiku in llvm-jitlink
The system's network API is in libnetwork.so, so we explicitly need to link to
them on Haiku. This patch is similar to https://reviews.llvm.org/D97633.

Patch by Niels Reedijk. Thanks Niels!

Reviewed By: lhames

Differential Revision: https://reviews.llvm.org/D98405
2021-05-14 20:49:03 -07:00

36 lines
640 B
CMake

if ( LLVM_INCLUDE_UTILS )
add_subdirectory(llvm-jitlink-executor)
endif()
set(LLVM_LINK_COMPONENTS
AllTargetsDescs
AllTargetsDisassemblers
AllTargetsInfos
BinaryFormat
ExecutionEngine
JITLink
MC
Object
OrcJIT
OrcShared
OrcTargetProcess
RuntimeDyld
Support
)
add_llvm_tool(llvm-jitlink
llvm-jitlink.cpp
llvm-jitlink-elf.cpp
llvm-jitlink-macho.cpp
)
if(${CMAKE_SYSTEM_NAME} MATCHES "Haiku")
target_link_libraries(llvm-jitlink PRIVATE network)
endif()
if(${CMAKE_SYSTEM_NAME} MATCHES "SunOS")
target_link_libraries(llvm-jitlink PRIVATE socket nsl)
endif()
export_executable_symbols(llvm-jitlink)