mirror of
https://github.com/FEX-Emu/FEX.git
synced 2026-10-06 22:00:16 +02:00
See https://github.com/FEX-Emu/FEX/pull/5172#pullrequestreview-3626560058. Signed-off-by: crueter <crueter@eden-emu.dev>
19 lines
504 B
CMake
19 lines
504 B
CMake
# SPDX-License-Identifier: MIT
|
|
|
|
include(FindPackageHandleStandardArgs)
|
|
|
|
find_package(PkgConfig QUIET)
|
|
pkg_search_module(xxhash QUIET IMPORTED_TARGET xxhash libxxhash)
|
|
find_package_handle_standard_args(xxhash
|
|
REQUIRED_VARS xxhash_LINK_LIBRARIES
|
|
VERSION_VAR xxhash_VERSION
|
|
)
|
|
|
|
if (xxhash_FOUND AND NOT TARGET xxHash::xxhash)
|
|
if (TARGET PkgConfig::xxhash)
|
|
add_library(xxHash::xxhash ALIAS PkgConfig::xxhash)
|
|
else()
|
|
add_library(xxHash::xxhash ALIAS xxhash)
|
|
endif()
|
|
endif()
|