Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C++ > error compiling stl samples with g++ in cygwin

Reply
Thread Tools

error compiling stl samples with g++ in cygwin

 
 
TheOne
Guest
Posts: n/a
 
      05-02-2007
I downloaded sample codes from http://www.cs.rpi.edu/~musser/stl-book/source/src.zip
and tried to compile them.

I started my cygwin on xp, renamed Makefile.unix to Makefile and typed
"make". After several successful compilation, it spat out following
error :

/usr/lib/gcc/i686-pc-cygwin/3.4.4/../../../libcygwin.a(libcmain.o):
(.text+0xab): undefined reference to `_WinMain@16'
collect2: ld returned 1 exit status
make: *** [ex04-01] ¿À·ù 1

There's no WinMain in the code. Strangely, when I retried "make",
compile is succuessful for the file but again after several succuess,
make complain with the same error message with another source code.

What can cause the problem?

TIA.

 
Reply With Quote
 
 
 
 
red floyd
Guest
Posts: n/a
 
      05-02-2007
TheOne wrote:
> I downloaded sample codes from http://www.cs.rpi.edu/~musser/stl-book/source/src.zip
> and tried to compile them.
>
> I started my cygwin on xp, renamed Makefile.unix to Makefile and typed
> "make". After several successful compilation, it spat out following
> error :
>
> /usr/lib/gcc/i686-pc-cygwin/3.4.4/../../../libcygwin.a(libcmain.o):
> (.text+0xab): undefined reference to `_WinMain@16'
> collect2: ld returned 1 exit status
> make: *** [ex04-01]
>
> There's no WinMain in the code. Strangely, when I retried "make",
> compile is succuessful for the file but again after several succuess,
> make complain with the same error message with another source code.
>
> What can cause the problem?
>


Wrong group. Try gnu.g++.help.

F/U set.

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Error when compiling with Cygwin TuPLaD C++ 22 08-30-2004 08:41 PM
confirm unsubscribe from cygwin@cygwin.com cygwin-help@cygwin.com Python 0 09-05-2003 04:42 PM
WELCOME to cygwin@cygwin.com cygwin-help@cygwin.com Python 1 09-05-2003 07:46 AM
confirm unsubscribe from cygwin-announce@cygwin.com cygwin-announce-help@cygwin.com Python 0 09-05-2003 01:29 AM
confirm unsubscribe from cygwin@cygwin.com cygwin-help@cygwin.com Python 0 09-04-2003 06:34 PM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57