| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
Now it is possible to pass multiple URLs as a list that will be tried in
and foreach(). So it will try next URL if the previous failed.
Fixes #15749.
|
|
|
|
|
|
| |
The download/extract step uses the file name only internally so we can
just use a fallback default name if one cannot be extracted from the
URL.
|
|
|
|
|
|
|
| |
While at it, refactor logic to consolidate the filename extraction
and verification into a single match.
Inspired-by: Ruslan Baratov <ruslan_baratov@yahoo.com>
|
|
|
|
|
|
| |
GIT_VERSION_STRING is unset in _ep_write_gitupdate_script(), hence
git stash is not being called with the "--all" option, even if Git
is new enough to support this.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Move the content to a `ExternalProject-download.cmake.in` file and use
`configure_file` to generate the final script.
Retry logic was not working before because similar script trigger
FATAL_ERROR if 'file(DOWNLOAD ...)' exits with nonzero 'status_code'.
FATAL_ERROR makes the whole chain of commands stop and
'_ep_write_verifyfile_script' retry logic was not used in fact.
Default retry number set to 5 with pauses 0, 5, 5, 15, 60 seconds. Some
space left for future improvements if needed (90, 300, 1200=20min). Can
be controlled by user.
|
|
|
|
|
| |
Move the content to a `ExternalProject-verify.cmake.in` file and use
`configure_file` to generate the final script.
|
|
|
|
| |
Verify step for downloaded files will be performed in separate script.
|
|
|
|
| |
The logic to re-run the download script will be moved elsewhere.
|
|
|
|
|
| |
There is no retries for local files and retry logic is broken for downloads.
Will be implemented in '*-download.cmake' script.
|
|
|
|
| |
Use uppercase variables for future 'configure_file' command.
|
|
|
|
|
|
|
|
| |
The purpose of the `update` step is to run an update on each build
(subject to `UPDATE_DISCONNECTED`). This is done for version-controlled
source directories. We should do it for a custom `UPDATE_COMMAND` too.
In particular, when `UPDATE_DISCONNECTED` is used we expect the
`skip-update` step to exist.
|
| |
|
|
|
|
| |
Inspired-by: Ilya Kulakov <kulakov.ilya@gmail.com>
|
|
|
|
|
|
|
|
| |
Avoid generating incorrect code such as
set(CMAKE_TLS_VERIFY set(CMAKE_TLS_VERIFY 1))
when one of these variables is set in the calling project.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since commit 272779ce (ExternalProject: Allow TLS_VERIFY for git clones,
2016-04-01) we pass the `-c http.sslVerify=false` option to `git clone`
even if no explicit `TLS_VERIFY` option was set. This changes behavior
because we used to use the default Git behavior by default. Revise the
logic to preserve the old default behavior by passing the new option
only if `TLS_VERIFY` was explicitly passed as `OFF`.
While at it, also honor `CMAKE_TLS_VERIFY` if the explicit `TLS_VERIFY`
option is not given.
|
|
|
|
|
| |
Use the git config `http.sslVerify=false` to disable strict ssl for git
commands.
|
|\
| |
| |
| |
| | |
49e82c15 Fix spelling typos in comments and documentation (#16037)
|
| |
| |
| |
| |
| | |
The Debian package checker tool (lintian) detected several typos in
CMake.
|
|/
|
|
|
|
| |
Some projects only ship self-extracting installers rather than
compressed archives. Add a flag so that these files may be used in
ExternalProject.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since commit v3.5.0-rc1~32^2~1 (ExternalProject: Simplify `cmake
--build` configuration passing, 2016-01-19) we use the `$<CONFIG>`
generator expression to generate the `cmake --build . --config <config>`
value for the default BUILD_COMMAND instead of the CMAKE_CFG_INTDIR
placeholder value provided by multi-config generators. However, some
projects have been abusing the old implementation detail by setting
CMAKE_CFG_INTDIR themselves to get a specific configuration. Those
projects should be updated to set their own BUILD_COMMAND to get
non-default behavior. Meanwhile we can be compatible with their
existing releases by detecting when CMAKE_CFG_INTDIR is not a
generator-provided placeholder and using its value instead.
|
|
|
|
|
|
|
| |
In multi-config generators we must tell `ctest` what configuration to
test.
Reported-by: Taylor Braun-Jones <taylor@braun-jones.org>
|
|
|
|
|
|
| |
Check CMAKE_CONFIGURATION_TYPES instead of CMAKE_CFG_INTDIR in order
to recognize multi-config generators. Then use $<CONFIG> to pass
the configuration value.
|
|
|
|
|
|
|
|
| |
Add a `GIT_REMOTE_NAME` option to `ExternalProject_Add` to support
git clone --origin <name>
Default to `origin` if not specified.
|
|
|
|
|
|
|
|
| |
Unset CMAKE_MODULE_PATH before calling find_package(Git) to ensure we do
not get a project-provided FindGit module that may not provide the
GIT_VERSION_STRING that we need. We do not need to restore the value
explicitly because this occurs inside the _ep_add_download_command
function call scope.
|
|
|
|
|
|
| |
Refactoring in commit v3.4.0-rc1~77^2~1 (ExternalProject: Use
GIT_VERSION_STRING instead of custom method, 2015-09-17) forgot
to update the variable name used in an error message.
|
|
|
|
| |
The --all option for git-stash wasn't introduced until git version 1.7.6.
|
|
|
|
| |
GIT_VERSION_STRING is available in FindGit.cmake since CMake version 2.8.8
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
By default Mercurial command "clone" will implicitly call "update" with
the "default" branch after downloading the cloned repository. However
ExternalProject_Add() always generates a second "update" command after
cloning with a tag which is either specified or "tip" (equivalent to
"default" by default). Therefore ExternalProject will first clone then
update to default branch then update to another specified branch if
provided. This leads to potentially very long clone operation (in
particular when the repository default branch contain subrepos) which
can lead to transaction abort triggered by the server.
Simply use "hg clone -U" to avoid the implicit update during clone.
Our following call to "hg update" will take care of updating anyway.
|
|
|
|
| |
Exposed by CMP0054 warnings.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Added new USES_TERMINAL option to the ExternalProject_Add_Step
function. This option passes USES_TERMINAL to the underlying
add_custom_command call so that the Ninja console pool is used.
Also, corresponding new USES_TERMINAL_<step> options were added
to the ExternalProject_Add function.
Justification: if using Ninja with a CMake superbuild, it's often
desirable to limit the superbuild to ONE sub-Ninja process at a
time to avoid oversubscribing the CPU. Using the console pool also
makes it easy to monitor the progress of the sub-Ninja process.
Independent USES_TERMINAL_<step> arguments are passed to
ExternalProject_Add instead of one USES_TERMINAL argument that
controls everything. Users may wish to run some steps in parallel
but not others (e.g. parallelize configure but not build).
|
|
|
|
|
|
|
|
|
|
|
| |
Honor the GIT_SUBMODULES option added by commit v3.0.0-rc1~92^2
(ExternalProject: Add option GIT_SUBMODULES, 2014-01-09) during the
'git submodule init' step to avoid initalizing all modules since we
are only going to update the specified subset anyway. This will
be useful for project repositories that have many submodules
(e.g. https://github.com/boostorg/boost).
Reviewed-by: Daniele E. Domenichelli <daniele.domenichelli@iit.it>
|
| |
|
|
|
|
|
| |
Mention the SOURCE_DIR that we checked and found empty or missing
so that the user can see the full path to what we expected to find.
|
|
|
|
|
| |
Respect INTERFACE library property whitelist. Check that a target has
type "UTILITY" before querying other properties.
|
| |
|
|
|
|
|
|
| |
Use file(GENERATE) to write the logging wrapper scripts to evaluate
generator expressions. Use a per-config script names in case the
content varies by configuration.
|
|
|
|
|
|
| |
Use file(GENERATE) to write the initial cache file so that we can
evaluate generator expressions. Use a per-config initial cache file
name in case the content varies by configuration.
|
|
|
|
|
|
| |
The `binary_dir` variable is never set, so this is invalid. Instead, use
"." which all the other build commands use anyways. Also only set the
--config option if it is meaningful.
|
|
|
|
|
|
| |
This allows the developer to specify the byproducts relative to the
binary directory without the need to set the binary directory location
explicitly.
|
|
|
|
| |
ARGV# could be defined from a parent scope.
|
|
|
|
|
|
|
| |
Within an existing build tree, if the stamp for a step already exists
when one activates the ALWAYS option, we still want it to always build.
Remove the step stamp file during CMake configuration to ensure it does
not exist when the ALWAYS option is enabled.
|
|\
| |
| |
| |
| | |
a300d0ff ExternalProject: avoid CMP0054 warnings
|
| |
| |
| |
| | |
Found where ${command} is "make" which is a local variable.
|
|/
|
|
| |
message() already adds a newline.
|
|
|
|
|
|
|
|
|
|
|
| |
If this option is enabled, the test step is created with the
EXCLUDE_FROM_MAIN option, and if TEST_BEFORE_INSTALL is enabled, the
install step does not depend on the test step.
This means that the test step is never executed, unless the test target
is explicitly created by calling ExternalProject_Add_StepTarget, or by
passing it with the STEP_TARGETS option, or with the EP_STEP_TARGETS
directory property.
|
|
|
|
|
|
|
| |
The external project's build process may generate byproducts on which
other rules in the driving project's build later depend. Provide a way
for the driving project to specify what byproducts it expects to be made
available by the custom commands that drive the external project.
|
|\
| |
| |
| |
| |
| |
| |
| | |
3c497f11 Help: Add notes for topic 'ExternalProject_UPDATE_DISCONNECTED'
aba5cec6 ExternalProject: Add unit tests for UPDATE_DISCONNECTED
3f606fa7 ExternalProject: Add UPDATE_DISCONNECTED option
c0b749cf ExternalProject: Always add a command to a step
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
If UPDATE_DISCONNECTED is set, the update step is not executed
automatically when building the main target. The update step can still
be added as a step target and called manually. This is useful if you
want to allow to build the project when you are disconnected from the
network (you might still need the network for the download step).
This is disabled by default.
The directory property EP_UPDATE_DISCONNECTED can be used to change
the default value for all the external projects in the current
directory and its subdirectories.
|
| |
| |
| |
| |
| |
| |
| |
| | |
Some generators (i.e. Xcode) will not generate a file level target if
no command is set, and therefore the dependencies on this target will
be broken.
This patch sets an empty echo command that does nothing to avoid this
issue.
|
|\ \
| |/
|/|
| |
| | |
ee7405a6 ExternalProject: Restore logic to not download already-existing file
|