Skip to contentSkip to conversation

kvm-85 build problem

PATCH Bernhard Held 1 participant 2 messages Apr 22, 2009 – Apr 24, 2009 KVM

lore
Share & tools
lore
#0 lore raw

Hi,

this happens on CentOS 5.3:

# cd kvm-85/qemu
# make
  CC    qemu-nbd.o
  CC    qemu-tool.o
  CC    osdep.o
  CC    cutils.o
In file included from cutils.c:27:
/usr/include/assert.h: In function ‘qemu_sync_idcache’:
/usr/include/assert.h:70: error: storage class specified for parameter
‘__assert_fail’
/usr/include/assert.h:76: error: storage class specified for parameter
‘__assert_perror_fail’
/usr/include/assert.h:82: error: storage class specified for parameter ‘__assert’
cutils.c:30: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘{’
token
   ...
cutils.c:224: error: expected ‘{’ at end of input
make: *** [cutils.o] Error 1

gcc 4.1.2 doesn't like functions without body, this patch fixes the problem:

cache-utils.h 2009-04-22 08:39:20.000000000 +0200 renamed from cache-utils.h.orig 2009-04-21 10:46:04.000000000 +0200 +2 -0
@@ -47,6 +47,8 @@
 }
 #else
 static inline void qemu_sync_idcache(unsigned long start, unsigned long stop)
+{
+}
 #endif
 
 #define qemu_cache_utils_init(envp) do { (void) (envp); } while (0)

Bernhard

#1 lore raw
Quoted 11 lines
cache-utils.h 2009-04-22 08:39:20.000000000 +0200 renamed from cache-utils.h.orig 2009-04-21 10:46:04.000000000 +0200 +2 -0
@@ -47,6 +47,8 @@
 }
 #else
 static inline void qemu_sync_idcache(unsigned long start, unsigned long 
 stop)
+{
+}
 #endif
 
Quoted 1 line

#define qemu_cache_utils_init(envp) do { (void) (envp); } while (0)

The package kvm-85.tar.gz on sourceforge was broken. The current package doesn't show this problem. It was fixed just 50 minutes after I download the corrupt package.

Thanks anyway,
Bernhard