🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.g++.help
Article #940

[Q] I'm having a problem linking this simple one...

#940
From: Jonathan Martin
Date: Sat, 06 Apr 1996 07:04
25 lines
1141 bytes
Ok, I'm teaching myself c++, so bare with me.

When I compile this:
	#include <CursesW.h>
	main () {
		CursesWindow mine (20,20,5,5);
	}
with the command line:

	g++ -I/usr/include/ncurses -ohello hello.cc

I get this from the linker:

/tmp/cca...: undefined reference to 'CursesWindow::~CursesWindow(void)'
/tmp/cca...: undefined reference to 'CursesWindow::CursesWindow(int,int,int,int)'

I checked the command line that g++ is feeding to ld, and -lg++ is 
there. I made a hello.o and checked the symbol table, and the symbols 
that ld's having trouble with seem to match those in libg++ ok.  I 
dunno.  Like I said, I'm new at this.

Any help would be greatly appreciated.

-Jon
jmartin@snet.net
Technical Details
Message-ID: <4k552m$1to0@CT1.SNET.Net>
Path: arc1-ca.pugleaf.net!new-news.sprintlink.net!snet!CT1!personalvision!jmartin

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!new-news.sprintlink.net!snet!CT1!personalvision!jmartin
From: jmartin@personalvision (Jonathan Martin)
Newsgroups: gnu.g++.help,comp.lang.c++
Subject: [Q] I'm having a problem linking this simple one...
Date: 6 Apr 1996 07:04:54 GMT
Organization: Southern New England Telephone
Message-ID: <4k552m$1to0@CT1.SNET.Net>
NNTP-Posting-Host: 204.60.5.42
Keywords: help
X-Newsreader: TIN [version 1.2 PL2]