Commit Graph

14 Commits

Author SHA1 Message Date
Brad King
1bdaad7573 ExternalProject: Optionally integrate 'make' job server with INSTALL_COMMAND
Add an `INSTALL_JOB_SERVER_AWARE` option to `ExternalProject_Add`.
When using an explicit `INSTALL_COMMAND`, the generated commands
won't use `$(MAKE)` thus failing to connect to the outer make's
job server.  Add an option enable explicit job server integration.

This is the install step's equivalent to the build step's
`BUILD_JOB_SERVER_AWARE` option added by commit bc43398e72
(ExternalProject: Enable Make Job Server with Explicit Build Command,
2023-08-09, v3.28.0-rc1~217^2).  It is useful when the external
project's installation is driven by its build system.  Note that with
Makefile generators, our default install command does use `$(MAKE)` to
connect to the outer make's job server.

Issue: #26398
2024-11-19 10:22:24 -05:00
Craig Scott
012d116260 Merge topic 'cmp0168-populate-nondeclare-regression'
cbb727ca6b FetchContent: Don't update verify script timestamp if it doesn't change
795e7b44f2 Help: file(CONFIGURE) only updates output file timestamp if it changes

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9799
2024-09-08 18:32:40 -04:00
Craig Scott
cbb727ca6b FetchContent: Don't update verify script timestamp if it doesn't change
Fixes: #26255
2024-09-06 15:53:48 +10:00
Craig Scott
31609421f2 Merge topic 'fetchcontent-updates-disconnected'
5df592ce31 FetchContent: Ensure can_fetch_default is set early enough
c233c51cb9 ExternalProject: Fix bad indenting for uses_terminal

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Acked-by: Silver Zachara <silver.zachara@gmail.com>
Merge-request: !9685
2024-07-27 18:28:19 -04:00
Craig Scott
5df592ce31 FetchContent: Ensure can_fetch_default is set early enough
The can_fetch_default variable needs to be set before the call to
_ep_write_gitupdate_script(). Move it to before that call and always
set the variable, even if arg_SCRIPT_FILE is not set. This makes the
generated git update script file easier to follow if someone tries to
follow what it is doing or wants to investigate problems and run it
manually.

Fixes: #26164
2024-07-26 11:23:58 +10:00
Craig Scott
c233c51cb9 ExternalProject: Fix bad indenting for uses_terminal 2024-07-26 10:58:19 +10:00
Brad King
777d5d6a81 Merge topic 'ep-svn-user-pass'
7e80415e79 ExternalProject: Reduce number of local variables for svn logic
e16f65be15 ExternalProject: Don't add SVN auth args if not set

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !9678
2024-07-23 09:53:28 -04:00
Craig Scott
cd379332c3 ExternalProject: Don't rely on *_disconnected vars being unset by caller 2024-07-20 12:30:50 +10:00
Craig Scott
7e80415e79 ExternalProject: Reduce number of local variables for svn logic
We still keep the svn_trust_cert and uses_terminal variables because they
improve the readability of if() conditions.
2024-07-20 12:19:17 +10:00
Craig Scott
e16f65be15 ExternalProject: Don't add SVN auth args if not set
In 462e583267 (ExternalProject: Switch download, update and patch to
use _EP_ vars, 2024-05-13), the svn_username and svn_password variables
were only updated appropriately in the svn download implementation, but
not in the svn update implementation. This was easily missed in part
because the old implementation was relying on behavior that differed
from the documentation for get_property(), and the new implementation
tried to keep the intermediate variables from the old implementation but
missed this subtle aspect.

Issue: #26152
Fixes: #26148
2024-07-20 11:58:33 +10:00
Craig Scott
a02eec4a9f FetchContent,ExternalProject: Fix extra semicolons in step commands
The extra semicolons weren't ultimately causing any errors when
running the step commands, but they shouldn't be there.
2024-06-07 16:58:08 +10:00
Craig Scott
b2496bf14c FetchContent: Populate directly without a sub-build
Fixes: #21703
2024-05-17 14:23:39 +10:00
Craig Scott
173daad58d ExternalProject: Move more internal commands out of main file
The commands moved to shared_internal_commands.cmake
will soon be used directly by FetchContent, which cannot
always include the full ExternalProject.cmake file (e.g. it may
be used in CMake script mode).

Issue: #21703
2024-05-13 20:24:47 +10:00
Chris Wright
550f63447d ExternalProject/FetchContent: Support relative remote URLs
Teach `ExternalProject_Add` and `FetchContent_Declare` to resolve
relative remote URLs provided via `GIT_REPOSITORY`.  Add policy
CMP0150 to maintain compatibility.

Fixes: #24211
Co-Authored-By: Craig Scott <craig.scott@crascit.com>
2023-04-26 16:30:36 +08:00