From 1fc12db95f7c1e353fd9fd4d496946cd17a733a4 Mon Sep 17 00:00:00 2001 From: Maciej Gabryelski Date: Thu, 21 Apr 2022 08:28:01 +0200 Subject: util/superiotool/Makefile: improve cross-compilation support MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Use tool from INSTALL variable to create directory instead of mkdir to be compatible with other cross-compilation buildsystems (like Yocto). Signed-off-by: Maciej Gabryelski Change-Id: I9d455f3d1a6d86c88b8e22da825fe14f9630e971 Reviewed-on: https://review.coreboot.org/c/coreboot/+/70103 Reviewed-by: Michał Żygowski Tested-by: build bot (Jenkins) --- util/superiotool/Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'util/superiotool') diff --git a/util/superiotool/Makefile b/util/superiotool/Makefile index 21bd2bca75..f8c1cc1f86 100644 --- a/util/superiotool/Makefile +++ b/util/superiotool/Makefile @@ -17,7 +17,7 @@ LDFLAGS += -lz OBJS = superiotool.o serverengines.o ali.o exar.o fintek.o ite.o nsc.o \ nuvoton.o smsc.o winbond.o infineon.o aspeed.o -OS_ARCH = $(shell uname) +OS_ARCH ?= $(shell uname) ifeq ($(OS_ARCH), Darwin) LIBS = -framework IOKit -framework DirectHW -lpci -lz endif @@ -54,9 +54,9 @@ $(PROGRAM): $(OBJS) superiotool.h $(CC) $(LDFLAGS) -o $(PROGRAM) $(OBJS) $(LIBS) install: $(PROGRAM) - mkdir -p $(DESTDIR)$(PREFIX)/sbin + $(INSTALL) -d $(DESTDIR)$(PREFIX)/sbin $(INSTALL) $(PROGRAM) $(DESTDIR)$(PREFIX)/sbin - mkdir -p $(DESTDIR)$(PREFIX)/share/man/man8 + $(INSTALL) -d $(DESTDIR)$(PREFIX)/share/man/man8 $(INSTALL) -p -m644 $(PROGRAM).8 $(DESTDIR)$(PREFIX)/share/man/man8 clean: -- cgit v1.2.3