summaryrefslogtreecommitdiff
path: root/pcr/coreboot-util/PKGBUILD
blob: ff26ebef029873a470638700dc29c1e31013b2b0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
# Maintainer: Wael Karram <wael@waelk.tech>

pkgname=coreboot-util
pkgver=4.15
pkgrel=1
pkgdesc="Misc utils from the coreboot project"
url="https://review.coreboot.org/util/ectool"
arch=('x86_64' 'i686' 'armv7h')
license=('GPL2')
makedepends=('pciutils')
source=("coreboot-${pkgver}.tar.gz::https://coreboot.org/releases/coreboot-${pkgver}.tar.xz")
sha256sums=('20e6aaa6dd0eaec7753441c799711d1b4630e3ca709536386f2242ac2c8a1ec5')

build() {
	cd coreboot-${pkgver}/util

	# Build ectool.
	make -C ectool
	# Build cbfstool.
	make -C cbfstool
	# Build nvramtool.
	make -C nvramtool
	# Build superiotool.
	make -C superiotool
	# Build cbmem.
	make -C cbmem
}

package() {
	cd coreboot-${pkgver}/util

	# Install ectool in /usr/bin.
	install -Dm755 ectool/ectool "${pkgdir}"/usr/bin/ectool
	# Install cbfstool and rmodtool in /usr/bin.
	install -Dm755 cbfstool/cbfstool "${pkgdir}"/usr/bin/cbfstool
	install -Dm755 cbfstool/rmodtool "${pkgdir}"/usr/bin/rmodtool
	# Install nvramtool in /usr/bin.
	install -Dm755 nvramtool/nvramtool "${pkgdir}"/usr/bin/nvramtool
	# Install superiotool in /usr/bin.
	install -Dm755 superiotool/superiotool "${pkgdir}"/usr/bin/superiotool
	# Install cbmem in /usr/bin.
	install -Dm755 cbmem/cbmem "${pkgdir}"/usr/bin/cbmem
}