diff options
author | Craig Scott <craig.scott@crascit.com> | 2018-09-07 23:40:15 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2018-09-07 23:40:24 (GMT) |
commit | 49cb2a504d1e00e51774a23bf1b91c982fa69e5d (patch) | |
tree | fa0f8c47b6389bcb228e87047a3d5a984ac4eb55 /Modules | |
parent | 917d98699e8dd13de89e2993b0b630cf64f17706 (diff) | |
parent | df1ddeec128d68cc636f2dde6c2acd87af5658b6 (diff) | |
download | CMake-49cb2a504d1e00e51774a23bf1b91c982fa69e5d.zip CMake-49cb2a504d1e00e51774a23bf1b91c982fa69e5d.tar.gz CMake-49cb2a504d1e00e51774a23bf1b91c982fa69e5d.tar.bz2 |
Merge topic 'ExternalProject-check-explicit-include'
df1ddeec12 ExternalProject: Report error if local variables are not defined
Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Brad King <brad.king@kitware.com>
Merge-request: !2281
Diffstat (limited to 'Modules')
-rw-r--r-- | Modules/ExternalProject.cmake | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Modules/ExternalProject.cmake b/Modules/ExternalProject.cmake index 0c5b33f..f987d2d 100644 --- a/Modules/ExternalProject.cmake +++ b/Modules/ExternalProject.cmake @@ -934,6 +934,11 @@ function(_ep_parse_arguments f name ns args) # We loop through ARGN and consider the namespace starting with an # upper-case letter followed by at least two more upper-case letters, # numbers or underscores to be keywords. + + if(NOT DEFINED _ExternalProject_SELF) + message(FATAL_ERROR "error: ExternalProject module must be explicitly included before using ${f} function") + endif() + set(key) foreach(arg IN LISTS args) |