From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lacrosse.corp.redhat.com (lacrosse.corp.redhat.com [207.175.42.154]) by listman.redhat.com (Postfix) with ESMTP id 0405D2FD02 for ; Tue, 6 Feb 2001 10:32:31 -0500 (EST) Received: (from mail@localhost) by lacrosse.corp.redhat.com (8.9.3/8.9.3) id KAA15392 for axp-list@listman.redhat.com; Tue, 6 Feb 2001 10:32:25 -0500 Received: from devserv.devel.redhat.com (devserv.devel.redhat.com [207.175.42.156]) by lacrosse.corp.redhat.com (8.9.3/8.9.3) with ESMTP id KAA15386 for ; Tue, 6 Feb 2001 10:32:25 -0500 Received: (from msw@localhost) by devserv.devel.redhat.com (8.11.0/8.11.0) id f16FWPX03003 for axp-list@redhat.com; Tue, 6 Feb 2001 10:32:25 -0500 Date: Tue, 6 Feb 2001 10:32:25 -0500 From: Matt Wilson To: axp-list@redhat.com Subject: Re: gcc-2.96 problem under rh70 Message-ID: <20010206103225.A31050@devserv.devel.redhat.com> References: <20010206145801.A3282@twister.gmd.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010206145801.A3282@twister.gmd.de>; from Georg.Wittig@gmd.de on Tue, Feb 06, 2001 at 02:58:01PM +0100 X-Loop: axp-list@redhat.com Sender: axp-list-admin@redhat.com Errors-To: axp-list-admin@redhat.com X-BeenThere: axp-list@redhat.com X-Mailman-Version: 2.0beta4 Precedence: bulk Reply-To: axp-list@redhat.com List-Id: Linux and Red Hat on Alpha processors There are many cases where the new compiler is a bit more strict and/or pedantic. Why are you including varargs.h? You're using the ANSI C va_start, etc macros. If you include varargs.h you get the old compatibility macros: from "man va_start" COMPATIBILITY These macros are not compatible with the historic macros they replace. A backward compatible version can be found in the include file varargs.h. varargs.h now blows away the stdargs.h macros (at least in the gcc build I have here, which is in rawhide). But this will also make your program build because va_start only takes one argument in the old style. So, in short, remove the varargs.h include - stick with stdarg.h Cheers, Matt On Tue, Feb 06, 2001 at 02:58:01PM +0100, Georg Wittig wrote: > The following program doesn't compile with gcc-2.96: > > --------------------------------- > #include > #include > > demo(int dummy1, ...){ > va_list dummy2; > va_start(dummy2, dummy1); > } > --------------------------------- > /usr/lib/gcc-lib/alpha-redhat-linux/2.96/include/varargs.h:66:17: warning: "va_start" redefined > /usr/lib/gcc-lib/alpha-redhat-linux/2.96/include/stdarg.h:54:1: warning: this is the location of the previous definition > test.c:6:26: too many arguments for macro "va_start" > --------------------------------- > > Of course, this isn't a real program, but an excerpt from a bigger > program to nail down the problem. That program used to compile and > work under RH >= 4.2 on all the Alphas, but no longer under RH70. > > $ rpm -qa | grep gcc > gcc-c++-2.96-69 > gcc-2.96-69 > $ uname -r > 2.2.17-4 > $ grep platform /proc/cpuinfo > platform string : COMPAQ Professional Workstation XP1000 > $ cat /etc/redhat-release > Red Hat Linux release 7.0 (Guinness) > $ > > Suggestions how to work-around that problem until the bug is fixed are > welcome. Thanks in advance for your help. > > > -- > Georg Wittig, GMD Georg.Wittig@gmd.de > - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - > A lot of time has been wasted arguing over what came first -- > the chicken or the egg. It was undoubtedly the rooster. > > > > _______________________________________________ > Axp-list mailing list > Axp-list@redhat.com > https://listman.redhat.com/mailman/listinfo/axp-list