Skip to content

Commit 561793e

Browse files
authored
Merge pull request #25214 from gottesmm/pr-ca4f1e17cef6e16b8230c7664a43cddd822909fd
[build-script] Add support for passing --reconfigure to arbitrary presets and remove --reconfigure from stdlib standalone presets
2 parents 1c0d0d3 + af77f11 commit 561793e

File tree

2 files changed

+13
-8
lines changed

2 files changed

+13
-8
lines changed

utils/build-presets.ini

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2057,7 +2057,6 @@ build-subdir=stdlib_RA_standalone
20572057
release
20582058
assertions
20592059

2060-
reconfigure
20612060
verbose-build
20622061

20632062
[preset: stdlib_RA_standalone,build,test]
@@ -2074,7 +2073,6 @@ build-subdir=stdlib_RDA_standalone
20742073
release-debuginfo
20752074
assertions
20762075

2077-
reconfigure
20782076
verbose-build
20792077

20802078
[preset: stdlib_RDA_standalone,build,test]
@@ -2091,7 +2089,6 @@ build-subdir=stdlib_DA_standalone
20912089
debug
20922090
assertions
20932091

2094-
reconfigure
20952092
verbose-build
20962093

20972094
[preset: stdlib_DA_standalone,build,test]

utils/build-script

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -887,6 +887,11 @@ def main_preset():
887887
"various values used to build in this configuration",
888888
action="store_true",
889889
default=False)
890+
parser.add_argument(
891+
"--reconfigure",
892+
help="Reconfigure all projects as we build",
893+
action="store_true",
894+
default=False)
890895
args = parser.parse_args()
891896
if len(args.preset_file_names) == 0:
892897
args.preset_file_names = [
@@ -954,14 +959,17 @@ def main_preset():
954959
build_script_args += ["--cmake-c-launcher", args.cmake_c_launcher]
955960
if args.cmake_cxx_launcher:
956961
build_script_args += ["--cmake-cxx-launcher", args.cmake_cxx_launcher]
957-
958962
printable_command = shell.quote_command(build_script_args)
959963
if args.expand_invocation:
960964
print(printable_command)
961-
else:
962-
diagnostics.note('using preset "{}", which expands to \n\n{}\n'.format(
963-
args.preset, printable_command))
964-
shell.call_without_sleeping(build_script_args)
965+
return 0
966+
967+
if args.reconfigure:
968+
build_script_args += ["--reconfigure"]
969+
970+
diagnostics.note('using preset "{}", which expands to \n\n{}\n'.format(
971+
args.preset, printable_command))
972+
shell.call_without_sleeping(build_script_args)
965973
return 0
966974

967975

0 commit comments

Comments
 (0)