diff --git a/CMakeLists.txt b/CMakeLists.txt index 0840b00..bcb84ec 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -3,7 +3,7 @@ cmake_minimum_required (VERSION 2.8.5) # Options option (WANT_READLINE "Use GNU Readline for the UI (better)" ON) -option (WANT_EDITLINE "Use BSD libedit for the UI" OFF) +option (WANT_LIBEDIT "Use BSD libedit for the UI" OFF) # Moar warnings if ("${CMAKE_C_COMPILER_ID}" MATCHES "GNU" OR CMAKE_COMPILER_IS_GNUC) @@ -42,24 +42,24 @@ else (CURSES_FOUND) message (SEND_ERROR "Curses not found") endif (ncursesw_FOUND) -if ((WANT_READLINE AND WANT_EDITLINE) OR (NOT WANT_READLINE AND NOT WANT_EDITLINE)) +if ((WANT_READLINE AND WANT_LIBEDIT) OR (NOT WANT_READLINE AND NOT WANT_LIBEDIT)) message (SEND_ERROR "You have to choose either GNU Readline or libedit") elseif (WANT_READLINE) list (APPEND project_libraries readline) -elseif (WANT_EDITLINE) +elseif (WANT_LIBEDIT) pkg_check_modules (libedit REQUIRED libedit) list (APPEND project_libraries ${libedit_LIBRARIES}) include_directories (${libedit_INCLUDE_DIRS}) -endif ((WANT_READLINE AND WANT_EDITLINE) OR (NOT WANT_READLINE AND NOT WANT_EDITLINE)) +endif ((WANT_READLINE AND WANT_LIBEDIT) OR (NOT WANT_READLINE AND NOT WANT_LIBEDIT)) # Generate a configuration file if (WANT_READLINE) set (HAVE_READLINE 1) endif (WANT_READLINE) -if (WANT_EDITLINE) +if (WANT_LIBEDIT) set (HAVE_EDITLINE 1) -endif (WANT_EDITLINE) +endif (WANT_LIBEDIT) include (GNUInstallDirs) set (plugin_dir ${CMAKE_INSTALL_LIBDIR}/${PROJECT_NAME})