From 16b64c339e98f23967396dfd85fd28105af6c587 Mon Sep 17 00:00:00 2001 From: Daniel Hahler Date: Fri, 6 Sep 2019 23:39:41 +0200 Subject: build: rename CMake find modules for LibFindMacros #10928 We are using "LIBFOO" prefixes for `LIBFOO_INCLUDE_DIRS` etc, and therefore need to use this for the PREFIX with LibFindMacros also, so that `"${${PREFIX}_FIND_VERSION}"` gets handled there properly. The alternative would be to either manually handle/set the upper/mixed case variants of those variable additionally, which is not as easy. Keeping the existing names is useful for packagers. Before this the version requirements with `find_package(Unibilium 2.0 REQUIRED)` was not handled (a49cf5126), and it prepares for using a required version with libvterm (initially/wrongly ported in 1896c72a5). --- cmake/FindLIBVTERM.cmake | 10 ++++++++++ cmake/FindLibVterm.cmake | 10 ---------- cmake/FindUNIBILIUM.cmake | 12 ++++++++++++ cmake/FindUnibilium.cmake | 12 ------------ 4 files changed, 22 insertions(+), 22 deletions(-) create mode 100644 cmake/FindLIBVTERM.cmake delete mode 100644 cmake/FindLibVterm.cmake create mode 100644 cmake/FindUNIBILIUM.cmake delete mode 100644 cmake/FindUnibilium.cmake (limited to 'cmake') diff --git a/cmake/FindLIBVTERM.cmake b/cmake/FindLIBVTERM.cmake new file mode 100644 index 0000000000..469494ddfd --- /dev/null +++ b/cmake/FindLIBVTERM.cmake @@ -0,0 +1,10 @@ +# - Try to find libvterm +# Once done this will define +# LIBVTERM_FOUND - System has libvterm +# LIBVTERM_INCLUDE_DIRS - The libvterm include directories +# LIBVTERM_LIBRARIES - The libraries needed to use libvterm + +include(LibFindMacros) + +libfind_pkg_detect(LIBVTERM vterm FIND_PATH vterm.h FIND_LIBRARY vterm) +libfind_process(LIBVTERM REQUIRED) diff --git a/cmake/FindLibVterm.cmake b/cmake/FindLibVterm.cmake deleted file mode 100644 index 469494ddfd..0000000000 --- a/cmake/FindLibVterm.cmake +++ /dev/null @@ -1,10 +0,0 @@ -# - Try to find libvterm -# Once done this will define -# LIBVTERM_FOUND - System has libvterm -# LIBVTERM_INCLUDE_DIRS - The libvterm include directories -# LIBVTERM_LIBRARIES - The libraries needed to use libvterm - -include(LibFindMacros) - -libfind_pkg_detect(LIBVTERM vterm FIND_PATH vterm.h FIND_LIBRARY vterm) -libfind_process(LIBVTERM REQUIRED) diff --git a/cmake/FindUNIBILIUM.cmake b/cmake/FindUNIBILIUM.cmake new file mode 100644 index 0000000000..0bf27b45e2 --- /dev/null +++ b/cmake/FindUNIBILIUM.cmake @@ -0,0 +1,12 @@ +# - Try to find unibilium +# Once done this will define +# UNIBILIUM_FOUND - System has unibilium +# UNIBILIUM_INCLUDE_DIRS - The unibilium include directories +# UNIBILIUM_LIBRARIES - The libraries needed to use unibilium + +include(LibFindMacros) + +libfind_pkg_detect(UNIBILIUM unibilium + FIND_PATH unibilium.h + FIND_LIBRARY unibilium) +libfind_process(UNIBILIUM) diff --git a/cmake/FindUnibilium.cmake b/cmake/FindUnibilium.cmake deleted file mode 100644 index 0bf27b45e2..0000000000 --- a/cmake/FindUnibilium.cmake +++ /dev/null @@ -1,12 +0,0 @@ -# - Try to find unibilium -# Once done this will define -# UNIBILIUM_FOUND - System has unibilium -# UNIBILIUM_INCLUDE_DIRS - The unibilium include directories -# UNIBILIUM_LIBRARIES - The libraries needed to use unibilium - -include(LibFindMacros) - -libfind_pkg_detect(UNIBILIUM unibilium - FIND_PATH unibilium.h - FIND_LIBRARY unibilium) -libfind_process(UNIBILIUM) -- cgit