From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christoph Egger Subject: [PATCH] xen: build fix with gcc 4.5 Date: Thu, 5 Jan 2012 16:30:04 +0100 Message-ID: <4F05C1FC.2090803@amd.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------010801080300090401060904" Return-path: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: "xen-devel@lists.xensource.com" List-Id: xen-devel@lists.xenproject.org --------------010801080300090401060904 Content-Type: text/plain; charset="ISO-8859-15"; format=flowed Content-Transfer-Encoding: 7bit Fix build failure with gcc 4.5: implicit declaration of __builtin_stdarg_start Signed-off-by: Christoph Egger From: David Brownlee 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 --------------010801080300090401060904 Content-Type: text/plain; name="xen_stdarg.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="xen_stdarg.diff" Content-Description: xen_stdarg.diff 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 --------------010801080300090401060904 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel --------------010801080300090401060904--