From fb3f115692db84f5f427755d9cf02cc14e9262fa Mon Sep 17 00:00:00 2001 From: Robert Adam Date: Fri, 7 Apr 2023 12:42:04 +0200 Subject: [PATCH] BUILD(cmake): Fix incorrect usage of pkg_search_module The incorrect use of this function caused calls to get_pkgconf_variable to fail. Fixes #6038 --- cmake/pkg-utils.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmake/pkg-utils.cmake b/cmake/pkg-utils.cmake index b5e0de74a..bcf7f6ab9 100644 --- a/cmake/pkg-utils.cmake +++ b/cmake/pkg-utils.cmake @@ -252,8 +252,8 @@ function(get_pkgconf_variable) message(FATAL_ERROR "get_pkgconf_variable: pkg-config was not found - can't use it to fetch variables") endif() - pkg_search_module("${GET_PKGCONF_VAR_MODULE}" QUIET) - if(NOT ${GET_PKGCONF_VAR_MODULE}_FOUND) + pkg_search_module("PKGCONF_MODULE" "${GET_PKGCONF_VAR_MODULE}" QUIET) + if(NOT PKGCONF_MODULE_FOUND) if(GET_PKGCONF_VAR_DEBUG) message(STATUS "Unable to find module \"${GET_PKGCONF_VAR_MODULE}\" via pkg-conf") set(VAR_VALUE "NOTFOUND")