]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
kvm tools: Cleanup ARCH & uname_M in Makefile
authorMichael Ellerman <michael@ellerman.id.au>
Wed, 4 Jul 2012 13:18:58 +0000 (23:18 +1000)
committerPekka Enberg <penberg@kernel.org>
Wed, 4 Jul 2012 14:12:20 +0000 (17:12 +0300)
The sed expression for ARCH seems to have been cribbed from the top-level
kernel Makefile, and includes lots of architectures kvmtool doesn't
support - strip it down.

Also call uname -m directly there and get rid of uname_M.

Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
Signed-off-by: Pekka Enberg <penberg@kernel.org>
tools/kvm/Makefile

index 501387b5c0930f5a128b4fcaf352e934cac7ff43..f9e1ec19264047c2abd306406b3808250865cf7c 100644 (file)
@@ -90,14 +90,9 @@ OBJS += kvm-ipc.o
 OBJS   += builtin-sandbox.o
 OBJS   += virtio/mmio.o
 
-# Additional ARCH settings for x86
-ARCH ?= $(shell echo $(uname_M) | sed -e s/i.86/i386/ -e s/sun4u/sparc64/ \
-                  -e s/arm.*/arm/ -e s/sa110/arm/ \
-                  -e s/s390x/s390/ -e s/parisc64/parisc/ \
-                  -e s/ppc.*/powerpc/ -e s/mips.*/mips/ \
-                  -e s/sh[234].*/sh/ )
-
-uname_M      := $(shell uname -m | sed -e s/i.86/i386/)
+# Translate uname -m into ARCH string
+ARCH ?= $(shell uname -m | sed -e s/i.86/i386/ -e s/ppc.*/powerpc/)
+
 ifeq ($(ARCH),i386)
        ARCH         := x86
        DEFINES      += -DCONFIG_X86_32