Skip to content

Commit af10f27

Browse files
authored
Rollup merge of rust-lang#137493 - nabijaczleweli:python3, r=Kobzol
configure.py: don't instruct user to run nonexistent program ```shell-session $ ./configure configure: processing command line configure: configure: build.configure-args := [] configure: profile := dist configure: configure: writing `config.toml` in current directory configure: configure: run `python /mnt/filling/store/nabijaczleweli/code/rust/x.py --help` ``` This is naturally not valid since I don't have a "python" executable (and this will hopefully become more and more true as Python 2 dies out). ./configure knows this since it does `try python3 "$``@"`,`` then `python2.7` &c. After, this now says ``` configure: run `python3 /mnt/filling/store/nabijaczleweli/code/rust/x.py --help` ``` which is possible, and corresponds to the interpreter actually running.
2 parents 5094010 + 097d642 commit af10f27

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/bootstrap/configure.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -776,6 +776,6 @@ def quit_if_file_exists(file):
776776
f.write(contents)
777777

778778
p("")
779-
p("run `python {}/x.py --help`".format(rust_dir))
779+
p("run `{} {}/x.py --help`".format(os.path.basename(sys.executable), rust_dir))
780780
if "GITHUB_ACTIONS" in os.environ:
781781
print("::endgroup::")

0 commit comments

Comments
 (0)