Warning, /multimedia/kaffeine/cmake/modules/FindLibdvbv5.cmake is written in an unsupported language. File is not indexed.
0001 # - Try to find the libdvbv5 library 0002 # Once done this will define 0003 # 0004 # Libdvbv5_FOUND - system has libdvbv5 0005 # Libdvbv5_INCLUDE_DIRS - the libdvbv5 include directories 0006 # Libdvbv5_LIBRARIES - Link these to use libdvbv5 0007 0008 # Copyright (c) 2016, Pino Toscano <pino@kde.org> 0009 0010 # Redistribution and use in source and binary forms, with or without 0011 # modification, are permitted provided that the following conditions 0012 # are met: 0013 # 0014 # 1. Redistributions of source code must retain the copyright 0015 # notice, this list of conditions and the following disclaimer. 0016 # 2. Redistributions in binary form must reproduce the copyright 0017 # notice, this list of conditions and the following disclaimer in the 0018 # documentation and/or other materials provided with the distribution. 0019 # 3. The name of the author may not be used to endorse or promote products 0020 # derived from this software without specific prior written permission. 0021 # 0022 # THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR 0023 # IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 0024 # OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 0025 # IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, 0026 # INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 0027 # NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 0028 # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 0029 # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 0030 # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 0031 # THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 0032 0033 find_package(PkgConfig) 0034 0035 if (PKG_CONFIG_FOUND) 0036 if (Libdvbv5_FIND_VERSION) 0037 set(version_string ">=${Libdvbv5_FIND_VERSION}") 0038 endif() 0039 pkg_check_modules(PC_LIBDVBV5 libdvbv5${version_string}) 0040 unset(version_string) 0041 else() 0042 # assume it was found 0043 set(PC_LIBDVBV5_FOUND TRUE) 0044 endif() 0045 0046 if (PC_LIBDVBV5_FOUND) 0047 find_path(Libdvbv5_INCLUDE_DIRS libdvbv5/dvb-file.h 0048 HINTS ${PC_LIBDVBV5_INCLUDE_DIRS} 0049 ) 0050 0051 find_library(Libdvbv5_LIBRARIES NAMES dvbv5 0052 HINTS ${PC_LIBDVBV5_LIBRARY_DIRS} 0053 ) 0054 0055 set(Libdvbv5_VERSION "${PC_LIBDVBV5_VERSION}") 0056 endif() 0057 0058 include(FindPackageHandleStandardArgs) 0059 find_package_handle_standard_args(Libdvbv5 0060 REQUIRED_VARS Libdvbv5_LIBRARIES Libdvbv5_INCLUDE_DIRS 0061 VERSION_VAR Libdvbv5_VERSION 0062 ) 0063 0064 mark_as_advanced(Libdvbv5_INCLUDE_DIRS Libdvbv5_LIBRARIES)