-
Notifications
You must be signed in to change notification settings - Fork 12.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
rustbuild: Rewrite the configure script in Python #44107
Conversation
(rust_highfive has picked a reviewer for you, use r? to override) |
I believe this will also close #43295, #42255, and #38058. Could you verify and update the description? I've looked through the code and everything looks good to me. If you'd like a rubber stamp approval, feel free to r=me -- I'm not familiar with Python though so can't really review code quality there. |
configure
Outdated
|
||
p("processing command line") | ||
i = 1 | ||
while i < len(sys.argv): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's possible, yes, but I'm pretty unfamiliar with both (I barely know python) and would prefer to focus on compatibility for now
edbd7c3
to
1ffe095
Compare
Thanks for reviewing @Mark-Simulacrum! I think I'll hold off on merging this until after beta branches, no need to land a rewrite that has a high likelihood for regressions just before! |
ecc3451
to
1db05ac
Compare
@bors: r=Mark-Simulacrum |
📌 Commit 1db05ac has been approved by |
⌛ Testing commit 1db05acbfa2bbe241323b3c7e98ed2407a921b60 with merge a10b0ddf528dd8e29853347fa20ca8c016d573d0... |
💔 Test failed - status-travis |
1db05ac
to
e206216
Compare
@bors: r=Mark-Simulacrum |
📌 Commit e206216 has been approved by |
⌛ Testing commit e2062165d58211ff81c10bc9332e14eb68c6970b with merge f52c915024bac5dbab77ecb715c445cfe7a40dca... |
💔 Test failed - status-travis |
Probably a matter of copying the config.toml.example into dist.
|
This commit rewrites our ancient `./configure` script from shell into Python. The impetus for this change is to remove `config.mk` which is just a vestige of the old makefile build system at this point. Instead all configuration is now solely done through `config.toml`. The python script allows us to more flexibly program (aka we can use loops easily) and create a `config.toml` which is based off `config.toml.example`. This way we can preserve comments and munge various values as we see fit. It is intended that the configure script here is a drop-in replacement for the previous configure script, no functional change is intended. Also note that the rationale for this is also because our build system requires Python, so having a python script a bit earlier shouldn't cause too many problems. Closes rust-lang#40730
e206216
to
a9b0a7b
Compare
@bors: r=Mark-Simulacrum |
📌 Commit a9b0a7b has been approved by |
…crum rustbuild: Rewrite the configure script in Python This commit rewrites our ancient `./configure` script from shell into Python. The impetus for this change is to remove `config.mk` which is just a vestige of the old makefile build system at this point. Instead all configuration is now solely done through `config.toml`. The python script allows us to more flexibly program (aka we can use loops easily) and create a `config.toml` which is based off `config.toml.example`. This way we can preserve comments and munge various values as we see fit. It is intended that the configure script here is a drop-in replacement for the previous configure script, no functional change is intended. Also note that the rationale for this is also because our build system requires Python, so having a python script a bit earlier shouldn't cause too many problems. Closes #40730 Closes #43295 Closes #42255 Closes #38058 Closes #32176
💔 Test failed - status-travis |
…crum rustbuild: Rewrite the configure script in Python This commit rewrites our ancient `./configure` script from shell into Python. The impetus for this change is to remove `config.mk` which is just a vestige of the old makefile build system at this point. Instead all configuration is now solely done through `config.toml`. The python script allows us to more flexibly program (aka we can use loops easily) and create a `config.toml` which is based off `config.toml.example`. This way we can preserve comments and munge various values as we see fit. It is intended that the configure script here is a drop-in replacement for the previous configure script, no functional change is intended. Also note that the rationale for this is also because our build system requires Python, so having a python script a bit earlier shouldn't cause too many problems. Closes #40730 Closes #43295 Closes #42255 Closes #38058 Closes #32176
☀️ Test successful - status-appveyor, status-travis |
This commit rewrites our ancient
./configure
script from shell into Python.The impetus for this change is to remove
config.mk
which is just a vestige ofthe old makefile build system at this point. Instead all configuration is now
solely done through
config.toml
.The python script allows us to more flexibly program (aka we can use loops
easily) and create a
config.toml
which is based offconfig.toml.example
.This way we can preserve comments and munge various values as we see fit.
It is intended that the configure script here is a drop-in replacement for the
previous configure script, no functional change is intended. Also note that the
rationale for this is also because our build system requires Python, so having a
python script a bit earlier shouldn't cause too many problems.
Closes #40730
Closes #43295
Closes #42255
Closes #38058
Closes #32176