You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The version of LLVM on your PATH does not support thewasm32-unknown-wasi triple (this is the default on macOS aarch64 even after running brew install llvm as the non-wasi Apple clang at /usr/bin/clang takes precedence)
Steps:
Run make in the root of the project. The runtime build will fail with error: unable to create target: 'No available targets are compatible with triple "wasm32-unknown-wasi"'
Run make CC=$(brew --prefix llvm)/bin/clang LIBTOOL=$(brew --prefix llvm)/bin/llvm-ar build
Expected
The instructions build and installs Juvix from source.
Actual
The build continues to fail at the make runtime stage with the error: error: unable to create target: 'No available targets are compatible with triple "wasm32-unknown-wasi"'
Workaround
After the error in step 1. of the reproduction steps, run (for macOS):
make clean
make CC=$(brew --prefix llvm)/bin/clang LIBTOOL=$(brew --prefix llvm)/bin/llvm-ar build
Explanation
After the initial failing build, the runtime build stores the resolved Makefile parameters as state in the build directory. This state is reused even if the Makefile parameters are subsequently changed.
The text was updated successfully, but these errors were encountered:
On macOS with recent versions of LLVM (at least 16+) the instructions to install libclang_rt.builtins-wasm32-wasi-*.tar.gz in https://docs.juvix.org/0.5.4/howto/installing/#installing-dependencies are redundant. They may still be necessary on Linux. We should check this and remove this section if possible.
…file (#2538)
This is an attempt to fix a confusing situation where a user:
1. Builds the runtime with clang that does not support wasm32-wasi
2. Attempts to rebuild the runtime by passing the CC parameter pointing
to another installation of clang that does support wasm32-wasi.
In step 1. the runtime Makefile generates dependencies files which
contain the resolved value of `$(CC)`. When the user passes the correct
`CC` variable to the Makefile in step 2., the dependencies files are not
regenerated, the old value of `CC` is used in the build and the build
continues to fail.
In this PR we change the dependency file generation so that the
variables like `$(CC)` are written into the dependency file verbatim.
They are resolved when they are run in step 2. using the new value of
the CC parameter.
* Closes#2537
To reproduce
Precondition:
wasm32-unknown-wasi
triple (this is the default on macOS aarch64 even after runningbrew install llvm
as the non-wasi Apple clang at/usr/bin/clang
takes precedence)Steps:
make
in the root of the project. The runtime build will fail witherror: unable to create target: 'No available targets are compatible with triple "wasm32-unknown-wasi"'
make CC=$(brew --prefix llvm)/bin/clang LIBTOOL=$(brew --prefix llvm)/bin/llvm-ar build
Expected
The instructions build and installs Juvix from source.
Actual
The build continues to fail at the
make runtime
stage with the error:error: unable to create target: 'No available targets are compatible with triple "wasm32-unknown-wasi"'
Workaround
After the error in step 1. of the reproduction steps, run (for macOS):
Explanation
After the initial failing build, the runtime build stores the resolved Makefile parameters as state in the build directory. This state is reused even if the Makefile parameters are subsequently changed.
The text was updated successfully, but these errors were encountered: