Skip to content
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

Detect compatible wasm-opt versions and improve error messages #242

Merged
merged 6 commits into from
Mar 30, 2021

Conversation

cmichi
Copy link
Collaborator

@cmichi cmichi commented Mar 30, 2021

The improved error message:

ERROR: wasm-opt not found!
We use this tool to optimize the size of your contract's Wasm binary.

wasm-opt is part of the binaryen package. You can find detailed
installation instructions on https://github.com/WebAssembly/binaryen#tools.

There are also ready-to-install packages for many platforms:
* Debian/Ubuntu: https://tracker.debian.org/pkg/binaryen
* Homebrew: https://formulae.brew.sh/formula/binaryen
* Arch Linux: https://archlinux.org/packages/community/x86_64/binaryen
* Windows: binary releases are available at https://github.com/WebAssembly/binaryen/releases

I'm aware that linking packages here can be seen as controversial, but due to the number of questions we get in public channels regarding this I think we should consider it.

@cmichi cmichi requested a review from ascjones March 30, 2021 09:51
@ascjones
Copy link
Collaborator

I'm aware that linking packages here can be seen as controversial, but due to the number of questions we get in public channels regarding this I think we should consider it.

Worth it to decrease the support burden IMO.

src/cmd/build.rs Show resolved Hide resolved
src/cmd/build.rs Outdated Show resolved Hide resolved
src/cmd/build.rs Outdated Show resolved Hide resolved
src/cmd/build.rs Outdated Show resolved Hide resolved
src/cmd/build.rs Outdated Show resolved Hide resolved
src/cmd/build.rs Outdated Show resolved Hide resolved
Michael Müller and others added 3 commits March 30, 2021 13:32
Copy link
Collaborator

@ascjones ascjones left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@cmichi cmichi merged commit 449a40f into master Mar 30, 2021
@cmichi cmichi deleted the cmichi-add-check-for-correct-wasm-opt-version branch March 30, 2021 11:55
@cmichi cmichi mentioned this pull request Mar 31, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants