www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1996/10/10/05:04:48

From: ebromber AT forest DOT drew DOT edu
Newsgroups: comp.os.msdos.djgpp
Subject: More compiler problems
Message-ID: <1996Oct10.005737.147622@forest>
Date: 10 Oct 96 00:57:37 EST
Organization: Drew University
Lines: 54
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

I wrote a small program that prints TEST to the screen to test if the 
compiler was working. Unfortunately, there were two error messages 
displayed when i tried to compile the file. Below is a copy of the program 
and the two error messages. I have also posted the results of typing set 
>environ.lst at the dos prompt as well as my autoexec.bat file. Any help 
is greatly appreciated.

thanks in advance,
ebromber AT drew DOT edu

test.cc

#include <iostream.h>

int main()
{
	cout<<"TEST\n";
	return (0);
}

Two error messages after typing gcc test.cc
test.cc(.text+0x16)undefined reference to 'cout'
test.cc(.text+0x1b)undefined reference to 'ostream::operator <<(char const 
*)'

Contents of environ.lst
COMPSPEC=C:\COMMAND.COM
PROMPT=$p$g
PATH=C:\WINDOWS;C:\DOS;C:\DJGPP\BIN;C:\WINDOWS;C:\MOUSE
DJGPP=C:\DJGPP\DJGPP.ENV
LMOUSE=C:\MOUSE
TEMP=C:\TEMP
PGPPATH=C:\PGP
TMPDIR=C:\TEMP
TZ=EST5EDT
windir=C:\WINDOWS

autoexec.bat
@ECHO OFF
C:\DOS\SMARTDRV.EXE /X 512 128
PROMPT $p$g
PATH C:\WINDOWS;C:\DOS;C:\DJGPP\BIN
PATH %PATH%;C:\WINDOWS
PATH %PATH%;C:\MOUSE
SET DJGPP=C:\DJGPP\DJGPP.ENV
SET LMOUSE=C:\MOUSE
C:\MOUSE\mouse.exe
DOSKEY
SET TEMP=C:\TEMP
SET PGPPATH=C:\PGP
SET TMPDIR=C:\TEMP
SET TZ=EST5EDT
WIN

- Raw text -


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