[lldb] Only link against Python 3 when LLDB_ENABLE_PYTHON is set.

Only link against Python3_LIBRARY when LLDB_ENABLE_PYTHON is true. We
have to be more strict now becuase Python3_LIBRARY might be set to
NOTFOUND instead of being not set at all.
This commit is contained in:
Jonas Devlieghere 2020-08-17 09:30:08 -07:00
parent c8a9872259
commit 6cc0b00f4d
1 changed files with 1 additions and 1 deletions

View File

@ -24,6 +24,7 @@ endif()
# Add python wrapper if python not disabled
if (LLDB_ENABLE_PYTHON AND LLDB_BUILD_INTEL_PT)
list(APPEND FEATURE_LIBS ${FEATURE_LIBS} ${Python3_LIBRARIES})
set(LLDB_INTEL_FEATURES_PYTHON_WRAP
${LLDB_BINARY_DIR}/tools/intel-features/scripts/IntelFeaturesPythonWrap.cpp)
set_source_files_properties(${LLDB_INTEL_FEATURES_PYTHON_WRAP}
@ -56,7 +57,6 @@ add_lldb_library(lldbIntelFeatures SHARED
LINK_LIBS
${FEATURE_LIBS}
${Python3_LIBRARIES}
)
# Add link dependencies for python wrapper