PKGNAME=update-alternatives
PKGSEC=admin
PKGDEP="glibc"
BUILDDEP="bzip2 diffutils doxygen glibc graphviz less libmd ncurses patch \
          perl-locale-gettext po4a xz zlib zstd"
BUILDDEP__RETRO="bzip2 diffutils glibc less libmd ncurses patch xz zlib zstd"
BUILDDEP__ARMV4="${BUILDDEP__RETRO}"
BUILDDEP__ARMV6HF="${BUILDDEP__RETRO}"
BUILDDEP__ARMV7HF="${BUILDDEP__RETRO}"
BUILDDEP__I486="${BUILDDEP__RETRO}"
BUILDDEP__LOONGSON2F="${BUILDDEP__RETRO}"
BUILDDEP__M68K="${BUILDDEP__RETRO}"
BUILDDEP__POWERPC="${BUILDDEP__RETRO}"
BUILDDEP__PPC64="${BUILDDEP__RETRO}"
PKGDES="A utility for managing different binary-level alternatives"

# NOTE: use the template to persuade dpkg to use our triples (i486).
ABTYPE=autotools
# Note: Disabling unused dselect, start-stop-daemon.
# Note: Disabling zlib-ng, which is not yet adopted.
# Note: To enable libselinux support in the future.
AUTOTOOLS_AFTER="--enable-nls \
                 --enable-rpath \
                 --disable-dselect \
                 --disable-start-stop-daemon \
                 --enable-update-alternatives \
                 --enable-devel-docs \
                 --disable-coverage \
                 --enable-largefile \
                 --enable-unicode \
                 --disable-mmap \
                 --enable-disk-preallocate \
                 --enable-compiler-warnings \
                 --enable-compiler-optimizations \
                 --enable-linker-optimizations \
                 --with-libz \
                 --without-libz-ng \
                 --with-libbz2 \
                 --with-liblzma \
                 --with-libzstd \
                 --without-libselinux"
AUTOTOOLS_AFTER__RETRO=" \
                 ${AUTOTOOLS_AFTER} \
                 --disable-devel-docs"

PKGCONFL="dpkg<=1.18.2-1"

PKGESS=1

# Needed by Afterglow, whereas FAIL_ARCH defaults to mainline-only.
FAIL_ARCH="!(mainline|retro)"
