Article View: gnu.g++.lib.bug
Article #9GCC-2.3.1 fails to build libg++2.2 under NeXTstep 3.0
From: Magnus Nordborg
Date: Wed, 04 Nov 1992 03:57
Date: Wed, 04 Nov 1992 03:57
116 lines
5424 bytes
5424 bytes
I'm trying to build libg++2.2 on a NeXT running NeXTstep 3.0 using a
freshly installed gcc-2.3.1. The compile fails due to parse error.
I did:
# ./configure next
Created "Makefile" in /usr/local/src/libg++-2.2
# cd libg++
# make all CFLAGS='-g -O2'
rootme=`pwd` ; export rootme; CC="`if [ -f ${rootme}/../gcc/gcc ] ; then
echo ${rootme}/../gcc/gcc\\ -B${rootme}/../gcc/ ; else echo gcc ; fi` `if
[ -f ${rootme}/../gcc/gcc ] ; then echo -I${rootme}/../gcc/include ;
else echo ; fi`"; export CC; utils/gen-params >tmp-params.h
mv tmp-params.h _G_config.h
gcc -g -O2 -nostdinc++ -I.. -I. -I./../iostream -I./../g++-include -c
AllocRing.cc
gcc -g -O2 -nostdinc++ -I.. -I. -I./../iostream -I./../g++-include -c
Obstack.cc
gcc -g -O2 -nostdinc++ -I.. -I. -I./../iostream -I./../g++-include -c
builtin.cc
gcc -g -O2 -nostdinc++ -I.. -I. -I./../iostream -I./../g++-include -c
regex.cc
gcc -g -O2 -nostdinc++ -I.. -I. -I./../iostream -I./../g++-include -c
Regex.cc
Regex.cc: In method `Regex::Regex (const char *, int (= 0 ), int (= 40
), const char * (= 0 ))':
Regex.cc:52: warning: ANSI C++ forbids implicit conversion from `void *'
in assignment
Regex.cc:59: warning: ANSI C++ forbids implicit conversion from `void *'
in assignment
gcc -g -O2 -nostdinc++ -I.. -I. -I./../iostream -I./../g++-include -c
String.cc
In file included from ./../iostream/iostream.h:25, from
/../iostream/stream.h:7, from ./String.h:26, from String.cc:25:
/../iostream/streambuf.h:359: warning: type specifier omitted for
parameter
/../iostream/streambuf.h:359: parse error before `,'
/../iostream/streambuf.h:360: warning: type specifier omitted for
parameter
/../iostream/streambuf.h:360: parse error before `)'
In file included from ./../iostream/stream.h:7, from ./String.h:26, from
String.cc:25:
/../iostream/iostream.h:60: warning: type specifier omitted for parameter
/../iostream/iostream.h:60: parse error before `)'
/../iostream/iostream.h:152: warning: type specifier omitted for
parameter
/../iostream/iostream.h:152: parse error before `)'
/../iostream/iostream.h:225: warning: type specifier omitted for
parameter
/../iostream/iostream.h:225: parse error before `)'
/../iostream/iostream.h:247: warning: type specifier omitted for
parameter
/../iostream/iostream.h:247: parse error before `)'
/../iostream/iostream.h: In method `class streambuf::istream&
iostream::vscan (...)':
/../iostream/iostream.h:226: `format' undeclared (first use this
function)
/../iostream/iostream.h:226: (Each undeclared identifier is reported only
once
/../iostream/iostream.h:226: for each function it appears in.)
/../iostream/iostream.h:226: `args' undeclared (first use this function)
/../iostream/iostream.h:226: warning: control reaches end of non-void
function
/../iostream/iostream.h: In method `class ostream& iostream::vform
(...)':
/../iostream/iostream.h:248: `format' undeclared (first use this
function)
/../iostream/iostream.h:248: `args' undeclared (first use this function)
/../iostream/iostream.h:248: warning: control reaches end of non-void
function
*** Exit 1
Stop.
*** Exit 1
Stop.
The offending lines 359-360 in "./../iostream/streambuf.h" are:
int vscan(char const *fmt0, _G_va_list ap, ios::iostate* = NULL);
int vform(char const *fmt0, _G_va_list ap);
and the lines in "./../iostream/iostream.h" are:
60: ostream& vform(const char *format, _G_va_list args);
152: istream& vscan(const char *format, _G_va_list args);
225: istream& vscan(const char *format, _G_va_list args)
226: { return ((istream*)this)->vscan(format, args); }
247: ostream& vform(const char *format, _G_va_list args)
248: { return ((ostream*)this)->vform(format, args); }
I have examined the preprocessor output using the -E option:
# grep vscan /tmp/cpp.out
int vscan(char const *fmt0, __gnuc_va_list ap, ios::iostate* =
((void*)0) );
istream& vscan(const char *format, __gnuc_va_list args);
istream& vscan(const char *format, __gnuc_va_list args)
{ return ((istream*)this)->vscan(format, args); }
# grep vform /tmp/cpp.out
int vform(char const *fmt0, __gnuc_va_list ap);
ostream& vform(const char *format, __gnuc_va_list args);
ostream& vform(const char *format, __gnuc_va_list args)
{ return ((ostream*)this)->vform(format, args); }
The definition appears in /usr/local/src/libg++-2.2/libg++/_G_config.h:
#define _G_va_list __gnuc_va_list
Any hints? Thanks, Magnus
---
Magnus Nordborg
Department of Biological Sciences
Stanford University
magnus@fisher.stanford.edu (NeXT mail preferred)
+1 (415) 723-4952 (office)
+1 (415) 948-7321 (home)
Technical Details
Message-ID:
<1992Nov4.035728.3183@leland.Stanford.EDU>Path:
arc1-ca.pugleaf.net!sparky!uunet!charon.amdahl.com!pacbell.com!iggy.GW.Vitalink.COM!cs.widener.edu!umn.edu!spool.mu.edu!olivea!charnel!rat!usc!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!fisher.stanford.edu!magnusShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!charon.amdahl.com!pacbell.com!iggy.GW.Vitalink.COM!cs.widener.edu!umn.edu!spool.mu.edu!olivea!charnel!rat!usc!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!fisher.stanford.edu!magnus From: magnus@fisher.stanford.edu (Magnus Nordborg) Newsgroups: gnu.g++.lib.bug Subject: GCC-2.3.1 fails to build libg++2.2 under NeXTstep 3.0 Keywords: next, parse, vform, gnuc Message-ID: <1992Nov4.035728.3183@leland.Stanford.EDU> Date: 4 Nov 92 03:57:28 GMT Sender: gnulists@ai.mit.edu Distribution: gnu Organization: DSO, Stanford University Lines: 116 Approved: bug-lib-g++@prep.ai.mit.edu