

_realname=EGL-Registry
_name=egl-headers
_specver=1.5
pkgbase=mingw-w64-${_name}
pkgname="${MINGW_PACKAGE_PREFIX}-${_name}"
pkgver=1.5.r284.3ae2b7c
pkgrel=1
_commit=3ae2b7c48690d2ce13cc6db3db02dfc0572be65e
pkgdesc="EGL header files (mingw-w64)"
arch=('any')
mingw_arch=('mingw32' 'mingw64' 'ucrt64' 'clang64' 'clangarm64')
url="https://registry.khronos.org/EGL/"
msys2_repository_url="https://github.com/KhronosGroup/EGL-Registry"
license=('spdx:Apache-2.0')
depends=()
makedepends=("git")
source=("git+https://github.com/KhronosGroup/EGL-Registry.git#commit=$_commit")
sha256sums=('SKIP')

pkgver() {
  cd ${_realname}
  printf "${_specver}.r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short=7 HEAD)"
}

package() {
  cd "${srcdir}"/${_realname}/api

  install -d "${pkgdir}"${MINGW_PREFIX}/include/EGL
  install -Dm644 "${srcdir}"/${_realname}/api/EGL/* "${pkgdir}"${MINGW_PREFIX}/include/EGL
}
