diff options
author | Claudio Fantacci <claudio.fantacci@gmail.com> | 2019-04-02 07:43:34 (GMT) |
---|---|---|
committer | Claudio Fantacci <claudio.fantacci@gmail.com> | 2019-04-03 07:06:16 (GMT) |
commit | 14c7396fb940d04f2afd3e9a7230fa6d4fac8145 (patch) | |
tree | 885f279b2d6d622800ecb440ac383c8beb6dcdae /Modules/FindGLEW.cmake | |
parent | 56ae290284a7f6f7298bf7410a361aaecb7ebbe9 (diff) | |
download | CMake-14c7396fb940d04f2afd3e9a7230fa6d4fac8145.zip CMake-14c7396fb940d04f2afd3e9a7230fa6d4fac8145.tar.gz CMake-14c7396fb940d04f2afd3e9a7230fa6d4fac8145.tar.bz2 |
FindGLEW: fix CMAKE_FIND_LIBRARY_SUFFIXES
FindGLEW temporarily changes the content of CMAKE_FIND_LIBRARY_SUFFIXES
to look for static and dynamic GLEW library.
However, it wasn't storing and restoring the initial content of such
variable, causing possible issues in user project.
Diffstat (limited to 'Modules/FindGLEW.cmake')
-rw-r--r-- | Modules/FindGLEW.cmake | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Modules/FindGLEW.cmake b/Modules/FindGLEW.cmake index 34ee873..2e9a052 100644 --- a/Modules/FindGLEW.cmake +++ b/Modules/FindGLEW.cmake @@ -117,6 +117,8 @@ else() endif() +set(__GLEW_CURRENT_FIND_LIBRARY_SUFFIXES ${CMAKE_FIND_LIBRARY_SUFFIXES}) + __glew_set_find_library_suffix(SHARED) find_library(GLEW_SHARED_LIBRARY_RELEASE @@ -142,6 +144,9 @@ find_library(GLEW_STATIC_LIBRARY_DEBUG PATH_SUFFIXES lib lib64 PATHS ENV GLEW_ROOT) +set(CMAKE_FIND_LIBRARY_SUFFIXES ${__GLEW_CURRENT_FIND_LIBRARY_SUFFIXES}) +unset(__GLEW_CURRENT_FIND_LIBRARY_SUFFIXES) + include(${CMAKE_CURRENT_LIST_DIR}/SelectLibraryConfigurations.cmake) select_library_configurations(GLEW_SHARED) |