teak-llvm/lldb/source/Plugins/ScriptInterpreter/Python/CMakeLists.txt
Jonas Devlieghere 282890d711 [Python] Define empty SWIG wrapper for unit testin"
The python plugin uses wrappers generated by swig. For the symbols to be
available, we'd need to link against liblldb, which is not an option
because the symbols could conflict with the static library we are
testing. Instead we define the symbols ourselves in the unit test.

llvm-svn: 356971
2019-03-26 01:11:15 +00:00

29 lines
760 B
CMake

if (NOT CMAKE_SYSTEM_NAME MATCHES "Windows")
# Call a python script to gather the arch-specific libdir for
# modules like the lldb module.
execute_process(
COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/../../../../scripts/get_relative_lib_dir.py
RESULT_VARIABLE get_libdir_status
OUTPUT_VARIABLE relative_libdir
)
if (get_libdir_status EQUAL 0)
add_definitions(-DLLDB_PYTHON_RELATIVE_LIBDIR="${relative_libdir}")
endif()
endif()
add_lldb_library(lldbPluginScriptInterpreterPython PLUGIN
PythonDataObjects.cpp
PythonExceptionState.cpp
ScriptInterpreterPython.cpp
LINK_LIBS
lldbBreakpoint
lldbCore
lldbDataFormatters
lldbHost
lldbInterpreter
lldbTarget
LINK_COMPONENTS
Support
)