From 0e4ba1fdd1cce363bfa5e727ddd5f44e3cd1dff4 Mon Sep 17 00:00:00 2001 From: Koekto-code <97475827+Koekto-code@users.noreply.github.com> Date: Thu, 11 Aug 2022 22:10:16 +0300 Subject: [PATCH] Fix problems setting DirectX_LIBRARY DirectX_LIBRARY was always clearing, though DirectX_PREFIX_PATH was not changed. This is because I had some semicolons at begin of DirectX_PREFIX_PATH and the macro `clear_if_changed` discarded them. Now it saves all extra semicolons and check passes. --- cmake-modules/FindPkgMacros.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmake-modules/FindPkgMacros.cmake b/cmake-modules/FindPkgMacros.cmake index 074cce352..d3a6042a7 100644 --- a/cmake-modules/FindPkgMacros.cmake +++ b/cmake-modules/FindPkgMacros.cmake @@ -54,7 +54,7 @@ macro(clear_if_changed TESTVAR) set(${var} "NOTFOUND" CACHE STRING "x" FORCE) endforeach(var) endif () - set(${TESTVAR}_INT_CHECK ${${TESTVAR}} CACHE INTERNAL "x" FORCE) + set(${TESTVAR}_INT_CHECK "${${TESTVAR}}" CACHE INTERNAL "x" FORCE) endmacro(clear_if_changed) # Try to get some hints from pkg-config, if available