[cmake] Locate PkgConfig module with find_package() instead of include(FindPkgConfig)

This is the contemporary way of including find modules and including the
find module this way avoids cmake errors in conjunction with
find_package_handle_standard_args().

Signed-off-by: Kimon Hoffmann <Kimon.Hoffmann@lawo.com>
This commit is contained in:
Kimon Hoffmann
2023-08-09 12:08:16 +02:00
committed by akallabeth
parent 988dcd49a3
commit 8ec4d20616
13 changed files with 7 additions and 13 deletions

View File

@@ -4,7 +4,7 @@
# PCSC_INCLUDE_DIRS - pcsc include directories
# PCSC_LIBRARIES - libraries needed for linking
include(FindPkgConfig)
find_package(PkgConfig)
if(PKG_CONFIG_FOUND)
pkg_check_modules(PC_PCSC QUIET libpcsclite)