Skip to content

Commit

Permalink
WIP: Quick and dirty - get WASM to pass CI
Browse files Browse the repository at this point in the history
  • Loading branch information
tcharding committed Jul 21, 2023
1 parent c6b103a commit ecb97c9
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 15 deletions.
15 changes: 0 additions & 15 deletions contrib/_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -83,21 +83,6 @@ if [ "$DO_DOCS" = true ]; then
RUSTDOCFLAGS="-D warnings" cargo +stable doc --all-features
fi

# Webassembly stuff
if [ "$DO_WASM" = true ]; then
clang --version
CARGO_TARGET_DIR=wasm cargo install --force wasm-pack

cp Cargo.toml orig-Cargo.toml
printf '\n[lib]\ncrate-type = ["cdylib", "rlib"]\n' >> Cargo.toml

CC=clang wasm-pack build
CC=clang wasm-pack test --node

rm Cargo.toml
mv orig-Cargo.toml Cargo.toml
fi

# Address Sanitizer
if [ "$DO_ASAN" = true ]; then
clang --version
Expand Down
13 changes: 13 additions & 0 deletions contrib/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,19 @@ REPO_DIR=$(git rev-parse --show-toplevel)

DEPS="recent minimal"

# Webassembly stuff
if [ "$DO_WASM" = true ]; then
clang --version
CARGO_TARGET_DIR=wasm cargo install --force wasm-pack

printf '\n[lib]\ncrate-type = ["cdylib", "rlib"]\n' >> Cargo.toml

CC=clang wasm-pack build
CC=clang wasm-pack test --node

exit 0
fi

for dep in $DEPS
do
cp "Cargo-$dep.lock" Cargo.lock
Expand Down

0 comments on commit ecb97c9

Please sign in to comment.