Add ASN.1-to-Java codegen and RLP codec for spend/signed tx subset.

Generate typed records from GajumaruChainObjects.asn, implement Asn1Rlp
and BasicEncoders matching Erlang static serialization, and add golden-vector
equivalence tests against gmser_chain_objects output.
This commit is contained in:
Ulf Wiger
2026-07-22 11:31:15 +02:00
parent 9492d193d6
commit 53eaa3056a
9 changed files with 1144 additions and 2 deletions
+10 -2
View File
@@ -8,14 +8,22 @@ set -e
abs_dir="$(cd -P $(dirname ${BASH_SOURCE}) && pwd)"
project_dir="$(dirname $abs_dir)"
# Prefer Homebrew OpenJDK when /usr/bin/java is a macOS stub.
if [[ -x /opt/homebrew/opt/openjdk/bin/javac ]]; then
export PATH="/opt/homebrew/opt/openjdk/bin:$PATH"
elif [[ -x /opt/homebrew/opt/openjdk@25/bin/javac ]]; then
export PATH="/opt/homebrew/opt/openjdk@25/bin:$PATH"
elif [[ -x /opt/homebrew/opt/openjdk@21/bin/javac ]]; then
export PATH="/opt/homebrew/opt/openjdk@21/bin:$PATH"
fi
# Clean
rm -rf "$project_dir/build/classes/*"
rm -f "$project_dir/Testinator.class"
# Build every .java file
find "$project_dir/src/main/java" -name "*.java" | xargs javac \
-source 21 \
-target 21 \
--release 21 \
-d "$project_dir/build/classes"
# Build the Testinator thingy