-
Notifications
You must be signed in to change notification settings - Fork 412
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
wasm-opt binary not found, even though it's in PATH #1062
Comments
Run That said, when using wasm-pack on NixOS, apparently just having this package in your build environment will allow it to resolve |
That shouldn't be an issue here, we don't package Binaryen binaries in a way that would cause that (we build from source using our toolchains etc. so the paths are correct). |
Ah, hrm, my bad. I came here to see how others were getting around the binaryen auto-install, and assumed you'd fallen for the classic unclear mising interpreter error message. If it's a data point for you, I can't reproduce this, using wasm-pack 0.10.2 and binaryen 102 from nixpkgs. They appear to be unpatched downstream, so perhaps this has been resolved by now? |
I am probably in a similar situation. OS: Windows 10 (but also on Fedora 37) Version info: PS hello-wasm> wasm-pack --version
wasm-pack 0.11.0
PS hello-wasm> (Get-Command wasm-pack).Source
C:\Users\user\.cargo\bin\wasm-pack.exe
PS hello-wasm> wasm-opt --version
wasm-opt version 112 (version_112)
PS hello-wasm> (Get-Command wasm-opt).Source
C:\Users\user\scoop\shims\wasm-opt.exe And I get the following error: PS hello-wasm> wasm-pack build --target web
[INFO]: Checking for the Wasm target...
[INFO]: Compiling to Wasm...
Finished release [optimized] target(s) in 0.03s
[WARN]: :-) origin crate has no README
[INFO]: Installing wasm-bindgen...
[INFO]: found wasm-opt at "C:\\Users\\user\\scoop\\shims\\wasm-opt.exe"
Error: C:\Users\user\scoop\shims\bin/wasm-opt.exe binary does not exist
To disable `wasm-opt`, add `wasm-opt = false` to your package metadata in your `Cargo.toml`.
Caused by: C:\Users\user\scoop\shims\bin/wasm-opt.exe binary does not exist
To disable `wasm-opt`, add `wasm-opt = false` to your package metadata in your `Cargo.toml`. In this case, you can see that it is looking for a different path ( The following locations appear to be the cause: Lines 53 to 59 in d5cb84e
Lines 14 to 26 in d5cb84e
(I think it would be better if the path to binaryen tools could be specified by command line options) |
There seems to be an issue (or an expected change) in wasm-pack 0.11.0: rustwasm/wasm-pack#1062, where a path to`wasm-opt` is not detected correctly. This breaks our build. Everything seems to be working well on wasm-pack 0.10.3, so let's freeze the version for the time being.
There seems to be an issue (or an expected change) in wasm-pack 0.11.0: rustwasm/wasm-pack#1062, where a path to`wasm-opt` is not detected correctly. This [breaks our build](https://github.com/nextstrain/nextclade/actions/runs/4474405842/jobs/7862840403). Everything seems to be working well on wasm-pack 0.10.3, so let's freeze the version for the time being.
Changes related to the above error: |
Thanks for reporting. At a quick glance, is the problem slash differences between unix-systems and windows? |
No, it occurs regardless of OS (I have opened a new issue #1247 , and please see: #1247 (comment). The same problem has been confirmed on mac and linux). The problem is caused by trying to run When a tarball (e.g. binaryen-version_111-x86_64-linux.tar.gz) is newly downloaded, this |
nakamurarts is correct. I used this patch to fix the problem:
|
This problem happens, by the way, on a Debian 11.6 (i.e. bullseye which is current stable) system (running binaryen version 99-3). So, not a niche development platform, particularly. |
A fix for this was merged in #1257, so installing a git version of |
v0.11.1 is now released: |
🐛 Bug description
My copy of
wasm-opt
isn't found bywasm-pack
, even though it is in myPATH
.🤔 Expected Behavior
It should've found it.
👟 Steps to reproduce
Run
wasm-pack
with--mode no-install
.🌍 Your environment
Include the relevant details of your environment.
wasm-pack version: 0.9.1
rustc version: 1.55.0
Additional context
Even the
which
crate that's used to find the binary agrees with me, so I'm really not sure what could be wrong...The text was updated successfully, but these errors were encountered: