mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-31 20:51:52 +01:00
db10580e9b
LLVM defines `PTHREAD_LIB` which is used by AddLLVM.cmake and various projects to correctly link the threading library when needed. Unfortunately `PTHREAD_LIB` is defined by LLVM's `config-ix.cmake` file which isn't installed and therefore can't be used when configuring out-of-tree builds. This causes such builds to fail since `pthread` isn't being correctly linked. This patch attempts to fix that problem by renaming and exporting `LLVM_PTHREAD_LIB` as part of`LLVMConfig.cmake`. I renamed `PTHREAD_LIB` because It seemed likely to cause collisions with downstream users of `LLVMConfig.cmake`. llvm-svn: 294690
18 lines
366 B
CMake
18 lines
366 B
CMake
include_directories( ${CMAKE_CURRENT_SOURCE_DIR}/.. )
|
|
|
|
if( HAVE_LIBDL )
|
|
set(LLVM_INTEL_JIT_LIBS ${CMAKE_DL_LIBS})
|
|
endif()
|
|
|
|
set(LLVM_INTEL_JIT_LIBS ${LLVM_PTHREAD_LIB} ${LLVM_INTEL_JIT_LIBS})
|
|
|
|
|
|
add_llvm_library(LLVMIntelJITEvents
|
|
IntelJITEventListener.cpp
|
|
jitprofiling.c
|
|
|
|
LINK_LIBS ${LLVM_INTEL_JIT_LIBS}
|
|
)
|
|
|
|
add_dependencies(LLVMIntelJITEvents LLVMCodeGen)
|