# Maintainer: Bruno Pagani <archange@archlinux.org>
# Maintainer: Laurent Carlier <lordheavym@gmail.com>
# Contributor: Giovanni Scafora <giovanni@archlinux.org>
# Contributor: Alessio 'mOlOk' Bolognino <themolok@gmail.com>

pkgname=acpica
pkgver=20250404
pkgrel=1
pkgdesc="ACPI tools, including Intel ACPI Source Language compiler"
arch=(x86_64 aarch64)
url="https://acpica.org"
license=(GPL-2.0-only)
depends=(glibc)
makedepends=(flex bison)
provides=(iasl)
conflicts=(iasl)
replaces=(iasl)
options=(!makeflags)
# thanks Intel for making downloading sources so painful...
# https://github.com/acpica/acpica/issues/888
# https://github.com/acpica/acpica/issues/886
# https://github.com/acpica/acpica/issues/883
# https://github.com/acpica/acpica/issues/857
source=(https://github.com/user-attachments/files/19613932/acpica-unix-$pkgver.tar.gz)
sha512sums=('38688493ca42425065b9b05f801e286de02e31ab5313616201ba20d7c7c9c46944ab82d2a46dd1a8b8744f300d940e31be32674573c093fae9fcea0f4a6e699e')
b2sums=('bef538fd06fb232c813736d8a7d3ad1f9d3771591744a673e676cfbd3df5ca4dcdaa478c01449a100bdfa43201523bef737df87b193b4d941d65b85dc9544955')

build() {
  NOWERROR=TRUE make -C $pkgname-unix-$pkgver
}

package() {
  make DESTDIR="$pkgdir" install -C $pkgname-unix-$pkgver
}
