Closed jasonm closed 2 years ago
Hi @eugeneia and @vipyne - thanks for what appears to be a super useful project! I'm very new to Rust programming and am not sure how to debug the build error. Could you point me in the right direction? Thanks!
Hi @jasonm , thanks for taking a look. What is the output of $ rustc -V
and $ rustup -V
?
Hi @vipyne thanks for your message! I ended up opening https://github.com/daily-co/synthetic-network/pull/3 and included my notes below.
rustc
and rustup
The cargo build
command is executing as part of building a docker image per the Makefile
/Dockerfile
in this repo, so here's the version of rustc
and rustup
from the intermediate docker image layer immediately prior to the failing cargo build
command:
~/dev/synthetic-network $ docker run -it --rm 04ca521c91d6 /bin/bash
root@4cb8abbf11ca:/opt/lib/rush# rustc -V
rustc 1.60.0-nightly (5e57faa78 2022-01-19)
root@4cb8abbf11ca:/opt/lib/rush# rustup -V
rustup 1.24.3 (ce5817a94 2021-05-31)
info: This is the version for the rustup toolchain manager, not the rustc compiler.
info: The currently active `rustc` version is `rustc 1.60.0-nightly (5e57faa78 2022-01-19)`
Here's the full docker build ...
command that resulted in this image, so you can see where the 04ca521c91d6
came from.
Looks like the Dockerfile
in this repo is always installing the latest nightly build of rust.
asm!
macroI spent a little more time reading the https://github.com/rust-lang/rust/issues/84019 thread I found earlier, and figured I'd try fiddling with the source to see if I could move things forward.
I namespaced the asm!
macro and voila! It built! Well, it complained with a warning, but that seems harmless:
Step 11/15 : RUN cargo build --release
---> Running in e28fc7c0a3ed
Compiling libc v0.2.68
(...)
Compiling rush v0.1.0 (/opt/lib/rush)
warning: the feature `asm` has been stable since 1.59.0 and no longer requires an attribute to enable
--> src/main.rs:3:12
|
3 | #![feature(asm)]
| ^^^
|
= note: `#[warn(stable_features)]` on by default
warning: `rush` (bin "rush") generated 1 warning
Finished release [optimized] target(s) in 12.60s
asm
Removing the feature
line caused the compilation to succeed with no warnings.
Fixed with #3
Expected behavior
Hello! When I clone this repo and run
make create-synthetic-network
and thenmake run-chrome
, I would expect the latter command to build the Docker image and exit successfully per the README.Describe the bug (unexpected behavior)
Instead, when I clone this repo and run
make run-chrome
thedocker build (...)
errors while runningcargo build --release
:Click to expand a shell session of the build and error log
Steps to reproduce
Screenshots
System information
I am not familiar with Rust programming. I found this thread that seems surface-similar to the error I received, and so I thought perhaps it was an architecture-specific problem; I am running on arm64 on an M1 Mac. However I see the same error on an x86 Mac.
OS and arch for both systems: