# Maintainer: Fabien Chouteau <chouteau@adacore.com>

_realname=gnat_util
pkgbase=mingw-w64-${_realname}
pkgname=${MINGW_PACKAGE_PREFIX}-${_realname}
pkgver=2020.0.0
pkgrel=1
_srcpkgid='20.0w-20190814-1532A'

pkgdesc="Internal GNAT compiler components (mingw-w64)"
arch=('any')
mingw_arch=('mingw32' 'mingw64' 'ucrt64' 'clang64')
license=('GPL3')
url="https://adacore.com"
makedepends=("${MINGW_PACKAGE_PREFIX}-gcc-ada"
             "${MINGW_PACKAGE_PREFIX}-gprbuild")
source=("gnat_util-${_srcpkgid}-src.tar.gz::https://community.download.adacore.com/v1/26bd253101b46706f5f8e3d0ca8b3107cde99e99?filename")
sha256sums=('80019dfb0b244d2cd848d13c9ad5a222d9df2fc7157e235b9ef219a9c180c175')

build() {
  cd "${srcdir}/gnat_util-${_srcpkgid}-src/"
  make all
}

package() {
  cd "${srcdir}/gnat_util-${_srcpkgid}-src/"
  make install prefix="${pkgdir}${MINGW_PREFIX}"
}
