www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2001/05/07/02:11:44

Date: Mon, 7 May 2001 09:13:12 +0300 (IDT)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
X-Sender: eliz AT is
To: Martin Ambuhl <mambuhl AT earthlink DOT net>
cc: djgpp AT delorie DOT com
Subject: Re: need help
In-Reply-To: <3AF62EB7.82D0792F@earthlink.net>
Message-ID: <Pine.SUN.3.91.1010507091224.19812E-100000@is>
MIME-Version: 1.0
Reply-To: djgpp AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On Sun, 6 May 2001, Martin Ambuhl wrote:

> > C:\>gcc hello.cpp -o hello.exe -lm
> > In file included from hello.cpp:1:
> > c:/djgpp/lang/cxx/iostream.h:31: streambuf.h: No such file or directory
> > (ENOENT)
> 
> You are trying to compile and link C++ code as C.  See your documentation for
> details on using gpp instead of gcc

Using gcc instead of gpp might be a reason for link errors, but not
for compilation errors.  When gcc sees a.cpp file, it knows that it is a 
C++ program.

The error message above comes from the preprocessor, not from the linker.

As I wrote elsewhere in this thread, section 8.3 of the FAQ discusses
this problem.

- Raw text -


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