Skip to content

Commit

Permalink
ENH: improved support for offline build
Browse files Browse the repository at this point in the history
  • Loading branch information
TheChymera authored and hjmjohnson committed Oct 10, 2020
1 parent ddca18b commit 75149ce
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion CMake/ITKDownloadSetup.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ mark_as_advanced(ITK_FORBID_DOWNLOADS)

macro(itk_download_attempt_check _name)
if(ITK_FORBID_DOWNLOADS)
message(SEND_ERROR "Attempted to download ${_name} when ITK_FORBID_DOWNLOADS is ON")
message(WARNING "Attempted to download ${_name} when ITK_FORBID_DOWNLOADS is ON")
endif()
endmacro()

Expand Down
3 changes: 3 additions & 0 deletions CMake/ITKModuleRemote.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,9 @@ function(itk_fetch_module _name _description)
endif()

if(Module_${_name})
if(ITK_FORBID_DOWNLOADS)
return()
endif()
itk_download_attempt_check(Module_${_name})
find_package(Git)
if(NOT GIT_EXECUTABLE)
Expand Down

0 comments on commit 75149ce

Please sign in to comment.