Skip to content

Commit

Permalink
Update documentation to recommend using y.sh rustc instead of `rust…
Browse files Browse the repository at this point in the history
…c` and all its flags
  • Loading branch information
GuillaumeGomez committed Apr 6, 2024
1 parent 00ad263 commit 2a99110
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,13 @@ error: failed to copy bitcode to object file: No such file or directory (os erro

### Rustc

> You should prefer using the Cargo method.
If you want to run `rustc` directly, you can do so with:

```bash
$ ./y.sh rustc my_crate.rs
```

You can do the same manually (although we don't recommend it):

```bash
$ LIBRARY_PATH="[gcc-path value]" LD_LIBRARY_PATH="[gcc-path value]" rustc +$(cat $CG_GCCJIT_DIR/rust-toolchain | grep 'channel' | cut -d '=' -f 2 | sed 's/"//g' | sed 's/ //g') -Cpanic=abort -Zcodegen-backend=$CG_GCCJIT_DIR/target/release/librustc_codegen_gcc.so --sysroot $CG_GCCJIT_DIR/build_sysroot/sysroot my_crate.rs
Expand Down

0 comments on commit 2a99110

Please sign in to comment.