From b634b5c253cb3351eb074c64be838f72aa83f54d Mon Sep 17 00:00:00 2001 From: Kei Kebreau Date: Sun, 30 Dec 2018 09:46:29 -0500 Subject: gnu: vboot-utils: Fix building on armhf-linux. * gnu/packages/bootloaders.scm (vboot-utils)[source]: Add patches. [arguments]: Conditionally add "HOST_ARCH=arm" to #:make-flags. * gnu/packages/patches/vboot-utils-fix-format-load-address.patch, gnu/packages/patches/vboot-utils-fix-tests-show-contents.patch, gnu/packages/patches/vboot-utils-skip-test-workbuf.patch: New files. * gnu/local.mk (dist_patch_DATA): Add them. --- gnu/packages/bootloaders.scm | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) (limited to 'gnu/packages/bootloaders.scm') diff --git a/gnu/packages/bootloaders.scm b/gnu/packages/bootloaders.scm index 2a595fafab..69b4a904be 100644 --- a/gnu/packages/bootloaders.scm +++ b/gnu/packages/bootloaders.scm @@ -673,10 +673,25 @@ board-independent tools."))) (file-name (string-append name "-" version "-checkout")) (sha256 (base32 - "0h0m3l69vp9dr6xrs1p6y7ilkq3jq8jraw2z20kqfv7lvc9l1lxj")))) + "0h0m3l69vp9dr6xrs1p6y7ilkq3jq8jraw2z20kqfv7lvc9l1lxj")) + (patches + (search-patches "vboot-utils-skip-test-workbuf.patch" + "vboot-utils-fix-tests-show-contents.patch" + "vboot-utils-fix-format-load-address.patch")))) (build-system gnu-build-system) (arguments `(#:make-flags (list "CC=gcc" + ;; On ARM, we must pass "HOST_ARCH=arm" so that the + ;; ${HOST_ARCH} and ${ARCH} variables in the makefile + ;; match. Otherwise, ${HOST_ARCH} will be assigned + ;; "armv7l", the value of `uname -m`, and will not + ;; match ${ARCH}, which will make the tests require + ;; QEMU for testing. + ,@(if (string-prefix? "arm" + (or (%current-target-system) + (%current-system))) + '("HOST_ARCH=arm") + '()) (string-append "DESTDIR=" (assoc-ref %outputs "out"))) #:phases (modify-phases %standard-phases (add-after 'unpack 'patch-hard-coded-paths -- cgit v1.2.3