The andromeda
libraries aims to provide logical blocks to build a privacy-focused, cross-platform, self-custody Bitcoin, integrated in Proton's ecosystem
The project is split up into several crates in the /crates
directory:
api
: Contains an api client to call Proton Wallet backend HTTP APIbitcoin
: A library that provides utilities to use bitcoin on the 1rst layer such as chain syncing, transactions/balance/utxos retrieving, address generating and obviously transaction building, signing and broadcasting.wasm
: Relevant interfaces to WASM (should be migrated to its own repo)
This chapter outlines the steps for building the WebAssembly (Wasm) package on macOS.
You will need to install the following tools:
- Xcode Command Line Tools
- Homebrew: macOS package manager
- gcc: GNU Compiler Collection
- llvm: Includes clang, the front-end compiler for WebAssembly
- lld: The LLVM linker, necessary for WebAssembly linking
- Install Xcode Command Line Tools (if not already installed):
xcode-select --install
- Install Homebrew (if not already installed):
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
- Install gcc, llvm and lld:
brew install gcc llvm lld
- Add gcc, llvm and lld to your PATH (replace 14 by the installed version):
echo 'export PATH="/opt/homebrew/opt/llvm/bin:$PATH"' >> ~/.zshrc echo 'export CC="$(brew --prefix gcc@14)/bin/gcc-14"' >> ~/.zshrc echo 'export CXX="$(brew --prefix gcc@14)/bin/g++-14"' >> ~/.zshrc echo 'alias gcc="gcc-14"' >> ~/.zshrc echo 'alias cc="gcc-14"' >> ~/.zshrc echo 'alias g++="g++-14"' >> ~/.zshrc echo 'alias c++="c++-14"' >> ~/.zshrc source ~/.zshrc
After installing prerequisite, install wasm-pack and build wasm crate:
cargo build
cd crates/wasm
wasm-pack build --out-name index
The code and data files in this distribution are licensed under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. See https://www.gnu.org/licenses/ for a copy of this license.
See LICENSE file