aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorNico Huber <nico.h@gmx.de>2021-04-18 20:50:32 +0200
committerNico Huber <nico.h@gmx.de>2021-06-27 21:11:37 +0000
commit9c0e009f7e7b54d2c394be93180ec80349a83d5a (patch)
treec12bfadc980d7ac963e554a025a8bb5b9e45bc62 /Makefile
parentd0fa8c0408cbc785de2aadbf57b30d941087831a (diff)
downloadflashrom-9c0e009f7e7b54d2c394be93180ec80349a83d5a.tar.gz
flashrom-9c0e009f7e7b54d2c394be93180ec80349a83d5a.tar.bz2
flashrom-9c0e009f7e7b54d2c394be93180ec80349a83d5a.zip
Makefile: Turn x86-arch comments into `if`
Actually check what the comments suggest. Supposed to fix non-x86 on NetBSD and OpenBSD. Change-Id: I440919c12e54ca4371e21bc8d1b5ab64692fb4b8 Signed-off-by: Nico Huber <nico.h@gmx.de> Reviewed-on: https://review.coreboot.org/c/flashrom/+/52486 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile6
1 files changed, 4 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index be6e5516..4d68cdb3 100644
--- a/Makefile
+++ b/Makefile
@@ -1186,12 +1186,14 @@ FEATURE_CFLAGS += -D'NEED_RAW_ACCESS=1'
PROGRAMMER_OBJS += physmap.o hwaccess.o
ifeq ($(TARGET_OS), NetBSD)
-# For (i386|x86_64)_iopl(2).
+ifeq ($(ARCH), x86)
PCILIBS += -l$(shell uname -p)
+endif
else
ifeq ($(TARGET_OS), OpenBSD)
-# For (i386|amd64)_iopl(2).
+ifeq ($(ARCH), x86)
PCILIBS += -l$(shell uname -m)
+endif
else
ifeq ($(TARGET_OS), Darwin)
# DirectHW framework can be found in the DirectHW library.