Unify target_cpu handling

Over the years several slightly different approaches were used
in the Makefiles to determine the target architecture.  This
change updates both the build system and Makefile to handle
this in a consistent fashion.

TARGET_CPU is set to i386, x86_64, powerpc, aarch6 or sparc64
and made available in the Makefiles to be used as appropriate.

Reviewed-by: Ryan Moeller <ryan@ixsystems.com>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #9848
This commit is contained in:
Brian Behlendorf
2020-01-17 12:40:09 -08:00
committed by GitHub
parent e5030fbc28
commit 70835c5b75
8 changed files with 61 additions and 63 deletions
+1 -3
View File
@@ -3,9 +3,7 @@
#
# Suppress unused-value warnings in sparc64 architecture headers
ifeq ($(target_cpu),sparc64)
ccflags-y += -Wno-unused-value
endif
ccflags-$(CONFIG_SPARC64) += -Wno-unused-value
ccflags-y += -I@abs_top_srcdir@/module/os/linux/zfs