Thomas Heijligen has submitted this change. ( https://review.coreboot.org/c/flashrom/+/67311 )
(
4 is the latest approved patch-set. No files were changed between the latest approved patch-set and the submitted one. )Change subject: tests: Guard Linux-specific linux/spidev.h header file ......................................................................
tests: Guard Linux-specific linux/spidev.h header file
This allows unit tests to build on non-Linux platforms.
BUG=b:237606255 TEST=unit tests compile on two environments: 1) FreeBSD 13.1-RELEASE-p2 GENERIC amd64 2) Debian 5.17.11 x86_64 GNU/Linux
Change-Id: Icdb1b0cb29c5d62187153788ad5e0e631e8d0b62 TICKET: https://ticket.coreboot.org/issues/411 Signed-off-by: Anastasia Klimchuk aklm@chromium.org Reviewed-on: https://review.coreboot.org/c/flashrom/+/67311 Reviewed-by: Angel Pons th3fanbus@gmail.com Reviewed-by: Felix Singer felixsinger@posteo.net Reviewed-by: Thomas Heijligen src@posteo.de Tested-by: build bot (Jenkins) no-reply@coreboot.org --- M tests/lifecycle.h 1 file changed, 25 insertions(+), 0 deletions(-)
Approvals: build bot (Jenkins): Verified Felix Singer: Looks good to me, approved Thomas Heijligen: Looks good to me, approved Angel Pons: Looks good to me, approved
diff --git a/tests/lifecycle.h b/tests/lifecycle.h index 1379f7d..69f1119 100644 --- a/tests/lifecycle.h +++ b/tests/lifecycle.h @@ -18,7 +18,9 @@
#include <include/test.h> #include <string.h> +#if defined(__linux__) && !defined(__ANDROID__) #include <linux/spi/spidev.h> +#endif
#include "tests.h" #include "libflashrom.h"