Date: Tue, 28 Dec 2004 15:26:48 -0800 From: Peter Wemm <peter@wemm.org> To: Archie Cobbs <archie@dellroad.org> Cc: freebsd-amd64@freebsd.org Subject: Re: mpd@amd64 Message-ID: <200412281526.48335.peter@wemm.org> In-Reply-To: <41D1E0B2.3020500@dellroad.org> References: <1936407230.20041214120051@bk.ru> <200412281432.56309.peter@wemm.org> <41D1E0B2.3020500@dellroad.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tuesday 28 December 2004 02:39 pm, Archie Cobbs wrote: > Peter Wemm wrote: > >>Attached is a slightly different patch. This is against the source > >>currently in ports, and it fixes two additional questionable uses > >> of va_start (). > > > > Just as a BTW; powerpc platforms need this series of changes too, > > not just amd64. > > Thanks.. this change should work for all. > > > BTW2: I wonder if some of the attached changes really could be > > done more simply with va_copy()... Not that it matters of course. > > Probably.. that's new though? No va_copy() on 4.x. Yes, its formerly part of C99, but gcc has had it for a while. In gcc-2.95 it is implemented in the gnu version of stdarg.h as __va_copy(), but we neglected to add it to our includes in 4.x: default implementation: gcc/ginclude/stdarg.h:#define __va_copy(dest, src) (dest) = (src) gcc/ginclude/varargs.h:#define __va_copy(dest, src) (dest) = (src) platform override for ppc: gcc/ginclude/va-ppc.h:#define __va_copy(dest, src) *(dest) = *(src) The same variation for ppc there would work for amd64 as well. I have run into quite a number of ports that have this knowledge built in so that they can compile on ppc with older gcc's without the includes. Anyway, never mind. :-) -- Peter Wemm - peter@wemm.org; peter@FreeBSD.org; peter@yahoo-inc.com "All of this is for nothing if we don't go to the stars" - JMS/B5
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200412281526.48335.peter>