cmake: modules review

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
Ivailo Monev 2021-03-07 02:40:21 +02:00
parent 1e41cb33b4
commit 8c6c2f1384
62 changed files with 378 additions and 459 deletions

View file

@ -1,5 +1,4 @@
# - Try to find the ACL library
# Once done this will define
# Try to find the ACL library, once done this will define:
#
# ACL_FOUND - system has the ACL library
# ACL_LIBS - The libraries needed to use ACL
@ -18,19 +17,19 @@ check_include_files(acl/libacl.h HAVE_ACL_LIBACL_H)
if(HAVE_ATTR_LIBATTR_H AND HAVE_SYS_XATTR_H AND HAVE_SYS_ACL_H AND HAVE_ACL_LIBACL_H)
set(ACL_HEADERS_FOUND TRUE)
endif (HAVE_ATTR_LIBATTR_H AND HAVE_SYS_XATTR_H AND HAVE_SYS_ACL_H AND HAVE_ACL_LIBACL_H)
endif()
if (ACL_HEADERS_FOUND)
find_library(ACL_LIBS NAMES acl )
find_library(ATTR_LIBS NAMES attr )
endif (ACL_HEADERS_FOUND)
endif()
if(ACL_HEADERS_FOUND AND ACL_LIBS AND ATTR_LIBS)
set(ACL_FOUND TRUE)
set(ACL_LIBS ${ACL_LIBS} ${ATTR_LIBS})
message(STATUS "Found ACL support: ${ACL_LIBS}")
endif (ACL_HEADERS_FOUND AND ACL_LIBS AND ATTR_LIBS)
endif()
mark_as_advanced(ACL_LIBS ATTR_LIBS)

View file

@ -1,12 +1,10 @@
# - Try to find ALSA
#
# Once done this will define
# Try to find the ALSA, once done this will define:
#
# ALSA_FOUND - system has ALSA
# ALSA_INCLUDES - the ALSA include directory
# ALSA_LIBRARIES - the libraries needed to use ALSA
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,11 +1,9 @@
# - Try to find Avahi
#
# Once done this will define
# Try to find the Avahi, once done this will define:
#
# AVAHI_FOUND - system has Avahi
# AVAHI_INCLUDE_DIR - the Avahi include directory
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,13 +1,11 @@
# - Try to find DBusMenuQt library
#
# Once done this will define
# Try to find the DBusMenuQt library, once done this will define:
#
# DBUSMENUQT_FOUND - system has DBusMenuQt
# DBUSMENUQT_INCLUDE_DIR - the DBusMenuQt include directory
# DBUSMENUQT_LIBRARIES - the libraries needed to use DBusMenuQt
# DBUSMENUQT_DEFINITIONS - compiler switches required for using DBusMenuQt
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,5 +1,4 @@
# - Try to find DNSSD
# Once done this will define
# Try to find DNSSD, once done this will define:
#
# DNSSD_FOUND - system has DNSSD
# DNSSD_INCLUDE_DIR - the DNSSD include directory
@ -15,16 +14,13 @@
include(CMakePushCheckState)
FIND_PATH(DNSSD_INCLUDE_DIR dns_sd.h
/usr/include/avahi-compat-libdns_sd/
find_path(DNSSD_INCLUDE_DIR
NAMES dns_sd.h
HINTS /usr/include/avahi-compat-libdns_sd/
)
if(DNSSD_INCLUDE_DIR)
if (APPLE)
set(DNSSD_LIBRARIES "/usr/lib/libSystem.dylib")
else (APPLE)
FIND_LIBRARY(DNSSD_LIBRARIES NAMES dns_sd )
endif (APPLE)
find_library(DNSSD_LIBRARIES NAMES dns_sd)
cmake_reset_check_state()
set(CMAKE_REQUIRED_INCLUDES ${DNSSD_INCLUDE_DIR})
@ -34,17 +30,17 @@ if (DNSSD_INCLUDE_DIR)
if(DNSSD_INCLUDE_DIR AND DNSSD_LIBRARIES AND DNSSD_FUNCTION_FOUND)
set(DNSSD_FOUND TRUE)
endif (DNSSD_INCLUDE_DIR AND DNSSD_LIBRARIES AND DNSSD_FUNCTION_FOUND)
endif (DNSSD_INCLUDE_DIR)
endif()
endif()
if(DNSSD_FOUND)
if (NOT DNSSD_FIND_QUIETLY)
message(STATUS "Found DNSSD: ${DNSSD_LIBRARIES}")
endif (NOT DNSSD_FIND_QUIETLY)
else (DNSSD_FOUND)
endif()
else()
if(DNSSD_FIND_REQUIRED)
message(FATAL_ERROR "Could NOT find DNSSD")
endif (DNSSD_FIND_REQUIRED)
endif (DNSSD_FOUND)
endif()
endif()
MARK_AS_ADVANCED(DNSSD_INCLUDE_DIR DNSSD_LIBRARIES)

View file

@ -1,39 +1,37 @@
# - Try to find the DjVuLibre library
# Once done this will define
# Try to find the DjVuLibre library, once done this will define:
#
# DJVULIBRE_FOUND - system has the DjVuLibre library
# DJVULIBRE_INCLUDE_DIR - the DjVuLibre include directory
# DJVULIBRE_LIBRARY - Link this to use the DjVuLibre library
#
# Copyright (c) 2021 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
if (DJVULIBRE_INCLUDE_DIR AND DJVULIBRE_LIBRARY)
# in cache already
set(DJVULIBRE_FOUND TRUE)
else (DJVULIBRE_INCLUDE_DIR AND DJVULIBRE_LIBRARY)
IF (NOT WIN32)
if(NOT WIN32)
find_package(PkgConfig)
pkg_check_modules(PC_DJVULIBRE ddjvuapi)
endif(NOT WIN32)
endif()
find_path(DJVULIBRE_INCLUDE_DIR libdjvu/ddjvuapi.h
PATHS
${PC_DJVULIBRE_INCLUDEDIR}
${PC_DJVULIBRE_INCLUDE_DIRS}
${GNUWIN32_DIR}/include
set(DJVULIBRE_VERSION ${PC_DJVULIBRE_VERSION})
if(NOT DJVULIBRE_INCLUDE_DIR OR NOT DJVULIBRE_LIBRARY)
find_path(DJVULIBRE_INCLUDE_DIR
NAMES libdjvu/ddjvuapi.h
HINTS $ENV{DJVULIBREDIR}/include
)
find_library(DJVULIBRE_LIBRARY NAMES djvulibre
PATHS
${PC_DJVULIBRE_LIBDIR}
${PC_DJVULIBRE_LIBRARY_DIRS}
${GNUWIN32_DIR}/lib
find_library(DJVULIBRE_LIBRARY
NAMES djvulibre
HINTS $ENV{DJVULIBREDIR}/lib
)
endif()
include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(DjVuLibre DEFAULT_MSG DJVULIBRE_INCLUDE_DIR DJVULIBRE_LIBRARY )
find_package_handle_standard_args(DjVuLibre
VERSION_VAR DJVULIBRE_VERSION
REQUIRED_VARS DJVULIBRE_LIBRARY DJVULIBRE_INCLUDE_DIR
)
mark_as_advanced(DJVULIBRE_INCLUDE_DIR DJVULIBRE_LIBRARY)
endif (DJVULIBRE_INCLUDE_DIR AND DJVULIBRE_LIBRARY)

View file

@ -1,13 +1,11 @@
# - Try to find the Enchant spell checker
#
# Once done this will define
# Try to find the Enchant spell checker, once done this will define:
#
# ENCHANT_FOUND - system has ENCHANT
# ENCHANT_INCLUDE_DIR - the ENCHANT include directory
# ENCHANT_LIBRARIES - the libraries needed to use ENCHANT
# ENCHANT_DEFINITIONS - compiler switches required for using ENCHANT
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,12 +1,10 @@
# - Try to find EPub library
#
# Once done this will define
# Try to find EPub library, once done this will define:
#
# EPUB_FOUND - system has EPub library
# EPUB_INCLUDE_DIR - the EPub library include directory
# EPUB_LIBRARIES - the libraries needed to use EPub library
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,13 +1,11 @@
# - Try to find Exiv2 library
#
# Once done this will define
# Try to find Exiv2 library, once done this will define:
#
# EXIV2_FOUND - system has Exiv2
# EXIV2_INCLUDE_DIR - the Exiv2 include directory
# EXIV2_LIBRARIES - the libraries needed to use Exiv2
# EXIV2_DEFINITIONS - compiler switches required for using Exiv2
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,12 +1,10 @@
# - Try to find FFmpegthumbnailer library
#
# Once done this will define
# Try to find FFmpegthumbnailer library, once done this will define:
#
# FFMPEGTHUMBNAILER_FOUND - system has FFmpegthumbnailer
# FFMPEGTHUMBNAILER_INCLUDES - the FFmpegthumbnailer include directory
# FFMPEGTHUMBNAILER_LIBRARIES - the libraries needed to use FFmpegthumbnailer
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,13 +1,11 @@
# - Try to find the FLAC++ library
#
# Once done this will define
# Try to find the FLAC++ library, once done this will define:
#
# FLAC_FOUND - system has FLAC++
# FLAC_INCLUDES - the FLAC++ include directories
# FLAC_LIBRARIES - the libraries needed to use FLAC++
# FLAC_DEFINITIONS - compiler switches required for using FLAC++
#
# Copyright (c) 2019-2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2019 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,13 +1,11 @@
# - Try to find Fontconfig
#
# Once done this will define
# Try to find Fontconfig, once done this will define:
#
# FONTCONFIG_FOUND - system has Fontconfig
# FONTCONFIG_INCLUDE_DIR -the Fontconfig include directory
# FONTCONFIG_LIBRARIES - the libraries needed to use Fontconfig
# FONTCONFIG_DEFINITIONS - compiler switches required for using Fontconfig
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,5 +1,4 @@
# - Try to find the GIO libraries
# Once done this will define
# Try to find the GIO libraries, once done this will define:
#
# GIO_FOUND - system has GIO
# GIO_INCLUDE_DIR - the GIO include directory
@ -20,24 +19,27 @@ pkg_check_modules(PC_LibGIO QUIET gio-2.0)
find_path(GIO_MAIN_INCLUDE_DIR
NAMES glib.h
PATH_SUFFIXES glib-2.0
HINTS ${PC_LibGIO_INCLUDEDIR}
PATH_SUFFIXES glib-2.0)
)
find_library(GIO_LIBRARIES
NAMES gio-2.0
HINTS ${PC_LibGLIB2_LIBDIR})
HINTS ${PC_LibGLIB2_LIBDIR}
)
get_filename_component(GIOLibDir "${GIO_LIBRARIES}" PATH)
find_path(GIO_INTERNAL_INCLUDE_DIR glibconfig.h
find_path(GIO_INTERNAL_INCLUDE_DIR
NAMES glibconfig.h
PATH_SUFFIXES glib-2.0/include
PATHS ${_LibGIOIncDir} "${GIOLibDir}" ${CMAKE_SYSTEM_LIBRARY_PATH}
NO_DEFAULT_PATH)
HINTS ${_LibGIOIncDir} "${GIOLibDir}" ${CMAKE_SYSTEM_LIBRARY_PATH}
)
find_path(GIO_INTERNAL_INCLUDE_DIR glibconfig.h
PATH_SUFFIXES glib-2.0/include
PATHS ${_LibGIOIncDir} "${GIOLibDir}" ${CMAKE_SYSTEM_LIBRARY_PATH})
HINTS ${_LibGIOIncDir} "${GIOLibDir}" ${CMAKE_SYSTEM_LIBRARY_PATH}
)
set(GIO_INCLUDE_DIR "${GIO_MAIN_INCLUDE_DIR}")

View file

@ -1,5 +1,4 @@
# - Try to find the GLIB2 libraries
# Once done this will define
# Try to find the GLIB2 libraries, once done this will define:
#
# GLIB2_FOUND - system has glib2
# GLIB2_INCLUDE_DIR - the glib2 include directory
@ -21,8 +20,9 @@ pkg_check_modules(PC_LibGLIB2 QUIET glib-2.0)
find_path(GLIB2_MAIN_INCLUDE_DIR
NAMES glib.h
PATH_SUFFIXES glib-2.0
HINTS ${PC_LibGLIB2_INCLUDEDIR}
PATH_SUFFIXES glib-2.0)
)
find_library(GLIB2_LIBRARY
NAMES glib-2.0
@ -34,9 +34,11 @@ set(GLIB2_LIBRARIES ${GLIB2_LIBRARY})
# search the glibconfig.h include dir under the same root where the library is found
get_filename_component(glib2LibDir "${GLIB2_LIBRARIES}" PATH)
find_path(GLIB2_INTERNAL_INCLUDE_DIR glibconfig.h
find_path(GLIB2_INTERNAL_INCLUDE_DIR
NAMES glibconfig.h
PATH_SUFFIXES glib-2.0/include
HINTS ${PC_LibGLIB2_INCLUDEDIR} "${glib2LibDir}" ${CMAKE_SYSTEM_LIBRARY_PATH})
HINTS ${PC_LibGLIB2_INCLUDEDIR} "${glib2LibDir}" ${CMAKE_SYSTEM_LIBRARY_PATH}
)
set(GLIB2_INCLUDE_DIR "${GLIB2_MAIN_INCLUDE_DIR}")

View file

@ -1,11 +1,10 @@
# - Try to find GMP
# Once done this will define
# Try to find GMP, once done this will define:
#
# GMP_FOUND - system has GMP
# GMP_INCLUDE_DIR - the GMP include directory
# GMP_LIBRARIES - the libraries needed to use GMP
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,12 +1,11 @@
# - Try to detect the GSSAPI support
# Once done this will define
# Try to detect the GSSAPI support, once done this will define:
#
# GSSAPI_FOUND - system supports GSSAPI
# GSSAPI_INCS - the GSSAPI include directory
# GSSAPI_LIBS - the libraries needed to use GSSAPI
# GSSAPI_FLAVOR - the type of API - MIT or HEIMDAL
# Copyright (c) 2006, Pino Toscano, <toscano.pino@tiscali.it>
# Copyright (c) 2006 Pino Toscano <toscano.pino@tiscali.it>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,31 +1,27 @@
# - Try to find GettextPO
#
# Once done this will define
# Try to find GettextPO, once done this will define:
#
# GETTEXTPO_FOUND - System has GETTEXTPO
# GETTEXTPO_INCLUDE_DIR - The GETTEXTPO include directory
# GETTEXTPO_LIBRARY - The library needed to use GETTEXTPO
# Copyright (c) 2012, Ni Hui <shuizhuyuanluo@126.com>
# Based off FindLibXml2.cmake from CMake 2.6.4 by Alexander Neundorf <neundorf@kde.org>
#
# Copyright (c) 2021 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
find_path(GETTEXTPO_INCLUDE_DIR
NAMES gettext-po.h
HINTS $ENV{GETTEXTPODIR}/include
)
if(GETTEXTPO_INCLUDE_DIR AND GETTEXTPO_LIBRARY)
# in cache already
set(GETTEXTPO_FIND_QUIETLY TRUE)
endif(GETTEXTPO_INCLUDE_DIR AND GETTEXTPO_LIBRARY)
find_path(GETTEXTPO_INCLUDE_DIR gettext-po.h)
find_library(GETTEXTPO_LIBRARY NAMES gettextpo)
find_library(GETTEXTPO_LIBRARY
NAMES gettextpo
HINTS $ENV{GETTEXTPODIR}/lib
)
include(FindPackageHandleStandardArgs)
# handle the QUIETLY and REQUIRED arguments and set GETTEXTPO_FOUND to TRUE if
# all listed variables are TRUE
find_package_handle_standard_args(GettextPO DEFAULT_MSG GETTEXTPO_LIBRARY GETTEXTPO_INCLUDE_DIR)
find_package_handle_standard_args(GettextPO
REQUIRED_VARS GETTEXTPO_LIBRARY GETTEXTPO_INCLUDE_DIR
)
mark_as_advanced(GETTEXTPO_INCLUDE_DIR GETTEXTPO_LIBRARY)

View file

@ -1,13 +1,11 @@
# - Try to find HUNSPELL
#
# Once done this will define
# Try to find HUNSPELL, once done this will define:
#
# HUNSPELL_FOUND - system has HUNSPELL
# HUNSPELL_INCLUDE_DIR - the HUNSPELL include directory
# HUNSPELL_LIBRARIES - the libraries needed to use HUNSPELL
# HUNSPELL_DEFINITIONS - compiler switches required for using HUNSPELL
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,5 +1,4 @@
# - Try to find HUPnP library
# Once done this will define
# Try to find HUPnP library, once done this will define:
#
# HUPNP_FOUND - system has HUPnP
# HUPNP_INCLUDE_DIR - the LIBHUpnp include directory

View file

@ -1,13 +1,11 @@
# - Try to find IBUS
#
# Once done this will define
# Try to find IBUS, once done this will define:
#
# IBUS_FOUND - system has IBUS
# IBUS_INCLUDE_DIR - the IBUS include directory
# IBUS_LIBRARIES - the libraries needed to use IBUS
# IBUS_DEFINITIONS - compiler switches required for using IBUS
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,4 +1,4 @@
# cmake macro to test if libksane is installed
# Try to find KSane, once done this will define:
#
# KSANE_FOUND - system has KSANE libs
# KSANE_INCLUDE_DIR - the KSANE include directory

View file

@ -1,5 +1,3 @@
# Copyright (C) 2008,2010,2011 by Volker Lanz <vl@fidra.de>
#
# Redistribution and use in source and binary forms, with or without

View file

@ -1,12 +1,10 @@
# - Try to find ATA library
#
# Once done this will define
# Try to find ATA library, once done this will define:
#
# LIBATASMART_FOUND - system has ATA library
# LIBATASMART_INCLUDES - the ATA library include directory
# LIBATASMART_LIBRARIES - the libraries needed to use ATA library
#
# Copyright (c) 2021, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2021 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,12 +1,10 @@
# Try to find the Attica library
#
# Once done this will define
# Try to find the Attica library, once done this will define:
#
# LIBATTICA_FOUND - system has Attica
# LIBATTICA_LIBRARIES - the Attica include directory
# LIBATTICA_INCLUDE_DIR - the libraries needed to use Attica
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,12 +1,10 @@
# - Try to find libdrm library
#
# Once done this will define
# Try to find libdrm library, once done this will define:
#
# LIBDRM_FOUND - system has libdrm
# LIBDRM_INCLUDE_DIR - the libdrm include directory
# LIBDRM_LIBRARIES - the libraries needed to use libdrm
#
# Copyright (c) 2021, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2021 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,12 +1,10 @@
# - Try to find GPS library
#
# Once done this will define
# Try to find GPS library, once done this will define:
#
# LIBGPS_FOUND - system has GPS library
# LIBGPS_INCLUDE_DIR - the GPS library include directory
# LIBGPS_LIBRARIES - the libraries needed to use GPS library
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,12 +1,10 @@
# - Try to find the libgcrypt library
#
# Once done this will define
# Try to find the libgcrypt library, once done this will define:
#
# LIBGCRYPT_FOUND - system has libgcrypt
# LIBGCRYPT_INCLUDE_DIR - the libgcrypt include directory
# LIBGCRYPT_LIBRARIES - the libraries needed to use libgcrypt
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,12 +1,10 @@
# - Try to find konqueror library
#
# Once done this will define
# Try to find konqueror library, once done this will define:
#
# LIBKONQ_FOUND - system has konqueror library
# LIBKONQ_INCLUDE_DIR - the konqueror library include directory
# LIBKONQ_LIBRARY - the konqueror library
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,12 +1,10 @@
# - Try to find the LibLZMA
#
# Once done this will define
# Try to find the LibLZMA, once done this will define:
#
# LIBLZMA_FOUND - system has LibLZMA
# LIBLZMA_INCLUDE_DIRS - the LibLZMA include directory
# LIBLZMA_LIBRARIES - the libraries needed to use LibLZMA
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,11 +1,10 @@
# - Try to find the libmms library
# Once done this will define
# Try to find the libmms library, once done this will define:
#
# LIBMMS_FOUND - system has libmms
# LIBMMS_INCLUDE_DIR - the libmms include directory
# LIBMMS_LIBRARIES - the libraries needed to use libmms
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,13 +1,11 @@
# - Try to find LibRaw library
#
# Once done this will define
# Try to find LibRaw library, once done this will define:
#
# LIBRAW_FOUND - system has LibRaw
# LIBRAW_INCLUDE_DIR - the LibRaw include directory
# LIBRAW_LIBRARIES - the libraries needed to use LibRaw
# LIBRAW_DEFINITIONS - compiler switches required for using LibRaw
#
# Copyright (c) 2021, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2021 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,13 +1,11 @@
# - Try to find LibSSH
#
# Once done this will define
# Try to find LibSSH, once done this will define:
#
# LIBSSH_FOUND - system has LibSSH
# LIBSSH_INCLUDE_DIRS - the LibSSH include directory
# LIBSSH_LIBRARIES - the libraries needed to use LibSSH
# LIBSSH_DEFINITIONS - compiler switches required for using LibSSH
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,12 +1,10 @@
# - Try to find the libspectre PS library
#
# Once done this will define
# Try to find the libspectre PS library, once done this will define:
#
# LIBSPECTRE_FOUND - system has libspectre
# LIBSPECTRE_INCLUDE_DIR - the libspectre include directory
# LIBSPECTRE_LIBRARY - Link this to use libspectre
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,12 +1,10 @@
# - Try to find libusb
#
# Once done this will define
# Try to find libusb, once done this will define:
#
# LIBUSB_FOUND - system has libusb
# LIBUSB_INCLUDES - the libusb include directory
# LIBUSB_LIBRARIES - the libraries needed to use libusb
#
# Copyright (c) 2016-2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2016 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,29 +1,25 @@
# - Try to find LibXKlavier
# Once done this will define
# Try to find LibXKlavier, once done this will define:
#
# LIBXKLAVIER_FOUND - system has LibXKlavier
# LIBXKLAVIER_LDFLAGS - the libraries needed to use LibXKlavier
# LIBXKLAVIER_CFLAGS - Compiler switches required for using LibXKlavier
# LIBXKLAVIER_VERSION - Version of LibXKlavier
#
# Copyright (c) 2021 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
if (LIBXKLAVIER_CFLAGS AND LIBXKLAVIER_LDFLAGS)
if(NOT WIN32)
include(FindPkgConfig)
pkg_check_modules(LIBXKLAVIER QUIET libxklavier>=3.0)
endif()
# in cache already
SET(LIBXKLAVIER_FOUND TRUE)
else (LIBXKLAVIER_CFLAGS AND LIBXKLAVIER_LDFLAGS)
IF (NOT WIN32)
# use pkg-config to get the directories and then use these values
# in the FIND_PATH() and FIND_LIBRARY() calls
INCLUDE(UsePkgConfig)
pkg_check_modules(LIBXKLAVIER libxklavier>=3.0)
ENDIF (NOT WIN32)
include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(LibXKlavier DEFAULT_MSG LIBXKLAVIER_CFLAGS LIBXKLAVIER_LDFLAGS)
find_package_handle_standard_args(LibXKlavier
VERSION_VAR LIBXKLAVIER_VERSION
REQUIRED_VARS LIBXKLAVIER_CFLAGS LIBXKLAVIER_LDFLAGS
)
MARK_AS_ADVANCED(LIBXKLAVIER_CFLAGS LIBXKLAVIER_LDFLAGS LIBXKLAVIER_VERSION)
endif (LIBXKLAVIER_CFLAGS AND LIBXKLAVIER_LDFLAGS)
mark_as_advanced(LIBXKLAVIER_CFLAGS LIBXKLAVIER_LDFLAGS)

View file

@ -1,5 +1,4 @@
# Try to find Libintl functionality
# Once done this will define
# Try to find Libintl functionality, once done this will define:
#
# LIBINTL_FOUND - system has Libintl
# LIBINTL_INCLUDE_DIR - Libintl include directory

View file

@ -1,12 +1,10 @@
# - Try to find MPFR
#
# Once done this will define
# Try to find MPFR, once done this will define:
#
# MPFR_FOUND - system has MPFR
# MPFR_INCLUDE_DIR - the MPFR include directory
# MPFR_LIBRARIES - the libraries needed to use MPFR
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,12 +1,10 @@
# - Try to find MPV
#
# Once done this will define
# Try to find MPV, once done this will define:
#
# MPV_FOUND - system has MPV
# MPV_INCLUDES - the MPV include directory
# MPV_LIBRARIES - the libraries needed to use MPV
#
# Copyright (c) 2015-2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2015 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,13 +1,11 @@
# - Try to find the libmtp library
#
# Once done this will define
# Try to find the libmtp library, once done this will define:
#
# MTP_FOUND - system has libmtp
# MTP_INCLUDE_DIR - the libmtp include directory
# MTP_LIBRARIES - the libraries needed to use libmtp
# MTP_DEFINITIONS - compiler switches required for using libmtp
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,5 +1,4 @@
# - Try to find NetworkManager
# Once done this will define
# Try to find NetworkManager, once done this will define:
#
# NETWORKMANAGER_FOUND - system has NetworkManager
# NETWORKMANAGER_INCLUDE_DIRS - the NetworkManager include directories
@ -9,7 +8,7 @@
# Copyright (c) 2006, Alexander Neundorf, <neundorf@kde.org>
# Copyright (c) 2007, Will Stephenson, <wstephenson@kde.org>
# Copyright (c) 2015, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2015 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,5 +1,4 @@
# Try to find the OpenEXR libraries
# This check defines:
# Try to find the OpenEXR libraries, once done this will define:
#
# OPENEXR_FOUND - system has OpenEXR
# OPENEXR_INCLUDE_DIR - OpenEXR include directory

View file

@ -1,5 +1,4 @@
# - Try to find OpenGLES
# Once done this will define
# Try to find OpenGLES, once done this will define:
#
# OPENGLES_FOUND - system has OpenGLES and EGL
# OPENGL_EGL_FOUND - system has EGL
@ -9,44 +8,41 @@
# OPENGLES_EGL_LIBRARY - the EGL library
# OPENGLES_LIBRARIES - all libraries needed for OpenGLES
# OPENGLES_INCLUDES - all includes needed for OpenGLES
#
# Copyright (c) 2021 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
FIND_PATH(OPENGLES_INCLUDE_DIR GLES2/gl2.h
/usr/openwin/share/include
/opt/graphics/OpenGL/include /usr/X11R6/include
/usr/include
find_path(OPENGLES_INCLUDE_DIR
NAMES GLES2/gl2.h
HINTS /usr/X11R7/include /usr/X11R6/include
)
FIND_LIBRARY(OPENGLES_LIBRARY
find_library(OPENGLES_LIBRARY
NAMES GLESv2
PATHS /opt/graphics/OpenGL/lib
/usr/openwin/lib
/usr/shlib /usr/X11R6/lib
/usr/lib
HINTS /usr/X11R7/lib /usr/X11R6/lib
)
FIND_PATH(OPENGLES_EGL_INCLUDE_DIR EGL/egl.h
/usr/openwin/share/include
/opt/graphics/OpenGL/include /usr/X11R6/include
/usr/include
find_path(OPENGLES_EGL_INCLUDE_DIR
NAMES EGL/egl.h
HINTS /usr/X11R7/include /usr/X11R6/include
)
FIND_LIBRARY(OPENGLES_EGL_LIBRARY
find_library(OPENGLES_EGL_LIBRARY
NAMES EGL
PATHS /usr/shlib /usr/X11R6/lib
/usr/lib
HINTS /usr/X11R7/lib /usr/X11R6/lib
)
SET(OPENGL_EGL_FOUND "NO")
IF(OPENGLES_EGL_LIBRARY AND OPENGLES_EGL_INCLUDE_DIR)
SET(OPENGL_EGL_FOUND "YES")
ENDIF()
set(OPENGL_EGL_FOUND "NO")
if(OPENGLES_EGL_LIBRARY AND OPENGLES_EGL_INCLUDE_DIR)
set(OPENGL_EGL_FOUND "YES")
endif()
SET(OPENGLES_FOUND "NO")
IF(OPENGLES_LIBRARY AND OPENGLES_INCLUDE_DIR AND
OPENGLES_EGL_LIBRARY AND OPENGLES_EGL_INCLUDE_DIR)
SET(OPENGLES_LIBRARIES ${OPENGLES_LIBRARY} ${OPENGLES_LIBRARIES}
${OPENGLES_EGL_LIBRARY})
SET(OPENGLES_INCLUDES ${OPENGLES_INCLUDE_DIR} ${OPENGLES_EGL_INCLUDE_DIR})
SET(OPENGLES_FOUND "YES")
ENDIF()
set(OPENGLES_FOUND "NO")
if(OPENGLES_LIBRARY AND OPENGLES_INCLUDE_DIR AND OPENGLES_EGL_LIBRARY AND OPENGLES_EGL_INCLUDE_DIR)
set(OPENGLES_LIBRARIES ${OPENGLES_LIBRARY} ${OPENGLES_EGL_LIBRARY})
set(OPENGLES_INCLUDES ${OPENGLES_INCLUDE_DIR} ${OPENGLES_EGL_INCLUDE_DIR})
set(OPENGLES_FOUND "YES")
endif()

View file

@ -1,12 +1,11 @@
# - Try to find the PAM libraries
# Once done this will define
# Try to find the PAM libraries, once done this will define:
#
# PAM_FOUND - system has pam
# PAM_INCLUDE_DIR - the pam include directory
# PAM_LIBRARIES - libpam library
# PAM_MESSAGE_CONST - libpam pam_message struct is const
#
# Copyright (c) 2021, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2021 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,12 +1,10 @@
# - Try to find the pciutils directory library
#
# Once done this will define
# Try to find the pciutils directory library, once done this will define:
#
# PCIUTILS_FOUND - system has PCIUtils
# PCIUTILS_INCLUDE_DIR - the PCIUTILS include directory
# PCIUTILS_LIBRARIES - the libraries needed to use PCIUtils
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,13 +1,11 @@
# - Try to find the Qt4 binding of the Poppler library
#
# Once done this will define
# Try to find the Qt4 binding of the Poppler library, once done this will define:
#
# POPPLER_QT4_FOUND - system has poppler-qt4
# POPPLER_QT4_INCLUDE_DIR - the poppler-qt4 include directory
# POPPLER_QT4_LIBRARIES - the libraries needed to use poppler-qt4
# POPPLER_QT4_DEFINITIONS - compiler switches required for using poppler-qt4
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,13 +1,11 @@
# - Try to find QCA2 (Qt Cryptography Architecture 2)
#
# Once done this will define
# Try to find QCA2 (Qt Cryptography Architecture 2), once done this will define:
#
# QCA2_FOUND - system has QCA2
# QCA2_INCLUDE_DIR - the QCA2 include directory
# QCA2_LIBRARIES - the libraries needed to use QCA2
# QCA2_DEFINITIONS - compiler switches required for using QCA2
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,12 +1,10 @@
# - Try to find Qalculate
#
# Once done this will define
# Try to find Qalculate, once done this will define:
#
# QALCULATE_FOUND - system has Qalculate
# QALCULATE_INCLUDE_DIR - the Qalculate include directory
# QALCULATE_LIBRARIES - the Qalculate libraries
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,12 +1,10 @@
# - Try to find the raw1394
#
# Once done this will define
# Try to find the raw1394, once done this will define:
#
# RAW1394_FOUND - system has raw1394
# RAW1394_INCLUDE_DIR - the raw1394 include directory
# RAW1394_LIBRARIES - the libraries needed to use raw1394
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,12 +1,11 @@
# - Try to find the SCIM
# Once done this will define
# Try to find the SCIM, once done this will define:
#
# SCIM_FOUND - system has SCIM
# SCIM_INCLUDE_DIR - the SCIM include directory
# SCIM_LIBRARIES - the libraries needed to use SCIM
# SCIM_DEFINITIONS - compiler switches required for using SCIM
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,5 +1,4 @@
# - Try to find the samba directory library
# Once done this will define
# Try to find the samba directory library, once done this will define:
#
# SAMBA_FOUND - system has SAMBA
# SAMBA_INCLUDE_DIR - the SAMBA include directory

View file

@ -1,21 +1,28 @@
# cmake macro to test if we use sane
# Try to find SANE, once done this will define:
#
# SANE_FOUND - system has SANE libs
# SANE_INCLUDE_DIR - the SANE include directory
# SANE_LIBRARIES - The libraries needed to use SANE
# Copyright (c) 2006, Marcus Hufgard <hufgardm@hufgard.de> 2006
#
# Copyright (c) 2021 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
FIND_PATH(SANE_INCLUDE_DIR sane/sane.h)
FIND_LIBRARY(SANE_LIBRARY NAMES sane libsane
PATH_SUFFIXES sane
find_path(SANE_INCLUDE_DIR
NAMES sane/sane.h
HINTS $ENV{SANEDIR}/include
)
INCLUDE(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Sane DEFAULT_MSG SANE_LIBRARY SANE_INCLUDE_DIR )
find_library(SANE_LIBRARY
NAMES sane
PATH_SUFFIXES sane
HINTS $ENV{SANEDIR}/lib
)
MARK_AS_ADVANCED(SANE_INCLUDE_DIR SANE_LIBRARY)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(Sane
REQUIRED_VARS SANE_LIBRARY SANE_INCLUDE_DIR
)
mark_as_advanced(SANE_INCLUDE_DIR SANE_LIBRARY)

View file

@ -1,16 +1,28 @@
# - Try to find the sensors directory library
# Once done this will define
# Try to find the sensors directory library, once done this will define:
#
# SENSORS_FOUND - system has SENSORS
# SENSORS_INCLUDE_DIR - the SENSORS include directory
# SENSORS_LIBRARIES - The libraries needed to use SENSORS
#
# Copyright (c) 2021 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
FIND_PATH(SENSORS_INCLUDE_DIR sensors/sensors.h)
FIND_PATH(SENSORS_INCLUDE_DIR
NAMES sensors/sensors.h
HINTS $ENV{SENSORSDIR}/include
)
FIND_LIBRARY(SENSORS_LIBRARIES NAMES sensors)
FIND_LIBRARY(SENSORS_LIBRARIES
NAMES sensors
HINTS $ENV{SENSORSDIR}/lib
)
include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Sensors DEFAULT_MSG SENSORS_INCLUDE_DIR SENSORS_LIBRARIES )
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Sensors
REQUIRED_VARS SENSORS_LIBRARIES SENSORS_INCLUDE_DIR
)
MARK_AS_ADVANCED(SENSORS_INCLUDE_DIR SENSORS_LIBRARIES)

View file

@ -1,6 +1,4 @@
# - Try to find the shared-mime-info package
#
# Once done this will define
# Try to find the shared-mime-info package, once done this will define:
#
# SHAREDMIMEINFO_FOUND - system has the shared-mime-info package
# UPDATE_MIME_DATABASE_EXECUTABLE - the update-mime-database executable
@ -9,7 +7,6 @@
# standard syntax, e.g. find_package(SharedMimeInfo 0.20)
#
# For backward compatibility, the following two variables are also supported:
# SHARED_MIME_INFO_FOUND - same as SHAREDMIMEINFO_FOUND
# SHARED_MIME_INFO_MINIMUM_VERSION - set to the minimum version you need, default is 0.18.
# When both are used, i.e. the version is set in the find_package() call and
# SHARED_MIME_INFO_MINIMUM_VERSION is set, the version specified in the find_package()
@ -24,18 +21,17 @@
# Support SHARED_MIME_INFO_MINIMUM_VERSION for compatibility:
if(NOT SharedMimeInfo_FIND_VERSION)
set(SharedMimeInfo_FIND_VERSION "${SHARED_MIME_INFO_MINIMUM_VERSION}")
endif(NOT SharedMimeInfo_FIND_VERSION)
endif()
# the minimum version of shared-mime-database we require
if(NOT SharedMimeInfo_FIND_VERSION)
set(SharedMimeInfo_FIND_VERSION "0.18")
endif(NOT SharedMimeInfo_FIND_VERSION)
endif()
find_program (UPDATE_MIME_DATABASE_EXECUTABLE NAMES update-mime-database)
# Store the version number in the cache, so we don't have to search the next time again:
if (UPDATE_MIME_DATABASE_EXECUTABLE AND NOT SHAREDMIMEINFO_VERSION)
execute_process(
COMMAND ${UPDATE_MIME_DATABASE_EXECUTABLE} -v
RETURN_VALUE _null
@ -47,22 +43,17 @@ if (UPDATE_MIME_DATABASE_EXECUTABLE AND NOT SHAREDMIMEINFO_VERSION)
"\\1" smiVersion "${_smiVersionRaw}")
set(SHAREDMIMEINFO_VERSION "${smiVersion}" CACHE STRING "Version number of SharedMimeInfo" FORCE)
endif (UPDATE_MIME_DATABASE_EXECUTABLE AND NOT SHAREDMIMEINFO_VERSION)
endif()
# Use the new FPHSA() syntax:
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(SharedMimeInfo REQUIRED_VARS UPDATE_MIME_DATABASE_EXECUTABLE
VERSION_VAR SHAREDMIMEINFO_VERSION )
# For backward compatibility:
set(SHARED_MIME_INFO_FOUND ${SHAREDMIMEINFO_FOUND} )
# message(FATAL_ERROR "Could NOT find shared-mime-info. See http://freedesktop.org/wiki/Software/shared-mime-info.")
find_package_handle_standard_args(SharedMimeInfo
VERSION_VAR SHAREDMIMEINFO_VERSION
REQUIRED_VARS UPDATE_MIME_DATABASE_EXECUTABLE
)
mark_as_advanced(UPDATE_MIME_DATABASE_EXECUTABLE)
macro(UPDATE_XDG_MIMETYPES _path)
get_filename_component(_xdgmimeDir "${_path}" NAME)
if("${_xdgmimeDir}" STREQUAL packages )
@ -77,6 +68,6 @@ if (NOT DESTDIR_VALUE)
# under Windows relative paths are used, that's why it runs from CMAKE_INSTALL_PREFIX
execute_process(COMMAND ${UPDATE_MIME_DATABASE_EXECUTABLE} ${_xdgmimeDir}
WORKING_DIRECTORY \"${CMAKE_INSTALL_PREFIX}\")
endif (NOT DESTDIR_VALUE)
endif()
")
endmacro (UPDATE_XDG_MIMETYPES)
endmacro()

View file

@ -1,6 +1,4 @@
# - Try to find speech-dispatcher
#
# Once done this will define
# Try to find speech-dispatcher, once done this will define:
#
# SPEECHD_FOUND - system has speech-dispatcher
# SPEECHD_INCLUDE_DIR - the speech-dispatcher include directory

View file

@ -1,12 +1,10 @@
# - Try to find Sqlite
#
# Once done this will define
# Try to find Sqlite, once done this will define:
#
# SQLITE_FOUND - system has Sqlite
# SQLITE_INCLUDE_DIR - the Sqlite include directory
# SQLITE_LIBRARIES - the libraries needed to use Sqlite
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,13 +1,11 @@
# - Try to find Strigi
#
# Once done this will define
# Try to find Strigi, once done this will define:
#
# STRIGI_FOUND - system has Strigi
# STRIGI_INCLUDE_DIR - the Strigi include directory
# STRIGI_STREAMS_LIBRARY - the libraries needed to use Strigi streams
# STRIGI_STREAMANALYZER_LIBRARY - the libraries needed to use Strigi stream analyzer
#
# Copyright (c) 2021, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2021 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
@ -39,6 +37,8 @@ if(NOT STRIGI_INCLUDE_DIR OR NOT STRIGI_STREAMS_LIBRARY OR NOT STRIGI_STREAMANAL
NAMES streamanalyzer
HINTS $ENV{STRIGIDIR}/lib
)
else()
link_directories(${PC_LIBSTREAMS_LIBDIR} ${PC_LIBSTREAMANALYZER_LIBDIR})
endif()
include(FindPackageHandleStandardArgs)

View file

@ -1,19 +1,22 @@
# - Try to find Sudo
# Once done this will define
# Try to find Sudo, once done this will define:
#
# SUDO_FOUND - sudo has been found
# SUDO_EXECUTABLE - the sudo executable path
#
# Copyright (c) 2021 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
find_program(SUDO_EXECUTABLE NAMES sudo
find_program(SUDO_EXECUTABLE
NAMES sudo
HINTS ${KDE4_BIN_INSTALL_DIR}
DOC "sudo -- execute a command as another user"
)
if(SUDO_EXECUTABLE)
set(SUDO_FOUND TRUE)
message(STATUS "Found Sudo: ${SUDO_EXECUTABLE}")
else(SUDO_EXECUTABLE)
set(SUDO_FOUND FALSE)
message(STATUS "Sudo not found.")
endif(SUDO_EXECUTABLE)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(Sudo
REQUIRED_VARS SUDO_EXECUTABLE
)
mark_as_advanced(SUDO_EXECUTABLE)

View file

@ -1,12 +1,10 @@
# - Try to find the Taglib
#
# Once done this will define
# Try to find the Taglib, once done this will define:
#
# TAGLIB_FOUND - system has Taglib
# TAGLIB_LIBRARIES - the libraries needed to use Taglib
# TAGLIB_CFLAGS - the Taglib C flags
#
# Copyright (c) 2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2020 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,5 +1,4 @@
# - Try to find UDev
# Once done this will define
# Try to find UDev, once done this will define:
#
# UDEV_FOUND - system has UDev
# UDEV_INCLUDE_DIR - the libudev include directory

View file

@ -1,12 +1,10 @@
# - Try to find libwebp
#
# Once done this will define
# Try to find libwebp, once done this will define:
#
# WEBP_FOUND - system has libwebp
# WEBP_INCLUDES - the libwebp include directory
# WEBP_LIBRARIES - the libraries needed to use libwebp
#
# Copyright (c) 2015-2020, Ivailo Monev, <xakepa10@gmail.com>
# Copyright (c) 2015 Ivailo Monev <xakepa10@gmail.com>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

View file

@ -1,5 +1,4 @@
# - Try to find libX11-xcb
# Once done this will define
# Try to find libX11-xcb, once done this will define:
#
# X11_XCB_FOUND - system has libX11-xcb
# X11_XCB_LIBRARIES - Link these to use libX11-xcb

View file

@ -1,6 +1,4 @@
# Try to find XCB on a Unix system
#
# This will define:
# Try to find XCB on a Unix system, once done this will define:
#
# XCB_FOUND - True if xcb is available
# XCB_LIBRARIES - Link these to use xcb
@ -34,14 +32,16 @@ IF (NOT WIN32)
IF (XCB_INCLUDE_DIR AND XCB_LIBRARIES)
# In the cache already
SET(XCB_FIND_QUIETLY TRUE)
ENDIF (XCB_INCLUDE_DIR AND XCB_LIBRARIES)
ENDIF ()
# Use pkg-config to get the directories and then use these values
# in the FIND_PATH() and FIND_LIBRARY() calls
FIND_PACKAGE(PkgConfig)
PKG_CHECK_MODULES(PKG_XCB QUIET xcb xcb-util xcb-composite xcb-xfixes xcb-damage xcb-render xcb-randr
PKG_CHECK_MODULES(PKG_XCB QUIET
xcb xcb-util xcb-composite xcb-xfixes xcb-damage xcb-render xcb-randr
xcb-shape xcb-dri2 xcb-glx xcb-shm xcb-xv xcb-sync xcb-record
xcb-xtest xcb-icccm xcb-ewmh xcb-image xcb-renderutil xcb-keysyms)
xcb-xtest xcb-icccm xcb-ewmh xcb-image xcb-renderutil xcb-keysyms
)
SET(XCB_DEFINITIONS ${PKG_XCB_CFLAGS})
@ -75,17 +75,21 @@ IF (NOT WIN32)
FIND_LIBRARY(XCB_XTEST_LIBRARIES NAMES xcb-xtest HINTS ${PKG_XCB_LIBRARY_DIRS})
FIND_LIBRARY(XCB_RECORD_LIBRARIES NAMES xcb-record HINTS ${PKG_XCB_LIBRARY_DIRS})
set(XCB_INCLUDE_DIR ${XCB_XCB_INCLUDE_DIR} ${XCB_COMPOSITE_INCLUDE_DIR} ${XCB_XFIXES_INCLUDE_DIR}
set(XCB_INCLUDE_DIR
${XCB_XCB_INCLUDE_DIR} ${XCB_COMPOSITE_INCLUDE_DIR} ${XCB_XFIXES_INCLUDE_DIR}
${XCB_DAMAGE_INCLUDE_DIR} ${XCB_RENDER_INCLUDE_DIR} ${XCB_RANDR_INCLUDE_DIR}
${XCB_SHAPE_INCLUDE_DIR} ${XCB_SHM_INCLUDE_DIR} ${XCB_SYNC_INCLUDE_DIR}
${XCB_IMAGE_INCLUDE_DIR} ${XCB_RENDERUTIL_INCLUDE_DIR} ${XCB_KEYSYMS_INCLUDE_DIR}
${XCB_XTEST_INCLUDE_DIR} ${XCB_RECORD_INCLUDE_DIR})
${XCB_XTEST_INCLUDE_DIR} ${XCB_RECORD_INCLUDE_DIR}
)
set(XCB_LIBRARIES ${XCB_XCB_LIBRARIES} ${XCB_COMPOSITE_LIBRARIES} ${XCB_XFIXES_LIBRARIES}
set(XCB_LIBRARIES
${XCB_XCB_LIBRARIES} ${XCB_COMPOSITE_LIBRARIES} ${XCB_XFIXES_LIBRARIES}
${XCB_DAMAGE_LIBRARIES} ${XCB_RENDER_LIBRARIES} ${XCB_RANDR_LIBRARIES}
${XCB_SHAPE_LIBRARIES} ${XCB_SHM_LIBRARIES} ${XCB_SYNC_LIBRARIES}
${XCB_IMAGE_LIBRARIES} ${XCB_RENDERUTIL_LIBRARIES} ${XCB_KEYSYMS_LIBRARIES}
${XCB_XTEST_LIBRARIES} ${XCB_RECORD_LIBRARIES})
${XCB_XTEST_LIBRARIES} ${XCB_RECORD_LIBRARIES}
)
list(REMOVE_DUPLICATES XCB_INCLUDE_DIR)
@ -124,5 +128,4 @@ IF (NOT WIN32)
XCB_XTEST_INCLUDE_DIR XCB_XTEST_LIBRARIES
XCB_RECORD_INCLUDE_DIR XCB_RECORD_LIBRARIES
)
ENDIF (NOT WIN32)