Skip to content

Commit 2c71f89

Browse files
committed
Remove old argon2 code and move remaining sources.
1 parent 70276a3 commit 2c71f89

32 files changed

+8
-4196
lines changed

wasm/argon2-benchmark.js

Lines changed: 0 additions & 44 deletions
This file was deleted.

wasm/argon2-bundle.js

Lines changed: 0 additions & 3768 deletions
This file was deleted.

wasm/argon2-simd.wasm

-26.3 KB
Binary file not shown.

wasm/argon2.js

Lines changed: 0 additions & 118 deletions
This file was deleted.

wasm/argon2.wasm

-25.3 KB
Binary file not shown.

wasm/argon2/CMakeLists.txt

Lines changed: 0 additions & 33 deletions
This file was deleted.

wasm/argon2/README.md

Lines changed: 0 additions & 11 deletions
This file was deleted.

wasm/argon2/build.log

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Built on 2025-02-11T15:51:03Z
1+
Built on 2025-02-11T16:03:39Z
22
Toolchain versions
33
emcc (Emscripten gcc/clang-like replacement + linker emulating GNU ld) 4.0.0-git
44
Building...

wasm/argon2/build.sh

Lines changed: 7 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,5 @@
11
#!/usr/bin/env bash
22

3-
4-
#!/bin/bash
5-
63
set -euo pipefail
74

85
rm -rf build/
@@ -16,14 +13,14 @@ emcc --version | head -n1 | tee -a "$BUILD_LOG"
1613

1714
# FIXME: Redownload the source if argon2 ever has source updates. At the time of writing it was last changed 5 years ago so this is probably not a high priority.
1815
SOURCES=(
19-
argon2/src/blake2/blake2b.c
16+
src/blake2/blake2b.c
2017

21-
argon2/src/argon2.c
22-
argon2/src/core.c
23-
argon2/src/encoding.c
24-
argon2/src/thread.c
18+
src/argon2.c
19+
src/core.c
20+
src/encoding.c
21+
src/thread.c
2522

26-
argon2/src/opt.c
23+
src/opt.c
2724
)
2825

2926
SIMD_FLAGS=(
@@ -39,34 +36,8 @@ emcc -o build/argon2.js \
3936
-g1 --emit-symbol-map \
4037
-DARGON2_NO_THREADS \
4138
-s MODULARIZE=1 -s EXPORT_NAME=setupModule -s EXPORTED_RUNTIME_METHODS=stringToNewUTF8,UTF8ToString -s EXPORTED_FUNCTIONS=_argon2_hash,_argon2_verify,_argon2_encodedlen,_argon2_error_message,_malloc,_free,_strlen \
42-
-Iargon2/include \
39+
-Iinclude \
4340
${SOURCES[@]} | tee -a "$BUILD_LOG"
4441

4542
echo "Building done" | tee -a "$BUILD_LOG"
4643
ls -lth build/
47-
48-
# set -e
49-
# set -o pipefail
50-
51-
# # Log emcc version
52-
# EMCC_SDK_PATH="/path/to/emsdk"
53-
# EMCC_PATH="$EMCC_SDK_PATH/upstream/emscripten/emcc"
54-
# $EMCC_PATH --version > emcc_version.txt
55-
56-
# # Build start
57-
# rm -rf dist
58-
# mkdir dist
59-
60-
# ./clean-cmake.sh
61-
# EMCC_SDK_PATH=$EMCC_SDK_PATH ARGON_JS_BUILD_BUILD_WITH_SIMD=1 ./build-wasm.sh
62-
# mv dist/argon2.wasm ../argon2-simd.wasm
63-
64-
# ./clean-cmake.sh
65-
# EMCC_SDK_PATH=$EMCC_SDK_PATH ARGON_JS_BUILD_BUILD_WITH_SIMD=0 ./build-wasm.sh
66-
# mv dist/argon2.wasm ../argon2.wasm
67-
68-
# ./clean-cmake.sh
69-
# rm -rf dist
70-
# # Build end
71-
72-
# echo Done

wasm/argon2/clean-cmake.sh

Lines changed: 0 additions & 9 deletions
This file was deleted.

0 commit comments

Comments
 (0)