* [PATCH] xen: build fix with gcc 4.5
@ 2012-01-05 15:30 Christoph Egger
2012-01-05 15:39 ` Keir Fraser
2012-01-05 15:48 ` Christoph Egger
0 siblings, 2 replies; 3+ messages in thread
From: Christoph Egger @ 2012-01-05 15:30 UTC (permalink / raw)
To: xen-devel@lists.xensource.com
[-- Attachment #1: Type: text/plain, Size: 484 bytes --]
Fix build failure with gcc 4.5:
implicit declaration of __builtin_stdarg_start
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
From: David Brownlee <abs@netbsd.org>
Please also apply this to xen-4.1-testing.
--
---to satisfy European Law for business letters:
Advanced Micro Devices GmbH
Einsteinring 24, 85689 Dornach b. Muenchen
Geschaeftsfuehrer: Alberto Bozzo, Andrew Bowd
Sitz: Dornach, Gemeinde Aschheim, Landkreis Muenchen
Registergericht Muenchen, HRB Nr. 43632
[-- Attachment #2: xen_stdarg.diff --]
[-- Type: text/plain, Size: 914 bytes --]
diff -r 9a84303b600c xen/include/xen/stdarg.h
--- a/xen/include/xen/stdarg.h Thu Jan 05 14:46:28 2012 +0100
+++ b/xen/include/xen/stdarg.h Thu Jan 05 16:15:47 2012 +0100
@@ -5,7 +5,17 @@
# include "/usr/include/stdarg.h"
#elif defined (__NetBSD__)
typedef __builtin_va_list va_list;
-# define va_start(ap, last) __builtin_stdarg_start((ap), (last))
+# ifdef __GNUC__
+# define __GNUC_PREREQ__(x, y) \
+ ((__GNUC__ == (x) && __GNUC_MINOR__ >= (y)) || \
+ (__GNUC__ > (x)))
+# else
+# define __GNUC_PREREQ__(x, y) 0
+# endif
+# if !__GNUC_PREREQ__(4, 5)
+# define __builtin_va_start(ap, last) __builtin_stdarg_start((ap), (last))
+# endif
+# define va_start(ap, last) __builtin_va_start((ap), (last))
# define va_end(ap) __builtin_va_end(ap)
# define va_arg __builtin_va_arg
#else
[-- Attachment #3: Type: text/plain, Size: 138 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] xen: build fix with gcc 4.5
2012-01-05 15:30 [PATCH] xen: build fix with gcc 4.5 Christoph Egger
@ 2012-01-05 15:39 ` Keir Fraser
2012-01-05 15:48 ` Christoph Egger
1 sibling, 0 replies; 3+ messages in thread
From: Keir Fraser @ 2012-01-05 15:39 UTC (permalink / raw)
To: Christoph Egger, xen-devel@lists.xensource.com
On 05/01/2012 15:30, "Christoph Egger" <Christoph.Egger@amd.com> wrote:
>
> Fix build failure with gcc 4.5:
> implicit declaration of __builtin_stdarg_start
>
> Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
> From: David Brownlee <abs@netbsd.org>
Can you please put netbsd in the comment header for netbsd-specific changes?
-- Keir
> Please also apply this to xen-4.1-testing.
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH] xen: build fix with gcc 4.5
2012-01-05 15:30 [PATCH] xen: build fix with gcc 4.5 Christoph Egger
2012-01-05 15:39 ` Keir Fraser
@ 2012-01-05 15:48 ` Christoph Egger
1 sibling, 0 replies; 3+ messages in thread
From: Christoph Egger @ 2012-01-05 15:48 UTC (permalink / raw)
To: xen-devel@lists.xensource.com
[-- Attachment #1: Type: text/plain, Size: 493 bytes --]
Fix build failure with gcc 4.5 on NetBSD:
implicit declaration of __builtin_stdarg_start
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
From: David Brownlee <abs@netbsd.org>
Please also apply this to xen-4.1-testing.
--
---to satisfy European Law for business letters:
Advanced Micro Devices GmbH
Einsteinring 24, 85689 Dornach b. Muenchen
Geschaeftsfuehrer: Alberto Bozzo, Andrew Bowd
Sitz: Dornach, Gemeinde Aschheim, Landkreis Muenchen
Registergericht Muenchen, HRB Nr. 43632
[-- Attachment #2: xen_stdarg.diff --]
[-- Type: text/plain, Size: 914 bytes --]
diff -r 9a84303b600c xen/include/xen/stdarg.h
--- a/xen/include/xen/stdarg.h Thu Jan 05 14:46:28 2012 +0100
+++ b/xen/include/xen/stdarg.h Thu Jan 05 16:15:47 2012 +0100
@@ -5,7 +5,17 @@
# include "/usr/include/stdarg.h"
#elif defined (__NetBSD__)
typedef __builtin_va_list va_list;
-# define va_start(ap, last) __builtin_stdarg_start((ap), (last))
+# ifdef __GNUC__
+# define __GNUC_PREREQ__(x, y) \
+ ((__GNUC__ == (x) && __GNUC_MINOR__ >= (y)) || \
+ (__GNUC__ > (x)))
+# else
+# define __GNUC_PREREQ__(x, y) 0
+# endif
+# if !__GNUC_PREREQ__(4, 5)
+# define __builtin_va_start(ap, last) __builtin_stdarg_start((ap), (last))
+# endif
+# define va_start(ap, last) __builtin_va_start((ap), (last))
# define va_end(ap) __builtin_va_end(ap)
# define va_arg __builtin_va_arg
#else
[-- Attachment #3: Type: text/plain, Size: 138 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2012-01-05 15:48 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-01-05 15:30 [PATCH] xen: build fix with gcc 4.5 Christoph Egger
2012-01-05 15:39 ` Keir Fraser
2012-01-05 15:48 ` Christoph Egger
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).