summaryrefslogtreecommitdiff
path: root/pcr/libreboot-utils/PKGBUILD
diff options
context:
space:
mode:
authorDenis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>2022-05-06 22:04:02 +0200
committerDenis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>2022-05-06 22:07:18 +0200
commit8ca8b108c4a038a04b70ae59a3c238902add196f (patch)
tree3ae0972f8b1e74073b4ef38c7e331eae09d2ef8a /pcr/libreboot-utils/PKGBUILD
parente46f79a38bb86436619c79c1b71ba4d909a0cb10 (diff)
downloadabslibre-8ca8b108c4a038a04b70ae59a3c238902add196f.tar.gz
abslibre-8ca8b108c4a038a04b70ae59a3c238902add196f.tar.bz2
abslibre-8ca8b108c4a038a04b70ae59a3c238902add196f.zip
pcr: libreboot-utils: fix cbfstool compilation on 32bit architectures
On i686, cbfstool wasn't build because it failed to compile, and on armv7h, the build fail with an error similar to this one: host/lib/extract_vmlinuz.c: In function ‘ExtractVmlinuz’: host/lib/extract_vmlinuz.c:67:9: warning: ‘memcpy’ specified bound between 2147483648 and 4294967295 exceeds maximum object size 2147483647 [-Wstringop-overflow=] 67 | memcpy(vmlinuz, kpart_data + vmlinuz_header_offset, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 68 | vmlinuz_header_size); | ~~~~~~~~~~~~~~~~~~~~ This fixes that build error and enables cbfstool to be built on all the architectures supported by Parabola. Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>
Diffstat (limited to 'pcr/libreboot-utils/PKGBUILD')
-rw-r--r--pcr/libreboot-utils/PKGBUILD22
1 files changed, 13 insertions, 9 deletions
diff --git a/pcr/libreboot-utils/PKGBUILD b/pcr/libreboot-utils/PKGBUILD
index d18125a1d..956cffac6 100644
--- a/pcr/libreboot-utils/PKGBUILD
+++ b/pcr/libreboot-utils/PKGBUILD
@@ -4,7 +4,7 @@
# Maintainers: Parabola hackers <dev@lists.parabola.nu>
pkgname=libreboot-utils
-pkgrel=2
+pkgrel=3
_upstream_ver=20211122
pkgver=4.15.libreboot${_upstream_ver}
pkgdesc="Misc. Coreboot/Libreboot utils (bucts, cbfstool, ECtool, nvramtool, superiotool)"
@@ -14,14 +14,22 @@ license=('GPL2')
makedepends=('pciutils')
_mirror="https://mirrors.mit.edu/libreboot" # use a mirror per libreboot's request
-source=(${_mirror}/testing/${_upstream_ver}/libreboot-${_upstream_ver}_src.tar.xz{,.sig})
+source=("${_mirror}/testing/${_upstream_ver}/libreboot-${_upstream_ver}_src.tar.xz"{,.sig}
+ "0001-cbfstool-enable-to-disable-Werror-in-standalone-buil.patch")
sha256sums=('e8a610e51e668c34627a6d9c048c554592fd2c2ab4dbcad83c85c06d132e5ad1'
- '4442fc225383e1edf8f45e1aecba81868ae43db19978f15c17828389364c0434')
+ '4442fc225383e1edf8f45e1aecba81868ae43db19978f15c17828389364c0434'
+ 'SKIP')
sha512sums=('3eac75b33bc6d2874c3ca1ad2392db7287992cf91d37879bb3244dbd6716bc7ffa3f8d31e15d821899e91a55b6fe665d918bea4e9da92e5e98345e9bcbe1bb95'
- '3a532ecef550ef27b723845544e91ff6b13ed6f2f1188d40fdeb7b3c416be619ff58103c3b01cd52ff88c28df6d419d2113b92d0b8ba36d1a74cfc16f70e0e63')
+ '3a532ecef550ef27b723845544e91ff6b13ed6f2f1188d40fdeb7b3c416be619ff58103c3b01cd52ff88c28df6d419d2113b92d0b8ba36d1a74cfc16f70e0e63'
+ 'SKIP')
validpgpkeys=('98CCDDF8E56047F475C044BDD0C62464FA8B4856') # Leah Rowe
prepare() {
+ cd "$srcdir/libreboot-${_upstream_ver}_src/coreboot/default/"
+ patch \
+ -Np1 -i \
+ "${srcdir}/0001-cbfstool-enable-to-disable-Werror-in-standalone-buil.patch"
+
# Replace sbin with bin in the makefiles.
cd "$srcdir/libreboot-${_upstream_ver}_src/coreboot/default/util/bucts/"
sed 's#/sbin#/bin#' -i Makefile
@@ -62,11 +70,7 @@ build() {
fi
# Build cbfstool.
- case "${CARCH}" in
- armv7h) make -C cbfstool;;
- #i686) make -C cbfstool;; #broken
- x86_64) make -C cbfstool;;
- esac
+ make -C cbfstool WERROR=''
# Build ECtool.
make -C ectool
# Build nvramtool.