Package: libvirt
Version: 0.4.6-4
User: [EMAIL PROTECTED]
Usertags: ftbfs-gcc-4.4
Tags: patch

Your package fails to build with the upcoming GCC 4.4.  Version 4.4
has not been released yet but I'm building with a snapshot in order
to find errors and give people an advance warning.

GCC 4.4 will introduce better checks in the preprocessor, which made
me found a typo in your code.

You can reproduce this problem with gcc-snapshot from unstable.

> Automatic build of libvirt_0.4.6-4 on em64t by sbuild/amd64 0.53
...
> /bin/sh ../libtool --tag=CC   --mode=compile cc -DHAVE_CONFIG_H -I. -I.. 
> -I../gnulib/lib -I../gnulib/lib -I../include -I../include -I../qemud 
> -I/usr/include/libxml2       -DBINDIR=\""/usr/lib/libvirt"\" 
> -DSBINDIR=\""/usr/sbin"\" -DSYSCONF_DIR="\"/etc\"" 
> -DLOCALEBASEDIR=\""/usr/share/locale"\" -DLOCAL_STATE_DIR=\""/var"\" 
> -DGETTEXT_PACKAGE=\"libvirt\" -Wall -Wformat -Wformat-security 
> -Wmissing-prototypes -Wnested-externs -Wpointer-arith -Wextra -Wshadow 
> -Wcast-align -Wwrite-strings -Waggregate-return -Wstrict-prototypes -Winline 
> -Wredundant-decls -Wno-sign-compare -Wp,-D_FORTIFY_SOURCE=2 -fexceptions 
> -fasynchronous-unwind-tables  -DWITH_QEMU -DWITH_TEST -DWITH_REMOTE 
> -DWITH_LIBVIRTD -DWITH_XEN    -DIN_LIBVIRT -g -O2 -g -Wall -O2 -c -o 
> libvirt_la-xen_internal.lo `test -f 'xen_internal.c' || echo 
> './'`xen_internal.c
>  cc -DHAVE_CONFIG_H -I. -I.. -I../gnulib/lib -I../gnulib/lib -I../include 
> -I../include -I../qemud -I/usr/include/libxml2 -DBINDIR=\"/usr/lib/libvirt\" 
> -DSBINDIR=\"/usr/sbin\" -DSYSCONF_DIR=\"/etc\" 
> -DLOCALEBASEDIR=\"/usr/share/locale\" -DLOCAL_STATE_DIR=\"/var\" 
> -DGETTEXT_PACKAGE=\"libvirt\" -Wall -Wformat -Wformat-security 
> -Wmissing-prototypes -Wnested-externs -Wpointer-arith -Wextra -Wshadow 
> -Wcast-align -Wwrite-strings -Waggregate-return -Wstrict-prototypes -Winline 
> -Wredundant-decls -Wno-sign-compare -Wp,-D_FORTIFY_SOURCE=2 -fexceptions 
> -fasynchronous-unwind-tables -DWITH_QEMU -DWITH_TEST -DWITH_REMOTE 
> -DWITH_LIBVIRTD -DWITH_XEN -DIN_LIBVIRT -g -O2 -g -Wall -O2 -c xen_internal.c 
>  -fPIC -DPIC -o .libs/libvirt_la-xen_internal.o
> xen_internal.c:76:13: error: missing binary operator before token "("
> xen_internal.c:341:13: error: missing binary operator before token "("
> xen_internal.c:351:13: error: missing binary operator before token "("
> xen_internal.c:667:13: error: missing binary operator before token "("
> make[4]: *** [libvirt_la-xen_internal.lo] Error 1
> make[4]: Leaving directory `/build/tbm/libvirt-0.4.6/src'

--- src/xen_internal.c~ 2008-11-13 19:26:46.000000000 +0000
+++ src/xen_internal.c  2008-11-13 19:27:02.000000000 +0000
@@ -73,7 +73,7 @@
 #define XEN_V1_IOCTL_HYPERCALL_CMD                  \
     _IOC(_IOC_NONE, 'P', 0, sizeof(v1_hypercall_t))
 typedef v1_hypercall_t hypercall_t;
-#elif define(__sun__)
+#elif defined(__sun__)
 typedef privcmd_hypercall_t hypercall_t;
 #else
 #error "unsupported platform"
@@ -338,7 +338,7 @@
 {
 #ifdef __linux__
         return (mlock(addr, len));
-#elif define(__sun)
+#elif defined(__sun)
         return (0);
 #endif
 }
@@ -348,7 +348,7 @@
 {
 #ifdef __linux__
         return (munlock(addr, len));
-#elif define(__sun)
+#elif defined(__sun)
         return (0);
 #endif
 }
@@ -664,7 +664,7 @@
 #define XEN_HYPERVISOR_SOCKET  "/proc/xen/privcmd"
 #define HYPERVISOR_CAPABILITIES        
"/sys/hypervisor/properties/capabilities"
 #define CPUINFO                        "/proc/cpuinfo"
-#elif define(__sun__)
+#elif defined(__sun__)
 #define XEN_HYPERVISOR_SOCKET  "/dev/xen/privcmd"
 #define HYPERVISOR_CAPABILITIES        ""
 #define CPUINFO                        "/dev/cpu/self/cpuid"
--- src/xs_internal.c~  2008-11-13 19:28:01.000000000 +0000
+++ src/xs_internal.c   2008-11-13 19:28:06.000000000 +0000
@@ -34,7 +34,7 @@
 
 #ifdef __linux__
 #define XEN_HYPERVISOR_SOCKET "/proc/xen/privcmd"
-#elif define(__sun__)
+#elif defined(__sun__)
 #define XEN_HYPERVISOR_SOCKET "/dev/xen/privcmd"
 #else
 #error "unsupported platform"

-- 
Martin Michlmayr
http://www.cyrius.com/



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to