]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
kvm tools: Fix compilation on x86_64
authorPaul Bolle <pebolle@tiscali.nl>
Thu, 31 Mar 2011 20:33:02 +0000 (22:33 +0200)
committerPekka Enberg <penberg@kernel.org>
Fri, 1 Apr 2011 04:14:31 +0000 (07:14 +0300)
Compilation on x86_64 failed with:
[...]
In file included from /usr/include/features.h:386:0,
                 from /usr/include/stdint.h:26,
                 from
/usr/lib/gcc/x86_64-redhat-linux/4.5.1/include/stdint.h:3,
                 from include/kvm/e820.h:4,
                 from bios/e820.c:1:
/usr/include/gnu/stubs.h:7:27: fatal error: gnu/stubs-32.h: No such file
or directory
compilation terminated.
make: *** [bios/bios-rom.bin] Error 1

This is caused by a typo in the Makefile and because gnu/stubs.h (and
friends) expect to see __x86_64__. That's trivial to fix.

Acked-by: Cyrill Gorcunov <gorcunov@gmail.com>
Signed-off-by: Paul Bolle <pebolle@tiscali.nl>
Signed-off-by: Pekka Enberg <penberg@kernel.org>
tools/kvm/Makefile

index bfb3deedd76b4c343fab1444b646fd7d7d72b7fa..b2aecc1cc253dc99dbc1923d85961154a7d7987d 100644 (file)
@@ -36,9 +36,9 @@ LIBS  += -lrt
 uname_M      := $(shell uname -m | sed -e s/i.86/i386/)
 ifeq ($(uname_M),i386)
        DEFINES      += -DCONFIG_X86_32
-ifeq ($(uname_M),x86_64)
-       DEFINES      += -DCONFIG_X86_64
 endif
+ifeq ($(uname_M),x86_64)
+       DEFINES      += -DCONFIG_X86_64 -D__x86_64__
 endif
 
 DEFINES        += -D_FILE_OFFSET_BITS=64