mirror of
https://github.com/rhboot/gnu-efi
synced 2026-08-26 00:26:04 -04:00
If CROSS_COMPILE is set, ignore the ARCH value supplied on the
command line and use the target machine of the cross compiler. Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Nigel Croxon <nigel.croxon@hp.com>
This commit is contained in:
parent
d32fb84543
commit
370cce41da
1 changed files with 6 additions and 1 deletions
|
|
@ -63,7 +63,12 @@ OBJCOPY := $(prefix)$(CROSS_COMPILE)objcopy
|
|||
# Host/target identification
|
||||
OS := $(shell uname -s)
|
||||
HOSTARCH := $(shell $(HOSTCC) -dumpmachine | cut -f1 -d- | sed s,i[3456789]86,ia32,)
|
||||
ARCH := $(shell $(CC) -dumpmachine | cut -f1 -d-| sed s,i[3456789]86,ia32,)
|
||||
ARCH := $(HOSTARCH)
|
||||
|
||||
# Get ARCH from the compiler if cross compiling
|
||||
ifneq ($(CROSS_COMPILE),)
|
||||
override ARCH := $(shell $(CC) -dumpmachine | cut -f1 -d-| sed s,i[3456789]86,ia32,)
|
||||
endif
|
||||
|
||||
# FreeBSD (and possibly others) reports amd64 instead of x86_64
|
||||
ifeq ($(ARCH),amd64)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue