From ae3cc4f1b7530da66ff1f65d4416451446da36a9 Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Tue, 9 Sep 2014 19:03:05 +0200 Subject: MDEV-6561 libedit detection is broken fix readline/libedit detection: * search in readline/, editline/ and edit/readline/ * fix typos CMAKE_REQUIRES_LIBRARIES -> CMAKE_REQUIRED_LIBRARIES * use correct libedit API * use different cmake variables for libedit and readline --- cmd-line-utils/readline/CMakeLists.txt | 3 +-- cmd-line-utils/readline/history.h | 4 ++-- cmd-line-utils/readline/keymaps.h | 6 +++--- cmd-line-utils/readline/readline.h | 8 ++++---- cmd-line-utils/readline/xmalloc.h | 2 +- 5 files changed, 11 insertions(+), 12 deletions(-) (limited to 'cmd-line-utils/readline') diff --git a/cmd-line-utils/readline/CMakeLists.txt b/cmd-line-utils/readline/CMakeLists.txt index c06b9c08c47..bdecdd1fcce 100644 --- a/cmd-line-utils/readline/CMakeLists.txt +++ b/cmd-line-utils/readline/CMakeLists.txt @@ -13,8 +13,7 @@ # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA -INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include - ${CMAKE_SOURCE_DIR}/cmd-line-utils) +INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include ${CMAKE_CURRENT_SOURCE_DIR}) ADD_DEFINITIONS(-DHAVE_CONFIG_H -DNO_KILL_INTR) diff --git a/cmd-line-utils/readline/history.h b/cmd-line-utils/readline/history.h index 59aad6a4e20..c196b0361e3 100644 --- a/cmd-line-utils/readline/history.h +++ b/cmd-line-utils/readline/history.h @@ -32,8 +32,8 @@ extern "C" { # include "rlstdc.h" # include "rltypedefs.h" #else -# include -# include +# include +# include #endif #ifdef __STDC__ diff --git a/cmd-line-utils/readline/keymaps.h b/cmd-line-utils/readline/keymaps.h index eb28a8ecc33..1de567ddc1e 100644 --- a/cmd-line-utils/readline/keymaps.h +++ b/cmd-line-utils/readline/keymaps.h @@ -32,9 +32,9 @@ extern "C" { # include "chardefs.h" # include "rltypedefs.h" #else -# include -# include -# include +# include +# include +# include #endif /* A keymap contains one entry for each key in the ASCII set. diff --git a/cmd-line-utils/readline/readline.h b/cmd-line-utils/readline/readline.h index 8ed1b84172e..867b2e71641 100644 --- a/cmd-line-utils/readline/readline.h +++ b/cmd-line-utils/readline/readline.h @@ -33,10 +33,10 @@ extern "C" { # include "keymaps.h" # include "tilde.h" #else -# include -# include -# include -# include +# include +# include +# include +# include #endif /* Hex-encoded Readline version number. */ diff --git a/cmd-line-utils/readline/xmalloc.h b/cmd-line-utils/readline/xmalloc.h index fafb44fcffd..58b17f39f3d 100644 --- a/cmd-line-utils/readline/xmalloc.h +++ b/cmd-line-utils/readline/xmalloc.h @@ -26,7 +26,7 @@ #if defined (READLINE_LIBRARY) # include "rlstdc.h" #else -# include +# include #endif #ifndef PTR_T -- cgit v1.2.1