From 2aac13f095f20fefdc83c79ce2ce3354fb5b816a Mon Sep 17 00:00:00 2001 From: Arnaud Brousseau Date: Wed, 3 May 2023 15:04:10 -0500 Subject: [PATCH] Normalize HOST_ARCH --- Makefile | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 6a1f0cb..8ea4c95 100644 --- a/Makefile +++ b/Makefile @@ -4,8 +4,11 @@ altarch = $(subst x86_64,amd64,$(subst aarch64,arm64,$1)) DEFAULT_GOAL := $(or $(DEFAULT_GOAL),toolchain) ARCH := $(or $(ARCH),x86_64) TARGET := $(or $(TARGET),$(ARCH)) -HOST_ARCH := $(call lc,$(shell uname -m)) + +normarch = $(subst arm64,aarch64,$(subst amd64,x86_64,$1)) +HOST_ARCH := $(call normarch,$(call lc,$(shell uname -m))) HOST_ARCH_ALT := $(call altarch,$(HOST_ARCH)) + HOST_OS := $(call lc,$(shell uname -s)) PLATFORM := $(or $(PLATFORM),linux) NAME := $(shell basename $(shell git rev-parse --show-toplevel | tr A-Z a-z ))