diff options
author | Thiago de Arruda <tpadilha84@gmail.com> | 2014-12-02 07:51:18 -0300 |
---|---|---|
committer | Thiago de Arruda <tpadilha84@gmail.com> | 2014-12-02 07:51:18 -0300 |
commit | 888511862bc7b0850e2695e3edd46212dc78cc47 (patch) | |
tree | 572598e6b335008a71d6bc76faf6c5be7185d91c /cmake | |
parent | 212cb13ca4526350ce761378505536fafb559eab (diff) | |
parent | 6436908ffe1906804a13073dd474e109e8be1d91 (diff) | |
download | rneovim-888511862bc7b0850e2695e3edd46212dc78cc47.tar.gz rneovim-888511862bc7b0850e2695e3edd46212dc78cc47.tar.bz2 rneovim-888511862bc7b0850e2695e3edd46212dc78cc47.zip |
Merge PR #1591 'Prepare to rewrite the terminal UI'
Diffstat (limited to 'cmake')
-rw-r--r-- | cmake/FindLibTermkey.cmake | 48 | ||||
-rw-r--r-- | cmake/FindLibTickit.cmake | 48 | ||||
-rw-r--r-- | cmake/FindLibUnibilium.cmake | 48 |
3 files changed, 144 insertions, 0 deletions
diff --git a/cmake/FindLibTermkey.cmake b/cmake/FindLibTermkey.cmake new file mode 100644 index 0000000000..533f168fe9 --- /dev/null +++ b/cmake/FindLibTermkey.cmake @@ -0,0 +1,48 @@ +# - Try to find libtermkey +# Once done this will define +# LIBTERMKEY_FOUND - System has libtermkey +# LIBTERMKEY_INCLUDE_DIRS - The libtermkey include directories +# LIBTERMKEY_LIBRARIES - The libraries needed to use libtermkey + +find_package(PkgConfig) +if(NOT LIBTERMKEY_USE_BUNDLED) + find_package(PkgConfig) + if (PKG_CONFIG_FOUND) + pkg_check_modules(PC_LIBTERMKEY QUIET libtermkey) + endif() +else() + set(PC_LIBTERMKEY_INCLUDEDIR) + set(PC_LIBTERMKEY_INCLUDE_DIRS) + set(PC_LIBTERMKEY_LIBDIR) + set(PC_LIBTERMKEY_LIBRARY_DIRS) + set(LIMIT_SEARCH NO_DEFAULT_PATH) +endif() + +set(LIBTERMKEY_DEFINITIONS ${PC_LIBTERMKEY_CFLAGS_OTHER}) + +find_path(LIBTERMKEY_INCLUDE_DIR termkey.h + PATHS ${PC_LIBTERMKEY_INCLUDEDIR} ${PC_LIBTERMKEY_INCLUDE_DIRS} + ${LIMIT_SEARCH}) + +# If we're asked to use static linkage, add libuv.a as a preferred library name. +if(LIBTERMKEY_USE_STATIC) + list(APPEND LIBTERMKEY_NAMES + "${CMAKE_STATIC_LIBRARY_PREFIX}termkey${CMAKE_STATIC_LIBRARY_SUFFIX}") +endif() + +list(APPEND LIBTERMKEY_NAMES termkey) + +find_library(LIBTERMKEY_LIBRARY NAMES ${LIBTERMKEY_NAMES} + HINTS ${PC_LIBTERMKEY_LIBDIR} ${PC_LIBTERMKEY_LIBRARY_DIRS} + ${LIMIT_SEARCH}) + +set(LIBTERMKEY_LIBRARIES ${LIBTERMKEY_LIBRARY}) +set(LIBTERMKEY_INCLUDE_DIRS ${LIBTERMKEY_INCLUDE_DIR}) + +include(FindPackageHandleStandardArgs) +# handle the QUIETLY and REQUIRED arguments and set LIBTERMKEY_FOUND to TRUE +# if all listed variables are TRUE +find_package_handle_standard_args(LibTermkey DEFAULT_MSG + LIBTERMKEY_LIBRARY LIBTERMKEY_INCLUDE_DIR) + +mark_as_advanced(LIBTERMKEY_INCLUDE_DIR LIBTERMKEY_LIBRARY) diff --git a/cmake/FindLibTickit.cmake b/cmake/FindLibTickit.cmake new file mode 100644 index 0000000000..c20bf4f74f --- /dev/null +++ b/cmake/FindLibTickit.cmake @@ -0,0 +1,48 @@ +# - Try to find libtickit +# Once done this will define +# LIBTICKIT_FOUND - System has libtickit +# LIBTICKIT_INCLUDE_DIRS - The libtickit include directories +# LIBTICKIT_LIBRARIES - The libraries needed to use libtickit + +find_package(PkgConfig) +if(NOT LIBTICKIT_USE_BUNDLED) + find_package(PkgConfig) + if (PKG_CONFIG_FOUND) + pkg_check_modules(PC_LIBTICKIT QUIET libtickit) + endif() +else() + set(PC_LIBTICKIT_INCLUDEDIR) + set(PC_LIBTICKIT_INCLUDE_DIRS) + set(PC_LIBTICKIT_LIBDIR) + set(PC_LIBTICKIT_LIBRARY_DIRS) + set(LIMIT_SEARCH NO_DEFAULT_PATH) +endif() + +set(LIBTICKIT_DEFINITIONS ${PC_LIBTICKIT_CFLAGS_OTHER}) + +find_path(LIBTICKIT_INCLUDE_DIR tickit.h + PATHS ${PC_LIBTICKIT_INCLUDEDIR} ${PC_LIBTICKIT_INCLUDE_DIRS} + ${LIMIT_SEARCH}) + +# If we're asked to use static linkage, add libuv.a as a preferred library name. +if(LIBTICKIT_USE_STATIC) + list(APPEND LIBTICKIT_NAMES + "${CMAKE_STATIC_LIBRARY_PREFIX}tickit${CMAKE_STATIC_LIBRARY_SUFFIX}") +endif() + +list(APPEND LIBTICKIT_NAMES tickit) + +find_library(LIBTICKIT_LIBRARY NAMES ${LIBTICKIT_NAMES} + HINTS ${PC_LIBTICKIT_LIBDIR} ${PC_LIBTICKIT_LIBRARY_DIRS} + ${LIMIT_SEARCH}) + +set(LIBTICKIT_LIBRARIES ${LIBTICKIT_LIBRARY}) +set(LIBTICKIT_INCLUDE_DIRS ${LIBTICKIT_INCLUDE_DIR}) + +include(FindPackageHandleStandardArgs) +# handle the QUIETLY and REQUIRED arguments and set LIBTICKIT_FOUND to TRUE +# if all listed variables are TRUE +find_package_handle_standard_args(LibTickit DEFAULT_MSG + LIBTICKIT_LIBRARY LIBTICKIT_INCLUDE_DIR) + +mark_as_advanced(LIBTICKIT_INCLUDE_DIR LIBTICKIT_LIBRARY) diff --git a/cmake/FindLibUnibilium.cmake b/cmake/FindLibUnibilium.cmake new file mode 100644 index 0000000000..aace9a40d5 --- /dev/null +++ b/cmake/FindLibUnibilium.cmake @@ -0,0 +1,48 @@ +# - Try to find libunibilium +# Once done this will define +# LIBUNIBILIUM_FOUND - System has libunibilium +# LIBUNIBILIUM_INCLUDE_DIRS - The libunibilium include directories +# LIBUNIBILIUM_LIBRARIES - The libraries needed to use libunibilium + +find_package(PkgConfig) +if(NOT LIBUNIBILIUM_USE_BUNDLED) + find_package(PkgConfig) + if (PKG_CONFIG_FOUND) + pkg_check_modules(PC_LIBUNIBILIUM QUIET libunibilium) + endif() +else() + set(PC_LIBUNIBILIUM_INCLUDEDIR) + set(PC_LIBUNIBILIUM_INCLUDE_DIRS) + set(PC_LIBUNIBILIUM_LIBDIR) + set(PC_LIBUNIBILIUM_LIBRARY_DIRS) + set(LIMIT_SEARCH NO_DEFAULT_PATH) +endif() + +set(LIBUNIBILIUM_DEFINITIONS ${PC_LIBUNIBILIUM_CFLAGS_OTHER}) + +find_path(LIBUNIBILIUM_INCLUDE_DIR unibilium.h + PATHS ${PC_LIBUNIBILIUM_INCLUDEDIR} ${PC_LIBUNIBILIUM_INCLUDE_DIRS} + ${LIMIT_SEARCH}) + +# If we're asked to use static linkage, add libuv.a as a preferred library name. +if(LIBUNIBILIUM_USE_STATIC) + list(APPEND LIBUNIBILIUM_NAMES + "${CMAKE_STATIC_LIBRARY_PREFIX}unibilium${CMAKE_STATIC_LIBRARY_SUFFIX}") +endif() + +list(APPEND LIBUNIBILIUM_NAMES unibilium) + +find_library(LIBUNIBILIUM_LIBRARY NAMES ${LIBUNIBILIUM_NAMES} + HINTS ${PC_LIBUNIBILIUM_LIBDIR} ${PC_LIBUNIBILIUM_LIBRARY_DIRS} + ${LIMIT_SEARCH}) + +set(LIBUNIBILIUM_LIBRARIES ${LIBUNIBILIUM_LIBRARY}) +set(LIBUNIBILIUM_INCLUDE_DIRS ${LIBUNIBILIUM_INCLUDE_DIR}) + +include(FindPackageHandleStandardArgs) +# handle the QUIETLY and REQUIRED arguments and set LIBUNIBILIUM_FOUND to TRUE +# if all listed variables are TRUE +find_package_handle_standard_args(LibUnibilium DEFAULT_MSG + LIBUNIBILIUM_LIBRARY LIBUNIBILIUM_INCLUDE_DIR) + +mark_as_advanced(LIBUNIBILIUM_INCLUDE_DIR LIBUNIBILIUM_LIBRARY) |