mirror of
https://bitbucket.org/smil3y/kdelibs.git
synced 2025-02-24 10:52:49 +00:00

it was causing overlinkg due to incorrect dependency additions added by the module because resolv library is used privately. in fact, it uses zlib and udev too but only privately and none of their include directories are needed to use libpci. since the rewrite makes use of pkg-config as primary lookup method any future changes to that behaviour will be handled correctly without overlinking. Signed-off-by: Ivailo Monev <xakepa10@laimg.moc>
43 lines
1 KiB
CMake
43 lines
1 KiB
CMake
# - 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>
|
|
#
|
|
# Redistribution and use is allowed according to the terms of the BSD license.
|
|
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
|
|
|
|
if(NOT WIN32)
|
|
include(FindPkgConfig)
|
|
pkg_check_modules(PC_MPV QUIET mpv)
|
|
|
|
set(MPV_INCLUDES ${PC_MPV_INCLUDE_DIRS})
|
|
set(MPV_LIBRARIES ${PC_MPV_LIBRARIES})
|
|
endif()
|
|
|
|
set(MPV_VERSION ${PC_MPV_VERSION})
|
|
|
|
if(NOT MPV_INCLUDES OR NOT MPV_LIBRARIES)
|
|
find_path(MPV_INCLUDES
|
|
NAMES client.h
|
|
PATH_SUFFIXES mpv
|
|
HINTS $ENV{MPVDIR}/include
|
|
)
|
|
|
|
find_library(MPV_LIBRARIES
|
|
NAMES mpv
|
|
HINTS $ENV{MPVDIR}/lib
|
|
)
|
|
endif()
|
|
|
|
include(FindPackageHandleStandardArgs)
|
|
find_package_handle_standard_args(MPV
|
|
VERSION_VAR MPV_VERSION
|
|
REQUIRED_VARS MPV_LIBRARIES MPV_INCLUDES
|
|
)
|
|
|
|
mark_as_advanced(MPV_INCLUDES MPV_LIBRARIES)
|