# POWER Maintainer: Alexander Baldeck <alex.bldck@gmail.com>
# Maintainer : Laurent Carlier <lordheavym@gmail.com>
# Contributor: Giovanni Scafora <giovanni@archlinux.org>
# Contributor: Alessio 'mOlOk' Bolognino <themolok@gmail.com>

pkgname=iasl
pkgver=20240927
pkgrel=1
pkgdesc="Intel ACPI Source Language compiler"
arch=(x86_64 powerpc64le)
url="http://acpica.org"
license=('custom')
depends=('glibc')
makedepends=('flex' 'bison' 'git')
options=('!makeflags')
source=("git+https://github.com/acpica/acpica.git#tag=R09_27_24"
	LICENSE)
sha256sums=('083de55bb99d0ca6cd41795ecc43aef62fb80b6d444b18c6210073f6fe2a779a'
            'a8eeb8c94b709f91be8575c229cc1df7f8aacb018224b23b0ab6f833a7f18591')

build() {
  cd ${srcdir}/acpica/generate/unix

  #sed -i -e 's/_CYGWIN/_LINUX/g' -e 's/-Werror//g' Makefile.config

  make clean
  make
}

package() {
  cd ${srcdir}/acpica/generate/unix

  make DESTDIR=${pkgdir} install

  install -D -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}
