![]() |
#1 | ||
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() |
![]() I need this to work in Linux. I am messing with it in Cygwin and I got that damn error, which screenshot I included in archive together with source files. I commented problem lines, so the error came out when one of it became uncommented.
Main file is Test.cpp
__________________
"Paladin work is never done..." ![]() |
||
![]() ![]() |
|
![]() |
#2 | ||
![]() ![]() Join Date: Mar 2006
Location: ,
Posts: 2
|
![]() <div class='quotetop'>QUOTE(Nick @ Jul 23 2006, 09:06 AM) [snapback]244583[/snapback]</div>
Quote:
The g++ compiler will, unless you also specify "-c" run the linker on the resultant code. The linker will try to find all the code that you're attempting to call, linking by default with the C run time library. When g++ calls the linker, it only supplies the linker with object files (.o) that it's just compiled, so without specifying the other modules on the command line for g++ to compile, you're going to get linker errors. Try compiling with g++ Test.cpp CSolarisCoroutine.cpp Note, I haven't tried this, I've yet to install Cygwin after a machine upgrade a week ago. Also, with multiple source modules, you may want to look into the "make" utility; very handy for cutting down on compile times... HTH, HAND. |
||
![]() ![]() |
|
![]() |
#3 | ||
![]() ![]() ![]() ![]() ![]() Join Date: Jun 2004
Location: Jan Mayen, Svalbard and Jan Mayen
Posts: 2,167
|
![]() uncomment that readword part in Test.cpp
(or remove the virtual go(); definition) compile with g++ *.cpp -lpthread
__________________
Flowing with the stream of life |
||
![]() ![]() |
|
![]() |
#4 | ||
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() |
![]() <div class='quotetop'>QUOTE(Data @ Jul 23 2006, 07:46 PM) [snapback]244637[/snapback]</div>
Quote:
__________________
"Paladin work is never done..." ![]() |
||
![]() ![]() |
|