# Enabling buildmode=pie for security features, where Go GC Compiler hasn't supported on MIPS yet.
if ! ab_match_arch loongson3; then
    abinfo "Enabling buildmode=pie ..."
    export GOFLAGS="${GOFLAGS} -buildmode=pie"
fi

abinfo "Building chisel..."
go build

abinfo "Installing the binary..."
install -Dvm755 "$SRCDIR"/chisel "$PKGDIR"/usr/bin/chisel
