#!/usr/bin/env bash # brintld — the link + pass engine front door. # # The link is where the whole-program bitcode closure is merged, the pass runs # once over the merged module, and the final wasm-ld happens. Both inputs are # required: the pinned LLVM, and the sysroot the linker takes its libc bitcode # pool, its startfiles AND its staged pass plugins from. set -euo pipefail # readlink -f, not dirname alone: these front doors are meant to be symlinked # into a prefix on PATH, and a symlink's dirname is the prefix, not this repo. source "$(dirname "$(readlink -f "${BASH_SOURCE[0]}")")/../libexec/config.sh" brintium_require llvm sysroot exec "$BRINTIUM/libexec/brintld" "$@"