From ef380f27d5d33548023d242e69ca0ba0a19bf940 Mon Sep 17 00:00:00 2001 From: Jeffrey Pfau Date: Wed, 8 Oct 2014 01:03:35 -0700 Subject: [PATCH] Fix outputing the right variable names in find_feature --- CMakeLists.txt | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index f307726e7..8a6b1c75f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -37,12 +37,13 @@ function(find_feature FEATURE_NAME FEATURE_REQUIRES) set(${FEATURE_NAME} OFF PARENT_SCOPE) return() endif() - set(${REQUIRE}_CFLAGS_OTHER ${${REQUIRE}_CFLAGS_OTHER} PARENT_SCOPE) - set(${REQUIRE}_FOUND ${${REQUIRE}_FOUND} PARENT_SCOPE) - set(${REQUIRE}_INCLUDE_DIRS ${${REQUIRE}_INCLUDE_DIRS} PARENT_SCOPE) - set(${REQUIRE}_LIBRARIES ${${REQUIRE}_LIBRARIES} PARENT_SCOPE) - set(${REQUIRE}_LIBRARY_DIRS ${${REQUIRE}_LIBRARY_DIRS} PARENT_SCOPE) - set(${REQUIRE}_LDFLAGS_OTHER ${${REQUIRE}_LDFLAGS_OTHER} PARENT_SCOPE) + string(TOUPPER ${REQUIRE} UREQUIRE) + set(${UREQUIRE}_CFLAGS_OTHER ${${REQUIRE}_CFLAGS_OTHER} PARENT_SCOPE) + set(${UREQUIRE}_FOUND ${${REQUIRE}_FOUND} PARENT_SCOPE) + set(${UREQUIRE}_INCLUDE_DIRS ${${REQUIRE}_INCLUDE_DIRS} PARENT_SCOPE) + set(${UREQUIRE}_LIBRARIES ${${REQUIRE}_LIBRARIES} PARENT_SCOPE) + set(${UREQUIRE}_LIBRARY_DIRS ${${REQUIRE}_LIBRARY_DIRS} PARENT_SCOPE) + set(${UREQUIRE}_LDFLAGS_OTHER ${${REQUIRE}_LDFLAGS_OTHER} PARENT_SCOPE) endforeach() endfunction()