emosenkis / esp-rs

Script for installing/running toolchain for building ESP8266 firmware in Rust
MIT License
329 stars 19 forks source link

Build less of mrustc and do so with parallelism #27

Closed jcard0na closed 5 years ago

jcard0na commented 5 years ago

Do as suggested in #11 and #12

Tested using Docker file but not sure if it worked...

$ docker build -t esp-rs .
(snip)
 ---> c87a3fa49688
Successfully built c87a3fa49688
Successfully tagged esp-rs:latest

$ docker run -it esp-rs
root@e7dce2ac2027:/build/esp-rs# mkdir hello_world
root@e7dce2ac2027:/build/esp-rs# cd hello_world/
root@e7dce2ac2027:/build/esp-rs/hello_world# ../build.sh
Installation does not seem to be complete. Try running with --ins
root@e7dce2ac2027:/build/esp-rs/hello_world# bindgen --version
thread 'main' panicked at 'Unable to find libclang: "couldn\'t find any valid shared libraries matching: [\'libclang.so\', \'libclang-*.so\', \'libclang.so.*\'], set the `LIBCLANG_PATH` environment variable to a path where one of these files can be found (invalid: [])"', src/libcore/result.rs:997:5
note: Run with `RUST_BACKTRACE=1` environment variable to display a backtrace.

However native compilation works...

root@e7dce2ac2027:/build/esp-rs/hello_world# export USER=root
root@e7dce2ac2027:/build/esp-rs/hello_world# cargo new foobar
     Created binary (application) `foobar` package
root@e7dce2ac2027:/build/esp-rs/hello_world# cd foobar/
root@e7dce2ac2027:/build/esp-rs/hello_world/foobar# cargo run
   Compiling foobar v0.1.0 (/build/esp-rs/hello_world/foobar)
    Finished dev [unoptimized + debuginfo] target(s) in 0.33s
     Running `target/debug/foobar`
Hello, world!

Any suggestions

emosenkis commented 5 years ago

Thanks!