# Maintainer: Jan Alexander Steffens (heftig) <heftig@archlinux.org>
# Maintainer: Laurent Carlier <lordheavym@archlinux.org>
# Contributor: Cyano Hao <c@cyano.cn>

pkgname=directx-headers
pkgver=1.618.2
pkgrel=1
pkgdesc="DirectX headers for using D3D12"
url="https://github.com/microsoft/DirectX-Headers"
arch=(x86_64 aarch64)
license=(MIT)
depends=()
makedepends=(
  git
  meson
)
options=(!lto)
source=("directx-headers::git+$url#tag=v$pkgver")
b2sums=('1754ac0b9302f6850401847f2369ab5e082d0320336d3f77790d1f28c18113011b7a21f12e739b2f568c58378d6a3a32c77e0d9db73927e61e91abd989f59140')

build() {
  local meson_options=(
    -D build-test=false
  )

  arch-meson directx-headers build "${meson_options[@]}"
  meson compile -C build
}

package() {
  meson install -C build --destdir "$pkgdir"

  install -Dm644 directx-headers/LICENSE \
    -t "$pkgdir/usr/share/licenses/$pkgname"
}

# vim:set sw=2 sts=-1 et:
