- Introduced a comprehensive build system that supports multiple platforms (Linux, macOS, Windows, Android) using pure Go builds (`CGO_ENABLED=0`). - Updated all build and test scripts to ensure compatibility with the new purego approach, allowing for dynamic loading of `libsecp256k1` at runtime. - Added detailed documentation on the build process, platform detection, and deployment options. - Enhanced CI/CD workflows to automate builds for all supported platforms and include necessary libraries in releases. - Updated `.gitignore` to exclude build output files. - Created new documentation files for deployment and multi-platform build summaries.
28 lines
549 B
Bash
Executable File
28 lines
549 B
Bash
Executable File
#!/usr/bin/env bash
|
|
# Pure Go build with purego - no CGO needed
|
|
# libsecp256k1 is loaded dynamically at runtime if available
|
|
export CGO_ENABLED=0
|
|
if [ -f "pkg/crypto/p8k/libsecp256k1.so" ]; then
|
|
export LD_LIBRARY_PATH="${LD_LIBRARY_PATH:+$LD_LIBRARY_PATH:}$(pwd)/pkg/crypto/p8k"
|
|
fi
|
|
|
|
go mod tidy
|
|
go test ./...
|
|
cd pkg/crypto
|
|
go mod tidy
|
|
go test ./...
|
|
cd ../database
|
|
go mod tidy
|
|
go test ./...
|
|
cd ../encoders
|
|
go mod tidy
|
|
go test ./...
|
|
cd ../protocol
|
|
go mod tidy
|
|
go test ./...
|
|
cd ../utils
|
|
go mod tidy
|
|
go test ./...
|
|
cd ../acl
|
|
go mod tidy
|
|
go test ./... |