Skip to content

Commit

Permalink
crux-mir README: Update translate_libs.sh usage
Browse files Browse the repository at this point in the history
  • Loading branch information
qsctr committed Dec 7, 2023
1 parent 46ad672 commit 5116a34
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions crux-mir/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,18 +28,17 @@ Use 8.10.7, 9.2.7, or 9.4.4. From the `crux-mir` directory, run:

$ cabal v2-install exe:crux-mir --overwrite-policy=always

Then translate the Rust libraries in `lib/` (requires
[`jq`](https://jqlang.github.io/jq/)):
Then translate the Rust libraries in `lib/`:

$ ./translate_libs.sh

If you want to cross-compile for a different target, you can pass a [target
triple](https://doc.rust-lang.org/nightly/rustc/platform-support.html) as an
optional argument to `./translate_libs.sh`. This is experimental and we have
only tested `wasm32-unknown-unknown` to work; you might get build errors for
other targets.
If you want to cross-compile for a different target, you can optionally set the
environment variable `TARGET` to a [target
triple](https://doc.rust-lang.org/nightly/rustc/platform-support.html) when
running `./translate_libs.sh`. This is experimental and we have only tested
`wasm32-unknown-unknown` to work; you might get build errors for other targets.

$ ./translate_libs.sh wasm32-unknown-unknown
$ TARGET=wasm32-unknown-unknown ./translate_libs.sh

When upgrading from a previous version, first install the new `mir-json`
version, then rerun the `cabal v2-install` and `./translate_libs.sh` commands.
Expand Down

0 comments on commit 5116a34

Please sign in to comment.