Mail Archives: djgpp/2000/11/23/14:06:58
neldredge AT hmc DOT edu (Nate Eldredge) scritched in
<83y9yfdyp3 DOT fsf AT mercury DOT st DOT hmc DOT edu>:
>thelemur AT nowhere DOT not (Wesel) writes:
>
>> I have been having trouble with the fstream class in djgpp. It seems
>> I have a misplaced library, or perhaps a damaged one.
>
>No.
Well it -was- in the wrong place in the command line. Does that count as
misplaced?
>
>> gcc -c test.cpp
>> gcc test.o -o test.exe
>
>This should be gxx, not gcc.
*shrug* gcc and gxx work much the same I've found, as long as you provide
the right libraries.
>Because link order matters. If you'd put -lstdcxx at the end of the
>line, it should have worked, AFAIK.
That... works. Thank you! I could have sworn someone told me the the
libraries needed to go -before- the source code. I must have had it
backwards. Well, now I know. My program compiles perfectly.
Wesel
- Raw text -