#!/SBUILD _disabled: false pkg: "b3sum" pkg_id: "blake3-team.blake3" pkg_type: "static" ghcr_pkg: "blake3-team/blake3" category: - "ConsoleOnly" - "Utility" description: "Command line utility for calculating BLAKE3 hashes" homepage: - "https://github.com/BLAKE3-team/BLAKE3" maintainer: - "QaidVoid (contact@qaidvoid.dev)" license: - "Apache-2.0" build_deps: - "docker" note: - "Built from source with static musl linking" - "[PORTABLE] (Portable Static Binary)" - "[NO_DESKTOP_INTEGRATION]" provides: - "b3sum" repology: - "blake3" src_url: - "https://github.com/BLAKE3-team/BLAKE3" tag: - "checksum" - "hash" - "blake3" x_exec: host: - "x86_64-linux" - "aarch64-linux" container: "ghcr.io/pkgforge/devscripts/alpine-builder" shell: "bash" pkgver: | curl -qfsSL "https://api.github.com/repos/BLAKE3-team/BLAKE3/releases/latest" | jq -r '.tag_name' run: | set -e cd "$(mktemp -d)" source "$HOME/.cargo/env" export RUST_TARGET="${ARCH}-unknown-linux-musl" export RUSTFLAGS="-C target-feature=+crt-static -C link-self-contained=yes" git clone --filter=blob:none --quiet "https://github.com/BLAKE3-team/BLAKE3" cd BLAKE3 git checkout "$PKGVER" cd b3sum cargo build --target="$RUST_TARGET" --release cp "target/$RUST_TARGET/release/b3sum" "$SBUILD_OUTDIR/" cp ../LICENSE_A2 "$SBUILD_OUTDIR/LICENSE" 2>/dev/null || true