NAME="oniguruma"
DESC="Regular expressions library"
VERSION="6.9.9"
FILES=("https://github.com/kkos/oniguruma/releases/download/v$VERSION/onig-$VERSION.tar.gz")
HASHES=("60162bd3b9fc6f4886d4c7a07925ffd374167732f55dce8c491bfd9cd818a6cf")
DEPENDS=()

PACKAGE() {
  tar xf onig-$VERSION.tar.gz
  cd onig-$VERSION

  ./configure --prefix=/usr --enable-posix-api
  make && make DESTDIR="$ROOTDIR" install

  mkdir -pv "$ROOTDIR/usr/share/doc"
  cp -r doc "$ROOTDIR/usr/share/doc/oniguruma"

  cd .. && rm -r onig-$VERSION
}
