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

add support for wasm/wasip1 build without mmap support #110

Merged
merged 1 commit into from
Jun 18, 2023

Conversation

ydnar
Copy link
Contributor

@ydnar ydnar commented Jun 18, 2023

Hi, thanks for writing this package. We’ve used it in production at Domainr for a long time. We’re in the midst of porting some of our infrastructure to WebAssembly + WASI, and wanted to contribute a patch.

This PR adds support for wasm + wasip1 builds in Go 1.21 via additional build tags.

  • The js build tag is used for legacy (browser) WebAssembly (GOARCH=wasm GOOS=js)
  • The wasip1 build tag is used for the new WASI Preview 1 in Go 1.21 (GOARCH=wasm GOOS=wasip1)

I took the liberty of renaming a couple files to better map their use (App Engine being one of many targets without mmap), and updated the doc comments.

Copy link
Owner

@oschwald oschwald left a comment

Choose a reason for hiding this comment

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

Nice. Thanks!

@oschwald oschwald merged commit 7d12b8c into oschwald:main Jun 18, 2023
8 of 9 checks passed
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.

None yet

2 participants