Move HOST_ARCH declaration to common.mak

In addition, add the ability that a Makefile that includes `common.mak`
can specify the `HOST_ARCH`. Usage example:

$S390_TOOLS/mytool/Makefile:
``` Makefile
HOST_ARCH := s390x
include ../common.mak
```

Reviewed-by: Steffen Eiden <seiden@linux.ibm.com>
Reviewed-by: Jan Höppner <hoeppner@linux.ibm.com>
Signed-off-by: Marc Hartmayer <mhartmay@linux.ibm.com>
Signed-off-by: Steffen Eiden <seiden@linux.ibm.com>
This commit is contained in:
Marc Hartmayer
2023-01-24 13:10:47 +00:00
committed by Steffen Eiden
parent 0c1a5069d9
commit 686fca1863
2 changed files with 2 additions and 2 deletions

View File

@@ -12,6 +12,8 @@ MAKECMDGOALS ?=
ifeq ($(COMMON_INCLUDED),false)
COMMON_INCLUDED := true
HOST_ARCH ?= $(shell uname -m | sed -e 's/i.86/i386/' -e 's/sun4u/sparc64/' -e 's/arm.*/arm/' -e 's/sa110/arm/')
# Global definitions
# The variable "DISTRELEASE" should be overwritten in rpm spec files with:
# "make DISTRELEASE=%{release}" and "make install DISTRELEASE=%{release}"