From 5034d43e6db92d24f96c55375e648dc3d23bef4b Mon Sep 17 00:00:00 2001 From: Byeongkeun Ahn <7p54ks3@naver.com> Date: Wed, 3 Jul 2024 20:30:37 +0900 Subject: [PATCH 1/3] Update build-windows.yml --- .github/workflows/build-windows.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/build-windows.yml b/.github/workflows/build-windows.yml index a995859f..856eb972 100644 --- a/.github/workflows/build-windows.yml +++ b/.github/workflows/build-windows.yml @@ -37,9 +37,7 @@ jobs: run: | python -m pip install pefile - name: Clippy - run: cargo clippy --all-targets - env: - RUSTFLAGS: "-D warnings -A clippy::missing_safety_doc" + run: cargo clippy --all-targets -- -D warnings -A clippy::missing_safety_doc - name: Rustfmt run: cargo fmt --check --all - name: Test From f485102ebeb84c75136736f98c98dd89615e86e8 Mon Sep 17 00:00:00 2001 From: Byeongkeun Ahn <7p54ks3@naver.com> Date: Sat, 6 Jul 2024 10:12:29 +0900 Subject: [PATCH 2/3] Bump compiler-builtins to 0.1.113 --- basm-std/Cargo.toml | 12 ++++++------ basm/Cargo.toml | 10 +++++----- basm/src/bin/lang_items.rs | 6 ------ 3 files changed, 11 insertions(+), 17 deletions(-) diff --git a/basm-std/Cargo.toml b/basm-std/Cargo.toml index eb1e96bf..74714ee3 100644 --- a/basm-std/Cargo.toml +++ b/basm-std/Cargo.toml @@ -15,17 +15,17 @@ libm = "0.2.7" ryu = "1.0" [target.x86_64-pc-windows-msvc.dependencies] -compiler_builtins = { version = "0.1.111", features = ["mem"] } +compiler_builtins = { version = "0.1.113", features = ["mem"] } [target.x86_64-pc-windows-gnu.dependencies] -compiler_builtins = { version = "0.1.111", features = ["mem"] } +compiler_builtins = { version = "0.1.113", features = ["mem"] } [target.x86_64-unknown-linux-gnu.dependencies] -compiler_builtins = { version = "0.1.111", features = ["mem"] } +compiler_builtins = { version = "0.1.113", features = ["mem"] } [target.i686-unknown-linux-gnu.dependencies] -compiler_builtins = { version = "0.1.111", features = ["mem"] } +compiler_builtins = { version = "0.1.113", features = ["mem"] } [target.aarch64-apple-darwin.dependencies] -compiler_builtins = { version = "0.1.111", features = ["mem"] } +compiler_builtins = { version = "0.1.113", features = ["mem"] } [target.wasm32-unknown-unknown.dependencies] -compiler_builtins = { version = "0.1.111", features = ["mem"] } +compiler_builtins = { version = "0.1.113", features = ["mem"] } [features] # Enables codegen routines. diff --git a/basm/Cargo.toml b/basm/Cargo.toml index 52e0ecff..840b54fe 100644 --- a/basm/Cargo.toml +++ b/basm/Cargo.toml @@ -30,15 +30,15 @@ basm-macro = { path = "../basm-macro" } basm-std = { path = "../basm-std", features = ["codegen"] } [target.x86_64-pc-windows-msvc.dependencies] -compiler_builtins = { version = "0.1.111", features = ["mem"] } +compiler_builtins = { version = "0.1.113", features = ["mem"] } [target.x86_64-pc-windows-gnu.dependencies] -compiler_builtins = { version = "0.1.111", features = ["mem"] } +compiler_builtins = { version = "0.1.113", features = ["mem"] } [target.x86_64-unknown-linux-gnu.dependencies] -compiler_builtins = { version = "0.1.111", features = ["mem"] } +compiler_builtins = { version = "0.1.113", features = ["mem"] } [target.i686-unknown-linux-gnu.dependencies] -compiler_builtins = { version = "0.1.111", features = ["mem"] } +compiler_builtins = { version = "0.1.113", features = ["mem"] } [target.wasm32-unknown-unknown.dependencies] -compiler_builtins = { version = "0.1.111", features = ["mem"] } +compiler_builtins = { version = "0.1.113", features = ["mem"] } [features] short = ["basm-std/short"] diff --git a/basm/src/bin/lang_items.rs b/basm/src/bin/lang_items.rs index 706e9eef..db0ca9c8 100644 --- a/basm/src/bin/lang_items.rs +++ b/basm/src/bin/lang_items.rs @@ -18,12 +18,6 @@ mod runtime { unsafe { core::hint::unreachable_unchecked() } } - // Temporary fix for Windows build failure. - // This should be removed later. - #[no_mangle] - #[cfg(target_os = "windows")] - extern "win64" fn __unordtf2() {} - #[no_mangle] #[allow(non_snake_case)] fn _Unwind_Resume() { From 69b87b1eefe0c7c4b7c7316517c6413cb122c84c Mon Sep 17 00:00:00 2001 From: Byeongkeun Ahn <7p54ks3@naver.com> Date: Sat, 6 Jul 2024 10:14:22 +0900 Subject: [PATCH 3/3] CI: do not set RUSTFLAGS as env var --- .cargo/config.toml | 2 +- .github/workflows/build-linux.yml | 4 +--- .github/workflows/build-macos.yml | 4 +--- 3 files changed, 3 insertions(+), 7 deletions(-) diff --git a/.cargo/config.toml b/.cargo/config.toml index 373363e7..7d7416aa 100644 --- a/.cargo/config.toml +++ b/.cargo/config.toml @@ -5,7 +5,7 @@ rustflags = ["-Z", "share-generics=no", "-Z", "export-executable-symbols", "-C", rustflags = ["-Z", "share-generics=no", "-C", "relocation-model=pie"] [target.x86_64-pc-windows-gnu] -rustflags = ["-Z", "share-generics=no", "-Z", "export-executable-symbols", "-C", "lto=thin", "-C", "target-feature=+avx,+avx2,+sse,+sse2,+sse3,+ssse3,+sse4.1,+sse4.2,+fma,+f16c,+aes", "-C", "relocation-model=pie", "-C", "target-cpu=haswell"] +rustflags = ["-Z", "share-generics=no", "-Z", "export-executable-symbols", "-C", "embed-bitcode=yes", "-C", "lto=thin", "-C", "target-feature=+avx,+avx2,+sse,+sse2,+sse3,+ssse3,+sse4.1,+sse4.2,+fma,+f16c,+aes", "-C", "relocation-model=pie", "-C", "target-cpu=haswell"] linker = "x86_64-w64-mingw32-gcc" [target.wasm32-unknown-unknown] diff --git a/.github/workflows/build-linux.yml b/.github/workflows/build-linux.yml index 2ab47463..1e5de320 100644 --- a/.github/workflows/build-linux.yml +++ b/.github/workflows/build-linux.yml @@ -38,9 +38,7 @@ jobs: rustup component add rust-src --toolchain nightly-x86_64-unknown-linux-gnu python -m pip install pefile - name: Clippy - run: cargo clippy --all-targets - env: - RUSTFLAGS: "-D warnings -A clippy::missing_safety_doc" + run: cargo clippy --all-targets -- -D warnings -A clippy::missing_safety_doc - name: Rustfmt run: cargo fmt --check --all - name: Test diff --git a/.github/workflows/build-macos.yml b/.github/workflows/build-macos.yml index ad854d3b..7528b90d 100644 --- a/.github/workflows/build-macos.yml +++ b/.github/workflows/build-macos.yml @@ -39,9 +39,7 @@ jobs: brew install gcc rustup component add rust-src --toolchain nightly-aarch64-apple-darwin - name: Clippy - run: cargo clippy --all-targets - env: - RUSTFLAGS: "-D warnings -A clippy::missing_safety_doc" + run: cargo clippy --all-targets -- -D warnings -A clippy::missing_safety_doc - name: Rustfmt run: cargo fmt --check --all - name: Test