This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

gcc 3.4.4-x (WinXP Win2K) failure to link for 'new'


I just downloaded gcc-3.4.4-03 on my WinXP and have the previous version of
gcc-3.4.4 on my Win2K computer. In both machines the following code fails to
link. The error message indicates that 'new(unsigned int)' could not be found
which I suppose means that 'new int' is translated into 'new((unsigned
int)sizeof(int))'. <br><br>Since I haven't seen another posting on this message
I assume that there's something wrong with my installation or installation
procedures. I usually execute an 'install from internet' so the problem must be
local. Any direction would be a great help.<br><br>art<br><br><span
style="font-family: courier;">int main(void)</span><br style="font-family:
courier;"><span style="font-family: courier;">{</span><br style="font-family:
courier;"><span style="font-family: courier;">&nbsp; int * p;</span><br
style="font-family: courier;"><span style="font-family: courier;">&nbsp; int *
q = new int;</span><br style="font-family: courier;"><br style="font-family:
courier;"><span style="font-family: courier;">&nbsp; p = new int;</span><br
style="font-family: courier;"><br style="font-family: courier;"><span
style="font-family: courier;">&nbsp; return 3;</span><br style="font-family:
courier;"><span style="font-family: courier;">&nbsp;&nbsp;&nbsp; </span><br
style="font-family: courier;"><span style="font-family: courier;">}</span><br
style="font-family: courier;"><br style="font-family: courier;"><br
style="font-family: courier;"><span style="font-family:
courier;">/c/DOCUME~1/ra07220/LOCALS~1/Temp/ccAgrALS.o:main.c++:(.text+0x32):
undefined reference to `operator new(unsigned int)'</span><br
style="font-family: courier;"><span style="font-family:
courier;">/c/DOCUME~1/ra07220/LOCALS~1/Temp/ccAgrALS.o:main.c++:(.text+0x41):
undefined reference to `operator new(unsigned int)'</span><br
style="font-family: courier;"><span style="font-family: courier;">collect2: ld
returned 1 exit status</span><br style="font-family: courier;"><span
style="font-family: courier;">&gt;&gt; gcc --version</span><br
style="font-family: courier;"><span style="font-family: courier;">gcc (GCC)
3.4.4 (cygming special, gdc 0.12, using dmd 0.125)</span><br
style="font-family: courier;"><span style="font-family: courier;">Copyright (C)
2004 Free Software Foundation, Inc.</span><br style="font-family:
courier;"><span style="font-family: courier;">This is free software; see the
source for copying conditions.&nbsp; There is NO</span><br style="font-family:
courier;"><span style="font-family: courier;">warranty; not even for
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.</span><br
style="font-family: courier;"><br style="font-family: courier;"><span
style="font-family: courier;">&gt;&gt; cygcheck -s -v -r &gt;
cygcheck.out</span><br style="font-family: courier;"><br>

Attachment: WinXP_cygcheck.out
Description: 2444029899-WinXP_cygcheck.out

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]