Skip to content

Commit 307aa1e

Browse files
committed
Merge branch 'main' into ps/state-traits
2 parents 1be6c69 + f28b4ef commit 307aa1e

File tree

3 files changed

+8
-3
lines changed

3 files changed

+8
-3
lines changed

Cargo.lock

Lines changed: 1 addition & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,12 @@ wasm-bindgen = { version = ">=0.2.91, <0.3", features = ["serde-serialize"] }
6464
js-sys = { version = ">=0.3.72, <0.4" }
6565
wasm-bindgen-futures = "0.4.41"
6666

67+
# There is an incompatibility when using pkcs5 and chacha20 on wasm builds. This can be removed once a new
68+
# rustcrypto-formats crate version is released since the fix has been upstreamed.
69+
# https://github.com/RustCrypto/formats/pull/1625
70+
[patch.crates-io]
71+
pkcs5 = { git = "https://github.com/bitwarden/rustcrypto-formats.git", rev = "2b27c63034217dd126bbf5ed874da51b84f8c705" }
72+
6773
[workspace.lints.clippy]
6874
unused_async = "deny"
6975
unwrap_used = "deny"

crates/bitwarden-wasm-internal/build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ fi
2525
# Note that this requirest build-std which is an unstable feature,
2626
# this normally requires a nightly build, but we can also use the
2727
# RUSTC_BOOTSTRAP hack to use the same stable version as the normal build
28-
RUSTFLAGS=-Ctarget-cpu=mvp RUSTC_BOOTSTRAP=1 cargo build -p bitwarden-wasm-internal -Zbuild-std=panic_abort,std --target wasm32-unknown-unknown ${RELEASE_FLAG} --config 'patch.crates-io.pkcs5.git="https://github.com/bitwarden/rustcrypto-formats.git"' --config 'patch.crates-io.pkcs5.rev="2b27c63034217dd126bbf5ed874da51b84f8c705"'
28+
RUSTFLAGS=-Ctarget-cpu=mvp RUSTC_BOOTSTRAP=1 cargo build -p bitwarden-wasm-internal -Zbuild-std=panic_abort,std --target wasm32-unknown-unknown ${RELEASE_FLAG}
2929
wasm-bindgen --target bundler --out-dir crates/bitwarden-wasm-internal/npm ./target/wasm32-unknown-unknown/${BUILD_FOLDER}/bitwarden_wasm_internal.wasm
3030
wasm-bindgen --target nodejs --out-dir crates/bitwarden-wasm-internal/npm/node ./target/wasm32-unknown-unknown/${BUILD_FOLDER}/bitwarden_wasm_internal.wasm
3131

0 commit comments

Comments
 (0)