Path: chuka.playstation.co.uk!news From: "Peter" Newsgroups: scee.yaroze.freetalk.english Subject: Re: Why won't this link? Date: Thu, 1 Mar 2001 13:06:46 -0000 Organization: PlayStation Net Yaroze (SCEE) Lines: 75 Message-ID: <97lh9t$3v21@www.netyaroze-europe.com> References: <97kf5l$i7g5@www.netyaroze-europe.com> <3A9EC4B0.AD349076@start.com.au> Reply-To: "Peter" NNTP-Posting-Host: host213-122-157-124.btinternet.com X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.50.4522.1200 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200 I figured that libps.a must be linked already because my call to ResetGraph() call works fine. It seems to be the use of the 'new' keyword its got a problem with (and pure virtual functions too, I mean how am I supposed to define an interface without using pure virtual functions?!!) Anyway I'll give it a try and keep you posted. Thanxs mate. Hugz Pete PS: If anyone knows of another C++ compiler that I can use, please let me know. this one is doing my 'ed in! ;) "gwald" wrote in message news:3A9EC4B0.AD349076@start.com.au... > Hi > Okay , I'm not on my Yaroze programming machine but of the top of my head, I > remember useing ar.exe to extract libps.a mods and added some modules into > libsngcc.a or something like this, because it uses only libsngcc.a to link and > not libps.a. > Sorry i can't remember which but it didn't take long. > make sure u keep a backup of everything and just experiment. > > Buena suerte! > > ~mgarcia > > > Peter wrote: > > > Hi guyz, > > > > I'm using the Gygwin (MIPS variant) C++ compiler. I can the following > > program to compile but I just can't get it to link. Every time I try I get > > the following error. > > > > gcc -Xlinker -Ttext -Xlinker 80140000 main.o object.o -o main.exe > > \psx3\mips-unknown-ecoff\lib/libsngcc.a(new_hand.o): In function > > `__default_new_handler': > > libgcc2.c(.text+0x3c): undefined reference to `_exit' > > libgcc2.c(.text+0x3c): relocation truncated to fit: JMPADDR _exit > > > > Main.cpp looks as follows: > > > > #include > > #include "object.h" > > > > int main (void) > > { > > Object* ptrObject = new Object("blip"); > > ResetGraph(0); > > } > > > > The Object class is defined as follows: > > > > class Object > > { > > protected: > > char* message; > > > > public: > > Object() {}; > > Object(char* string); > > }; > > > > My coding is very rusty so I may be missing something but I'm sure this > > should work. Its also 3 in the morning and my brain shut down > > about...actually come to think of it I don't remember it starting up :) > > > > Hugz, Peter >