# Description: 8086 assembler and loader which can generate 32-bit code for the 386+ processors
# URL:         https://github.com/lkundrak/dev86/tree/master/bin86
# Maintainer:  CRUX System Team, core-ports at crux dot nu

name=bin86
version=0.16.21
release=1
source=(https://mirror.netcologne.de/gentoo/distfiles/$name-$version.tar.gz \
        $name-x86_64.patch)

build() {
    cd $name-$version
    patch -p1 -i $SRC/$name-x86_64.patch
    make -j1 CFLAGS="$CFLAGS -D_POSIX_SOURCE" PREFIX=/usr
    install -d $PKG/usr/{bin,share/man/man1}
    make PREFIX=$PKG/usr MANDIR=$PKG/usr/share/man/man1 install
}