diff options
author | fuzzard <fuzzard@kodi.tv> | 2023-09-16 13:14:21 +1000 |
---|---|---|
committer | fuzzard <fuzzard@kodi.tv> | 2023-09-16 16:43:18 +1000 |
commit | 2481f3fb58d8ed4342bc7779b5eba7984f04c273 (patch) | |
tree | e47eb608f69da2c134514d43eb25388554b27494 /cmake/modules/FindFmt.cmake | |
parent | 29755df826b063e2d51343dd9d0a1a62afa14394 (diff) |
[cmake] add support for ${CORE_PLATFORM_NAME_LC}_SEARCH_CONFIG in several find modules
Update HINTS paths as well to accommodate restricted search paths with the use of
${CORE_PLATFORM_NAME_LC}_SEARCH_CONFIG
Diffstat (limited to 'cmake/modules/FindFmt.cmake')
-rw-r--r-- | cmake/modules/FindFmt.cmake | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/cmake/modules/FindFmt.cmake b/cmake/modules/FindFmt.cmake index 223445c595..a403a03ce5 100644 --- a/cmake/modules/FindFmt.cmake +++ b/cmake/modules/FindFmt.cmake @@ -24,7 +24,9 @@ if(NOT TARGET fmt::fmt OR Fmt_FIND_REQUIRED) SETUP_BUILD_VARS() # Check for existing FMT. If version >= FMT-VERSION file version, dont build - find_package(FMT CONFIG QUIET) + find_package(FMT CONFIG QUIET + HINTS ${DEPENDS_PATH}/lib + ${${CORE_PLATFORM_NAME_LC}_SEARCH_CONFIG}) # Build if ENABLE_INTERNAL_FMT, or if required version in find_package call is greater # than already found FMT_VERSION from a previous find_package call @@ -83,12 +85,18 @@ if(NOT TARGET fmt::fmt OR Fmt_FIND_REQUIRED) endif() find_path(FMT_INCLUDE_DIR NAMES fmt/format.h - PATHS ${PC_FMT_INCLUDEDIR}) + HINTS ${DEPENDS_PATH}/include ${PC_FMT_INCLUDEDIR} + ${${CORE_PLATFORM_LC}_SEARCH_CONFIG} + NO_CACHE) find_library(FMT_LIBRARY_RELEASE NAMES fmt - PATHS ${PC_FMT_LIBDIR}) + HINTS ${DEPENDS_PATH}/lib ${PC_FMT_LIBDIR} + ${${CORE_PLATFORM_LC}_SEARCH_CONFIG} + NO_CACHE) find_library(FMT_LIBRARY_DEBUG NAMES fmtd - PATHS ${PC_FMT_LIBDIR}) + HINTS ${DEPENDS_PATH}/lib ${PC_FMT_LIBDIR} + ${${CORE_PLATFORM_LC}_SEARCH_CONFIG} + NO_CACHE) endif() add_library(fmt::fmt UNKNOWN IMPORTED) |