aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt13
1 files changed, 9 insertions, 4 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 88a01c8..ca80edf 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -20,9 +20,13 @@ set (project_VERSION "${project_VERSION_MAJOR}")
set (project_VERSION "${project_VERSION}.${project_VERSION_MINOR}")
set (project_VERSION "${project_VERSION}.${project_VERSION_PATCH}")
+# For custom modules
+set (CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake)
+
# Dependencies
find_package (PkgConfig REQUIRED)
-pkg_check_modules (dependencies REQUIRED ncursesw libuv>=0.11)
+pkg_check_modules (ncursesw REQUIRED ncursesw)
+find_package (LibEV REQUIRED)
if (USE_SYSTEM_TERMO)
find_package (Termo REQUIRED)
@@ -38,11 +42,12 @@ else (USE_SYSTEM_TERMO)
set (Termo_LIBRARIES termo-static)
endif (USE_SYSTEM_TERMO)
-include_directories (${dependencies_INCLUDE_DIRS} ${Termo_INCLUDE_DIRS})
+include_directories (${ncursesw_INCLUDE_DIRS}
+ ${LIBEV_INCLUDE_DIRS} ${Termo_INCLUDE_DIRS})
# Configuration
include (CheckFunctionExists)
-set (CMAKE_REQUIRED_LIBRARIES ${dependencies_LIBRARIES})
+set (CMAKE_REQUIRED_LIBRARIES ${ncursesw_LIBRARIES})
CHECK_FUNCTION_EXISTS ("resizeterm" HAVE_RESIZETERM)
# Project source files
@@ -50,7 +55,7 @@ set (project_sources ${PROJECT_NAME}.c)
set (project_headers ${PROJECT_BINARY_DIR}/config.h)
# Project libraries
-set (project_libraries ${dependencies_LIBRARIES} termo-static)
+set (project_libraries ${ncursesw_LIBRARIES} ${LIBEV_LIBRARIES} termo-static)
# Generate a configuration file
configure_file (${PROJECT_SOURCE_DIR}/config.h.in ${PROJECT_BINARY_DIR}/config.h)