From 23d66ae1e4866db2f009ef7f9781174f9eebdfd1 Mon Sep 17 00:00:00 2001 From: Saleem Abdulrasool Date: Mon, 4 Jun 2018 02:08:12 +0000 Subject: Python: adjust the include directories Restructure the include search order to adjust for libedit. This ensures that the variables are not unused if they are not defined. llvm-svn: 333863 --- lldb/scripts/Python/modules/readline/CMakeLists.txt | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'lldb/scripts/Python/modules') diff --git a/lldb/scripts/Python/modules/readline/CMakeLists.txt b/lldb/scripts/Python/modules/readline/CMakeLists.txt index d7b0e468fb9..876ab341682 100644 --- a/lldb/scripts/Python/modules/readline/CMakeLists.txt +++ b/lldb/scripts/Python/modules/readline/CMakeLists.txt @@ -6,14 +6,13 @@ SET(PYTHON_DIRECTORY python${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR}/site- # Build the readline python module include_directories(${PYTHON_INCLUDE_DIR}) add_library(readline SHARED readline.cpp) -target_include_directories(readline - PRIVATE - ${libedit_INCLUDE_DIRS}) +target_link_libraries(readline ${PYTHON_LIBRARY}) if (NOT LLDB_DISABLE_LIBEDIT) - target_link_libraries(readline ${PYTHON_LIBRARY} ${libedit_LIBRARIES}) -else() - target_link_libraries(readline ${PYTHON_LIBRARY}) + target_include_directories(readline + PRIVATE + ${libedit_INCLUDE_DIRS}) + target_link_libraries(readline ${libedit_LIBRARIES}) endif() # FIXME: the LIBRARY_OUTPUT_PATH seems to be ignored - this is not a -- cgit v1.2.3