mirror of
https://github.com/llvm/llvm-project.git
synced 2025-04-16 13:46:37 +00:00
[OpenMP] [OMPD] Build gdb-plugin code only when python3 development files are available.
gdb-plugin code is a interface between gdb, libompd, gdb and libomp. Python3 development files are required to build this utility. This patch will disable the plugin code build when python3 dev files are not available. Reviewed By: @mgorny, @aaronpuchert Differential Revision: https://reviews.llvm.org/D134275
This commit is contained in:
parent
333246b48e
commit
97bb709013
@ -8,10 +8,13 @@
|
||||
#//===----------------------------------------------------------------------===//
|
||||
#
|
||||
|
||||
find_package (Python3 COMPONENTS Interpreter Development)
|
||||
option(LIBOMP_OMPD_GDB_SUPPORT "Build gdb-plugin code that enables OMPD support in GDB." ${Python3_FOUND})
|
||||
|
||||
if(LIBOMP_OMPD_SUPPORT)
|
||||
set(OMPD_INCLUDE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/src/)
|
||||
add_subdirectory(src)
|
||||
if(NOT DISABLE_OMPD_GDB_PLUGIN)
|
||||
if(LIBOMP_OMPD_GDB_SUPPORT)
|
||||
add_subdirectory(gdb-plugin)
|
||||
endif()
|
||||
endif()
|
||||
|
@ -13,9 +13,6 @@ set (CMAKE_MODULE_PATH
|
||||
${CMAKE_MODULE_PATH}
|
||||
)
|
||||
|
||||
find_package (Python3 COMPONENTS Interpreter Development)
|
||||
find_package (PythonLibs REQUIRED)
|
||||
|
||||
include_directories (${OMPD_INCLUDE_PATH})
|
||||
include_directories (${LIBOMP_INCLUDE_DIR})
|
||||
add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/python-module/ompd/__init__.py
|
||||
|
Loading…
x
Reference in New Issue
Block a user