Get rid of one CMake dev warning

This commit is contained in:
Přemysl Eric Janouch 2020-09-07 18:39:59 +02:00
parent 695f71d946
commit 74f2bcae34
Signed by: p
GPG Key ID: A0420B94F92B9493
2 changed files with 12 additions and 12 deletions

View File

@ -89,12 +89,12 @@ endif (WITH_X11)
link_directories (${dependencies_LIBRARY_DIRS}) link_directories (${dependencies_LIBRARY_DIRS})
include_directories (${ZLIB_INCLUDE_DIRS} ${icu_INCLUDE_DIRS} include_directories (${ZLIB_INCLUDE_DIRS} ${icu_INCLUDE_DIRS}
${dependencies_INCLUDE_DIRS} ${NCURSESW_INCLUDE_DIRS} ${dependencies_INCLUDE_DIRS} ${Ncursesw_INCLUDE_DIRS}
${Termo_INCLUDE_DIRS}) ${Termo_INCLUDE_DIRS})
# Configuration # Configuration
include (CheckFunctionExists) include (CheckFunctionExists)
set (CMAKE_REQUIRED_LIBRARIES ${NCURSESW_LIBRARIES}) set (CMAKE_REQUIRED_LIBRARIES ${Ncursesw_LIBRARIES})
CHECK_FUNCTION_EXISTS ("resizeterm" HAVE_RESIZETERM) CHECK_FUNCTION_EXISTS ("resizeterm" HAVE_RESIZETERM)
# Localization # Localization
@ -145,7 +145,7 @@ set (project_common_headers
# Project libraries # Project libraries
set (project_common_libraries ${ZLIB_LIBRARIES} ${icu_LIBRARIES} set (project_common_libraries ${ZLIB_LIBRARIES} ${icu_LIBRARIES}
${dependencies_LIBRARIES} ${NCURSESW_LIBRARIES} termo-static) ${dependencies_LIBRARIES} ${Ncursesw_LIBRARIES} termo-static)
# Create a common project library so that source files are only compiled once # Create a common project library so that source files are only compiled once
if (${CMAKE_VERSION} VERSION_GREATER "2.8.7") if (${CMAKE_VERSION} VERSION_GREATER "2.8.7")

View File

@ -1,17 +1,17 @@
# Public Domain # Public Domain
find_package (PkgConfig REQUIRED) find_package (PkgConfig REQUIRED)
pkg_check_modules (NCURSESW QUIET ncursesw) pkg_check_modules (Ncursesw QUIET ncursesw)
# OpenBSD doesn't provide a pkg-config file # OpenBSD doesn't provide a pkg-config file
set (required_vars NCURSESW_LIBRARIES) set (required_vars Ncursesw_LIBRARIES)
if (NOT NCURSESW_FOUND) if (NOT Ncursesw_FOUND)
find_library (NCURSESW_LIBRARIES NAMES ncursesw) find_library (Ncursesw_LIBRARIES NAMES ncursesw)
find_path (NCURSESW_INCLUDE_DIRS ncurses.h) find_path (Ncursesw_INCLUDE_DIRS ncurses.h)
list (APPEND required_vars NCURSESW_INCLUDE_DIRS) list (APPEND required_vars Ncursesw_INCLUDE_DIRS)
endif (NOT NCURSESW_FOUND) endif (NOT Ncursesw_FOUND)
include (FindPackageHandleStandardArgs) include (FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS (NCURSESW DEFAULT_MSG ${required_vars}) FIND_PACKAGE_HANDLE_STANDARD_ARGS (Ncursesw DEFAULT_MSG ${required_vars})
mark_as_advanced (NCURSESW_LIBRARIES NCURSESW_INCLUDE_DIRS) mark_as_advanced (Ncursesw_LIBRARIES Ncursesw_INCLUDE_DIRS)