Skip to content

Commit

Permalink
Fix wasm target usage (#1846)
Browse files Browse the repository at this point in the history
  • Loading branch information
Thomasdezeeuw authored Dec 3, 2024
1 parent f45f492 commit 54e4397
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ rustdoc-args = ["--cfg", "docsrs", "--generate-link-to-definition"]
targets = [
"aarch64-apple-ios",
"aarch64-linux-android",
"wasm32-wasi",
"wasm32-wasip1",
"x86_64-apple-darwin",
"x86_64-pc-windows-gnu",
"x86_64-pc-windows-msvc",
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Targets available via Rustup that are supported.
TARGETS ?= aarch64-apple-darwin aarch64-apple-ios aarch64-linux-android arm-linux-androideabi i686-unknown-linux-gnu wasm32-wasi x86_64-apple-darwin x86_64-apple-ios x86_64-pc-windows-gnu x86_64-pc-windows-msvc x86_64-unknown-freebsd x86_64-unknown-illumos x86_64-unknown-linux-gnu x86_64-unknown-linux-musl x86_64-unknown-netbsd x86_64-unknown-redox
TARGETS ?= x86_64-pc-windows-msvc x86_64-unknown-freebsd x86_64-unknown-illumos x86_64-unknown-linux-gnu x86_64-unknown-linux-musl x86_64-unknown-netbsd x86_64-unknown-redox
# Example value: `nightly-x86_64-apple-darwin`.
RUSTUP_TOOLCHAIN ?= $(shell rustup show active-toolchain | cut -d' ' -f1)
# Architecture target. Example value: `x86_64-apple-darwin`.
Expand Down
4 changes: 2 additions & 2 deletions examples/tcp_listenfd_server.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
// You can run this example from the root of the mio repo:
// cargo run --example tcp_listenfd_server --features="os-poll net"
// or with wasi:
// cargo +nightly build --target wasm32-wasi --example tcp_listenfd_server --features="os-poll net"
// wasmtime run --tcplisten 127.0.0.1:9000 --env 'LISTEN_FDS=1' target/wasm32-wasi/debug/examples/tcp_listenfd_server.wasm
// cargo +nightly build --target wasm32-wasip1 --example tcp_listenfd_server --features="os-poll net"
// wasmtime run --tcplisten 127.0.0.1:9000 --env 'LISTEN_FDS=1' target/wasm32-wasip1/debug/examples/tcp_listenfd_server.wasm

use mio::event::Event;
use mio::net::{TcpListener, TcpStream};
Expand Down

0 comments on commit 54e4397

Please sign in to comment.