# Maintainer: Alexander Baldeck <alex.bldck@gmail.com>
pkgname=powerpc-utils
pkgver=1.3.8
pkgrel=1
pkgdesc="Contains utilities which are intended for maintenance of IBM powerpc platforms"
arch=(powerpc64le powerpc64 powerpc)
url="https://github.com/ibm-power-utilities/powerpc-utils"
license=('GPL')
depends=(librtas)
makedepends=(git)
source=("${pkgname}-${pkgver}::git+https://github.com/ibm-power-utilities/powerpc-utils.git?#tag=v${pkgver}")
md5sums=('SKIP')

prepare() {
	cd "$srcdir/${pkgname}-${pkgver}"
	sh autogen.sh
}

build() {
	cd "$srcdir/${pkgname}-${pkgver}"
	./configure --prefix=/usr \
                    --sbindir=/usr/bin \
		    --with-systemd=/usr/lib/systemd/system \
		    --disable-werror
	make
}

check() {
	cd "$srcdir/${pkgname}-${pkgver}"
	make -k check
}

package() {
	cd "$srcdir/${pkgname}-${pkgver}"
	make DESTDIR="$pkgdir/" install
}
