lists.zerezo.com



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

***BOGO*** Re: [Mingw-users] Why does g++ not link with libstdc++?



> fiveight wrote on 13 May 2008 06:06:
> 
>> But in my firm's project there are too many object files, so I put these
>> object files path in a response file, for example "proj.rsp". Then I link
>> with: g++ -o proj.exe -Wl,@"proj.rsp" 
>> This command does not link with libstdc++.
>> If I link with:
>> g++ -o proj.exe -Wl,@"proj.rsp" -lstdc++
>> It works well.
>> 
>> I remember that g++ will automatic link libstdc++. Why does the first
>> command not work? 
> 
>  Guessing: compile doesn't add -lstdc++ because you're passing all the .o
> files straight to the linker (-Wl), so it doesn't know you have any object

Yes, I think so. The g++ doesn't know the object files.

> files at all.  Try passing it at least one, or maybe the mingw gcc.exe

I am afraid that I can not pass g++ one object file, because another program will
use the response file too. I must keep the response file integral.

> understands "@" files itself?

Neither gcc.exe nor g++.exe understand "@" option. 

So, I am in big trouble!

Thank you very mush.
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft 
Defy all challenges. Microsoft(R) Visual Studio 2008. 
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
MinGW-users mailing list
MinGW-users@xxxxxxxxxxxxxxxxxxxxx

You may change your MinGW Account Options or unsubscribe at:
https://lists.sourceforge.net/lists/listinfo/mingw-users