oasisprotocol / oasisprotocol/oasis-core
Cargo recompilation in newer rust nightlies
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 369
- Forks
- 151
- Avg merge
- 1d 3h
- Merged PRs (30d)
- 6
Description
It appears that if using a recent Rust nightly, Cargo will recompile runtimes every time, even if there are no changes to any of the files whatsoever.
I think the newest nightly that works without recompilation is nightly-2019-08-26.
The recompilation happens in build-runtimes step, where we build for the default and x86_64-fortanix-unknown-sgx targets: https://github.com/oasislabs/oasis-core/blob/master/Makefile#L25-L26 . A currently known workaround is to explicitly specify distinct target directories via the --target-dir flag for the runtimes builds. However this looks like an upstream bug so we should try to come up with a minimal example and file an issue upstream.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the build-runtimes step in Makefile lines 25-26, which builds the default and x86_64-fortanix-unknown-sgx targets. Reproduce the repeated recompilation with a recent Rust nightly and compare it with nightly-2019-08-26, including the --target-dir workaround. Done means reducing the behavior to a minimal example and filing the upstream issue.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100