From fc228313f496af9a49ae9a56f6c0b9dbbb1a39ca Mon Sep 17 00:00:00 2001 From: Daniel Bevenius Date: Mon, 27 Aug 2018 08:14:02 +0200 Subject: [PATCH 1/2] build: use arm64 as DESTCPU for aarch64 On a `aarch64` system I can run the complete build with tests without specifying the Makefile variable `DESTCPU`. But when running the `tar-headers` target `DESTCPU` is passed to configure: ```shell $(PYTHON) ./configure \ --prefix=/ \ --dest-cpu=$(DESTCPU) \ ... ``` The value of `DESTCPU` in this case will be 'aarch64' which will cause configure to fail: ```shell configure: error: option --dest-cpu: invalid choice: 'aarch64' (choose from 'arm', 'arm64', 'ia32', 'mips', 'mipsel', 'mips64el', 'ppc', 'ppc64', 'x32', 'x64', 'x86', 'x86_64', 's390', 's390x') ``` In the configure script there is a matching of `__aarch64__` to `arm64`: ```shell $ python -c 'from configure import host_arch_cc; print host_arch_cc()' arm64 ``` In our case it would be nice to have consitent behaviour for both of these cases on `aarch64`. This commit changes `DESTCPU` to `arm64` to be consistent with the configure script. `DESTCPU` is used in `$(TARBALL)-headers` and in `$(BINARYTAR)` but I'm not sure about the implications of making the change purposed and hope others might chime in and provide some guidance. --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 2452244fc25967..6631d9a7ec225f 100644 --- a/Makefile +++ b/Makefile @@ -726,7 +726,7 @@ ifeq ($(findstring arm,$(UNAME_M)),arm) DESTCPU ?= arm else ifeq ($(findstring aarch64,$(UNAME_M)),aarch64) -DESTCPU ?= aarch64 +DESTCPU ?= arm64 else ifeq ($(findstring powerpc,$(shell uname -p)),powerpc) DESTCPU ?= ppc64 From 1dedf3f0d1645271b45d829b457ed01fe2c8f38c Mon Sep 17 00:00:00 2001 From: Daniel Bevenius Date: Fri, 31 Aug 2018 05:33:57 +0200 Subject: [PATCH 2/2] squash: update DESTCPU check for ARCH setting --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 6631d9a7ec225f..f818daed6609bb 100644 --- a/Makefile +++ b/Makefile @@ -746,7 +746,7 @@ else ifeq ($(DESTCPU),arm) ARCH=arm else -ifeq ($(DESTCPU),aarch64) +ifeq ($(DESTCPU),arm64) ARCH=arm64 else ifeq ($(DESTCPU),ppc64)