# Maintainer: Maxime Gauduin <alucryd@archlinux.org>

pkgname=libretro-beetle-pce-fast
pkgver=1139
pkgrel=1
pkgdesc='NEC PC Engine/CD core'
arch=(x86_64)
url=https://github.com/libretro/beetle-pce-fast-libretro
license=(GPL2)
groups=(libretro)
depends=(
  gcc-libs
  glibc
  libretro-core-info
  zlib
)
makedepends=(git)
_commit=c186838c875fe3633efe5c4fc4d5b74f84b07140
source=(libretro-beetle-pce-fast::git+https://github.com/libretro/beetle-pce-fast-libretro.git#commit=${_commit})
sha256sums=(SKIP)

pkgver() {
  cd libretro-beetle-pce-fast

  git rev-list --count HEAD
}

build() {
  make \
    SYSTEM_LIBCHDR=0 \
    SYSTEM_ZLIB=1 \
    -C libretro-beetle-pce-fast
}

package() {
  install -Dm 644 libretro-beetle-pce-fast/mednafen_pce_fast_libretro.so -t "${pkgdir}"/usr/lib/libretro/
}

# vim: ts=2 sw=2 et:
