summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Modules/ExternalProject.cmake5
1 files changed, 3 insertions, 2 deletions
diff --git a/Modules/ExternalProject.cmake b/Modules/ExternalProject.cmake
index bbeeeed..e3bdc6d 100644
--- a/Modules/ExternalProject.cmake
+++ b/Modules/ExternalProject.cmake
@@ -1184,10 +1184,11 @@ endfunction()
function(ExternalProject_Get_Property name)
foreach(var ${ARGN})
string(TOUPPER "${var}" VAR)
- get_property(${var} TARGET ${name} PROPERTY _EP_${VAR})
- if(NOT ${var})
+ get_property(is_set TARGET ${name} PROPERTY _EP_${VAR} SET)
+ if(NOT is_set)
message(FATAL_ERROR "External project \"${name}\" has no ${var}")
endif()
+ get_property(${var} TARGET ${name} PROPERTY _EP_${VAR})
set(${var} "${${var}}" PARENT_SCOPE)
endforeach()
endfunction()