diff options
| author | Victor Romero <romerosanchezv@gmail.com> | 2019-08-28 11:47:17 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-08-28 11:47:17 -0700 |
| commit | 65d4bc146bf7c1c21989b680497b1f6f9a09c967 (patch) | |
| tree | 31e564677ff7ae3f065c3bd3d7448ba959edb524 /scripts/cmake/execute_process.cmake | |
| parent | fc135e20eae801bcd6a20ddb8fba677f61dba5a5 (diff) | |
| download | vcpkg-65d4bc146bf7c1c21989b680497b1f6f9a09c967.tar.gz vcpkg-65d4bc146bf7c1c21989b680497b1f6f9a09c967.zip | |
[vcpkg install] Enable Download Mode (#7797)
* [portfile functions] Override execute_process() to accept ALLOW_IN_DOWNLOAD_MODE option
* [vcpkg install] Set VCPKG_DOWNLOAD_MODE when using --only-downloads option
* [vcpkg_find_acquire_program] Allow in Download Mode
* Don't stop when build fails for a package
* Download sources for all packages in dependency graph
* Improve output messages
* Enable acquiring MSYS packages in download mode
* Documentation
* Update documentation
* execute_process() always fails on Download Mode
* Regenerate docs and fix formatting
* Run clang-format
* Use _execute_process on vcpkg_from_<source> helpers
Diffstat (limited to 'scripts/cmake/execute_process.cmake')
| -rw-r--r-- | scripts/cmake/execute_process.cmake | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/scripts/cmake/execute_process.cmake b/scripts/cmake/execute_process.cmake new file mode 100644 index 000000000..90198e337 --- /dev/null +++ b/scripts/cmake/execute_process.cmake @@ -0,0 +1,19 @@ +## # execute_process
+##
+## Intercepts all calls to execute_process() inside portfiles and fails when Download Mode
+## is enabled.
+##
+## In order to execute a process in Download Mode call `_execute_process()` instead.
+##
+if (NOT DEFINED OVERRIDEN_EXECUTE_PROCESS)
+set(OVERRIDEN_EXECUTE_PROCESS ON)
+
+function(execute_process)
+ message(FATAL_ERROR
+[[
+ This command cannot be executed in Download Mode.
+ Halting portfile execution.
+]])
+endfunction()
+
+endif()
\ No newline at end of file |
