www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2002/02/22/15:03:45

X-Authentication-Warning: delorie.com: mailnull set sender to djgpp-bounces using -f
From: "A. Sinan Unur" <asu1 AT cornell DOT edu>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Having a problem compiling a program.
Date: 22 Feb 2002 19:55:54 GMT
Organization: Cornell University
Lines: 34
Sender: asu1 AT cornell DOT invalid (on 132.236.44.13)
Message-ID: <Xns91BD97E3CBC2Fasu1cornelledu@132.236.56.8>
References: <%Qvd8.5806$0y2 DOT 288632 AT typhoon DOT austin DOT rr DOT com>
NNTP-Posting-Host: 132.236.44.13
X-Trace: news01.cit.cornell.edu 1014407754 6247 132.236.44.13 (22 Feb 2002 19:55:54 GMT)
X-Complaints-To: usenet AT news01 DOT cit DOT cornell DOT edu
NNTP-Posting-Date: 22 Feb 2002 19:55:54 GMT
User-Agent: Xnews/L5
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

"Stratis Aftousmis" <lsdguru78 AT hotmail DOT com> wrote in news:%Qvd8.5806
$0y2 DOT 288632 AT typhoon DOT austin DOT rr DOT com:

> Greeting's, here is the program:
> #include <iostream.h>
> int main()
> {
> cout<<"Hello, world, will i get this to work?";
> return 0;
> }
> Here is the command:  c:\djgpp> gcc hello.cpp -o hello.exe
> Here is the problem:
> In file included from hello.cpp:1:
> djgpp.ver:1:25: No include path in which to find sys/version.h
> hello.cpp:1:25: No include path in which to find iostream.h
> hello.cpp: In function ' int main()":
> hello.cpp:4: 'cout' undeclared (first use this function)
> hello.cpp:4: (Each undeclared identifier is reported only once for each
>     function it appears in.)
> 
> Iv'e tryed even including the header in my autoexec.bat, but now i just
> have: SET C_INCLUDE_PATH=C:\djgpp and all my header's are there.

which means you did not read the instructions (the readme.1st file has 
that name for a reason). your header files have no business inc:\djgpp 
... they should be in the appropriate subdirectories, and you should 
never have to set C_INCLUDE_PATH unless you are adding extra stuff.

delete your c:\djgpp directory, and re-unzip the distribution preserving 
the directory structure. for this either use the unzip program available 
from the ftp site, or make sure the appropriate option is set in whatever 
program you are using.

sinan.

- Raw text -


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