Skip to content
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

Switch to stable rust and make rust debug build usable #2207

Merged
merged 7 commits into from Apr 5, 2023

Conversation

librelois
Copy link
Collaborator

What does it do?

This pull request brings support for compiling moonbeam with stable Rust, this required to cherry-pick paritytech/substrate#13580 on our substrate branch moonbeam-polkadot-v0.9.38.

This PR also allows to use the moonbeam binary in debug build (much faster compilation), to achieve this we use the same trick as parity on these substrate and polkadot repos: force the optimized compilation only for the few low-level crates that need it.

What important points reviewers should know?

Is there something left for follow-up PRs?

What alternative implementations were considered?

Are there relevant PRs or issues in other repositories (Substrate, Polkadot, Frontier, Cumulus)?

What value does it bring to the blockchain users?

@librelois librelois added B7-runtimenoteworthy Changes should be noted in any runtime-upgrade release notes not-breaking Does not need to be mentioned in breaking changes D3-trivial PR contains trivial changes in a runtime directory that do not require an audit labels Apr 4, 2023
@tmpolaczyk
Copy link
Contributor

I believe cargo-expand requires nightly rust to work. I found this workaround, not sure if it is a good idea though:

dtolnay/cargo-expand#113 (comment)

@librelois
Copy link
Collaborator Author

librelois commented Apr 5, 2023

Thank you @tmpolaczyk for the suggestion but we can't inject an environment variable on cargo expand run, it will require a contribution to the macrotest crate to allow to pass env vars (they only allow cli args).

@librelois librelois marked this pull request as ready for review April 5, 2023 10:04
@librelois librelois merged commit 66023c3 into master Apr 5, 2023
18 checks passed
@librelois librelois deleted the elois-stable-rust branch April 5, 2023 10:23
imstar15 pushed a commit to OAK-Foundation/moonbeam that referenced this pull request May 16, 2023
…dation#2207)

* make moonnbeam compiling with stable rust

* make rust dev mode usable

* toml-sort

* macro tests: update compile error outputs

* macro tests: update expanded outputs

* rebuild cargo-expand with stable rust

* cargo expand is not supported in stable rust
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
B7-runtimenoteworthy Changes should be noted in any runtime-upgrade release notes D3-trivial PR contains trivial changes in a runtime directory that do not require an audit not-breaking Does not need to be mentioned in breaking changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants