summaryrefslogtreecommitdiff
path: root/cmake
diff options
context:
space:
mode:
authorMike Stroyan <stroyan@google.com>2016-09-20 09:05:28 -0600
committerMike Stroyan <stroyan@google.com>2016-09-26 12:58:15 -0600
commit95d461ded5efd535389bf641fbfd65449a8d38b2 (patch)
tree1d83b778da2d4995d68590b0a8a239208fd51a9b /cmake
parentc3c3a5dac2ac4b77018c48129cbe4306bdd0edd4 (diff)
build: UNSET cache variables for FIND_IMAGEMAGICK_API
The way that the ImageMagick component search calls find_path multiple times with the same variable but different names does not expect old cache values in the variable.
Diffstat (limited to 'cmake')
-rw-r--r--cmake/FindImageMagick.cmake4
1 files changed, 4 insertions, 0 deletions
diff --git a/cmake/FindImageMagick.cmake b/cmake/FindImageMagick.cmake
index 163e5ae8..4db4773b 100644
--- a/cmake/FindImageMagick.cmake
+++ b/cmake/FindImageMagick.cmake
@@ -231,6 +231,8 @@ FOREACH(component ${ImageMagick_FIND_COMPONENTS}
)
IF(component STREQUAL "Magick++")
+ # unset cached variable that assumes header parameter never changes
+ UNSET(ImageMagick_MagickWand_INCLUDE_DIR CACHE)
# Try top folder first
FIND_IMAGEMAGICK_API(Magick++ <NONE> Magick++.h
@@ -252,6 +254,8 @@ FOREACH(component ${ImageMagick_FIND_COMPONENTS}
ENDIF()
ELSEIF(component STREQUAL "MagickWand")
+ # unset cached variable that assumes header parameter never changes
+ UNSET(ImageMagick_MagickWand_INCLUDE_DIR CACHE)
# Try top folder first
FIND_IMAGEMAGICK_API(MagickWand <NONE> MagickWand.h