I'm showing explicitly the output. Here is the linking sentence:
c++ -o Exefile -g3 -v -Wall -mno-cygwin -mthreads << my objects >>
-L(Directories) -lnetapi32 -lwsock32
So I don't call explicitly most of linking libraries.
Perhaps should I use g++ directly ?
Ignasi Villagrasa.
Ranjit Mathew wrote:
It fails with and without -mthreads in compilation and linking.
Here is the list of libraries linked in the application.
-lnetapi32 -lwsock32 -lstdc++ -lmingwthrd -lmingw32 -lgcc -lmoldname
-lmsvcrt -lmingwthr
d -lmingw32 -luser32 -lkernel32 -ladvapi32 -lshell32 -lmingwthrd
-lmingw32 -lgcc -lmoldname -lmsvcrt
What am I going wrong ?
Why do you need to explicitly link in all these libraries?
(Or are you showing the final output of compiling with "g++ -v"?
BTW, you *are* compiling this with "g++" - not "gcc" - aren't
you?)
AFAICT, you just need to link in like:
g++ -mthreads -o exename all-your-object-files -lws2_32 -lnetapi32
Does this also not work?
Ranjit.
_________________________________________________________________
High ISD bills? Get a phone card. http://www.msn.co.in/webtelephony
Call US for just Rs. 5
-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
MinGW-users mailing list
MinGW-users at lists dot sourceforge dot net
You may change your MinGW Account Options or unsubscribe at:
https://lists.sourceforge.net/lists/listinfo/mingw-users