delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/04/29/19:02:07

From: "John M. Aldrich" <fighteer AT cs DOT com>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Trying to compile C++
Date: Wed, 29 Apr 1998 18:50:47 -0400
Organization: Two pounds of chaos and a pinch of salt.
Lines: 40
Message-ID: <3547AEC7.17C9@cs.com>
References: <3546A4BD DOT A752A564 AT NOSPAMmindless DOT com>
NNTP-Posting-Host: ppp123.cs.net
Mime-Version: 1.0
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

vic wrote:
> 
> I am having a lot of trouble getting rhide to compile even the simplest
> C++ programs. When I try to compile the following program:
> 
> I get the following error message:
> 
> ¦ Compiling: a:/old/planet.cpp
> ¦ a:/old/planet.cpp(1) In file included from
> a:/old/planet.cpp:1:              _
> ¦ c:/djgpp/lang/cxx/iostream.h(91) Error: parse error before
> `__extension__'   _
> ¦ c:/djgpp/lang/cxx/iostream.h(208) Error: parse error before
> `__extension__'  _
> ¦ There were some errors
> 
> Does anyone have any ideas on what I'm doing wrong.

Your program compiles fine for me from DOS; therefore the problem is
almost certainly in your setup.  Please make sure that you are not
mixing versions of gcc in your DJGPP installation, such as lgpp280b with
gpp2721b.  If you installed gcc 2.8.0 over 2.7.x, you should have
completely removed the old gcc installation before installing.  If you
run out of options, completely remove all components of gcc from your
system (gccXXXb, gppXXXb, and lgpXXXb) and reinstall from scratch.

I looked in iostream.h and the __extension__ keyword is apparently used
there to permit the overloaded operators for the GNU long long type to
compile without warnings with the '-pedantic' switch.  I can't think of
any reason why this would not be recognized unless it is a new feature
of gcc 2.8.0.  Probably somebody with more knowledge of the subject
should clarify this.

-- 
---------------------------------------------------------------------
| John M. Aldrich, aka Fighteer I  |     mailto:fighteer AT cs DOT com     |
|      ICQ UIN#:  7406319          |   http://www.cs.com/fighteer/  |
|    ObJoke:  If Bill Gates were a robber, not only would he        |
|     shoot you, but he'd send you a bill for the bullets.          |
---------------------------------------------------------------------

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019