75 lines
2.0 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Contributor: Nulo <alpine@nulo.in>
# Maintainer: Adam Thiede <me@adamthiede.com>
pkgname=coreboot-tools
pkgver=4.21
pkgrel=1
pkgdesc="Tools from the coreboot project"
url="https://review.coreboot.org/coreboot"
# coreboot only runs on x86_64 and x86 systems
arch="x86 x86_64"
license="GPL-2.0-only"
# All specified dependencies are just for configurator subpackage.
# Everything else builds with default tooling.
makedepends="
inkscape
meson
qt5-qtbase-dev
qt5-qttools-dev
qt5-qtsvg-dev
yaml-cpp-dev
"
subpackages="$pkgname-ectool $pkgname-nvramtool $pkgname-nvramtool-doc:nvramtool_doc:noarch $pkgname-ifdtool $pkgname-configurator"
source="https://coreboot.org/releases/coreboot-$pkgver.tar.xz"
builddir="$srcdir/coreboot-$pkgver"
options="!check" # no test suite
build() {
make -e -C util/ectool
make -e -C util/nvramtool CFLAGS="$CFLAGS -I. -DCMOS_HAL=1"
make -e -C util/ifdtool
abuild-meson -Db_lto=true util/coreboot-configurator util/coreboot-configurator/output
meson compile -C util/coreboot-configurator/output
}
package() {
make -e -C util/ectool PREFIX="$pkgdir/usr" install
make -e -C util/nvramtool PREFIX="$pkgdir/usr" install
make -e -C util/ifdtool PREFIX="$pkgdir/usr" install
}
nvramtool() {
pkgdesc="Manipulates NVRAM from userspace"
amove usr/sbin/nvramtool
}
nvramtool_doc() {
pkgdesc="Manipulates NVRAM from userspace (documentation)"
install_if="$pkgname-nvramtool=$pkgver-r$pkgrel docs"
amove usr/share/man/man8/nvramtool*
gzip -9n "$subpkgdir"/usr/share/man/man8/*
}
ectool() {
pkgdesc="Dumps the RAM of a laptops Embedded/Environmental Controller (EC)"
amove usr/sbin/ectool
}
ifdtool() {
pkgdesc="Extract and dump Intel Firmware Descriptor information"
amove usr/bin/ifdtool
}
configurator() {
pkgdesc="Graphical NVRAMtool frontend"
DESTDIR="$subpkgdir" meson install --no-rebuild -C $builddir/util/coreboot-configurator/output
}
sha512sums="
cbaa8700b7e2196209ab495aee2dc347cc9f346f8480e26f6cd75c2792778a46df028417b0be5ad5ca7c4417b5379fd600a5ba12544b4f1a2720c4a86971a520 coreboot-4.21.tar.xz
"