#!/bin/sh -e

# shellcheck disable=SC2016
sed '/chown ${BINOWN}:${BINGRP}/d' bsd.prog.mk > _
cat _ > bsd.prog.mk; rm -f _

./configure \
    --enable-static \
    --without-pam

make
make DESTDIR="$1" install

install -D doas.conf "$1/etc/doas.conf"