From 7d953fbcc46768d8bc3518e6db9fc6619e59908e Mon Sep 17 00:00:00 2001 From: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com> Date: Thu, 5 Sep 2024 20:03:17 +0200 Subject: [PATCH 1/3] chore: Bump Rust to 1.81 --- Dockerfile | 2 +- rust-toolchain.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 03f63aa39c80ec..70c47c9f671e18 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ # syntax = docker/dockerfile:1.2 -FROM rust:1.80-bookworm as builder +FROM rust:1.81-bookworm as builder WORKDIR app COPY . . diff --git a/rust-toolchain.toml b/rust-toolchain.toml index 688b21f75509ee..645221dec39f40 100644 --- a/rust-toolchain.toml +++ b/rust-toolchain.toml @@ -1,5 +1,5 @@ [toolchain] -channel = "1.80" +channel = "1.81" profile = "minimal" components = [ "rustfmt", "clippy" ] targets = [ "x86_64-apple-darwin", "aarch64-apple-darwin", "x86_64-unknown-linux-gnu", "wasm32-wasi", "x86_64-pc-windows-msvc" ] From f09c4b24a81832b188d5287c08acec250945806f Mon Sep 17 00:00:00 2001 From: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com> Date: Thu, 5 Sep 2024 22:48:17 +0200 Subject: [PATCH 2/3] Update rust-toolchain.toml Co-authored-by: Finn Evers <75036051+MrSubidubi@users.noreply.github.com> --- rust-toolchain.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rust-toolchain.toml b/rust-toolchain.toml index 645221dec39f40..820aa9bbc75552 100644 --- a/rust-toolchain.toml +++ b/rust-toolchain.toml @@ -2,4 +2,4 @@ channel = "1.81" profile = "minimal" components = [ "rustfmt", "clippy" ] -targets = [ "x86_64-apple-darwin", "aarch64-apple-darwin", "x86_64-unknown-linux-gnu", "wasm32-wasi", "x86_64-pc-windows-msvc" ] +targets = [ "x86_64-apple-darwin", "aarch64-apple-darwin", "x86_64-unknown-linux-gnu", "wasm32-wasip1", "x86_64-pc-windows-msvc" ] From 32c1e3001a463467238be717c5e8ed5a7e4840ff Mon Sep 17 00:00:00 2001 From: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com> Date: Thu, 5 Sep 2024 22:50:55 +0200 Subject: [PATCH 3/3] Update WASI target name --- crates/extension/src/extension_builder.rs | 4 ++-- docs/src/development/macos.md | 2 +- docs/src/development/windows.md | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/crates/extension/src/extension_builder.rs b/crates/extension/src/extension_builder.rs index 11b8fbc934e146..8eeb5d9c45b671 100644 --- a/crates/extension/src/extension_builder.rs +++ b/crates/extension/src/extension_builder.rs @@ -24,7 +24,7 @@ use wit_component::ComponentEncoder; /// /// Once Rust 1.78 is released, there will be a `wasm32-wasip2` target available, so we will /// not need the adapter anymore. -const RUST_TARGET: &str = "wasm32-wasi"; +const RUST_TARGET: &str = "wasm32-wasip1"; const WASI_ADAPTER_URL: &str = "https://github.com/bytecodealliance/wasmtime/releases/download/v18.0.2/wasi_snapshot_preview1.reactor.wasm"; @@ -158,7 +158,7 @@ impl ExtensionBuilder { &cargo_toml .package .name - // The wasm32-wasi target normalizes `-` in package names to `_` in the resulting `.wasm` file. + // The wasm32-wasip1 target normalizes `-` in package names to `_` in the resulting `.wasm` file. .replace('-', "_"), ]); wasm_path.set_extension("wasm"); diff --git a/docs/src/development/macos.md b/docs/src/development/macos.md index 0108cbb9457fec..5ef01fe6daf546 100644 --- a/docs/src/development/macos.md +++ b/docs/src/development/macos.md @@ -26,7 +26,7 @@ Clone down the [Zed repository](https://github.com/zed-industries/zed). - Install the Rust wasm toolchain: ```sh - rustup target add wasm32-wasi + rustup target add wasm32-wasip1 ``` ## Backend Dependencies diff --git a/docs/src/development/windows.md b/docs/src/development/windows.md index b0277212712085..600c030931f27f 100644 --- a/docs/src/development/windows.md +++ b/docs/src/development/windows.md @@ -17,7 +17,7 @@ Clone down the [Zed repository](https://github.com/zed-industries/zed). - Install the Rust wasm toolchain: ```sh - rustup target add wasm32-wasi + rustup target add wasm32-wasip1 ``` - Install [Visual Studio](https://visualstudio.microsoft.com/downloads/) with the optional component `MSVC v*** - VS YYYY C++ x64/x86 build tools` (`v***` is your VS version and `YYYY` is year when your VS was released)