   Linking libws2_32.a library in code::blocks
  Hi all,I hope someone can help. I want to start programming using sockets and stuff, but I can't manage to link the libws2_32.a in code::blocks.I have tried adding the full path in the linker and I have also tried -llibws2_32 in the linker, but for some reason code::blocks keeps looking in the wrong place for my library and I get the following message:mingw32-g++.exe: C:\Program Files\CodeBlocks\MinGW\lib\libws2_32.a: No such file or directoryI use dev c++ and it isn't installed on my c: partition.I even put the correct location of the libs folder in the search tab as well.Can anyone help me with this, I need to network my game.Asimov500   
  Okay, go to Settings -> Compiler and Debugger... -> Toolchain executables. Is the path to MingW set correctly? As in, install directory should contain a path like this: "E:\Compilers\MingW" and all the others just executable names, not paths.Within the same window, you can try and go to Search directories. Now add compiler (for includes) and linker (for libs) directories as to where it should look for those. If you do this through Project -> Build Options it will only set these for the active project, not for any project you do in C::B.Now go to Project -> Build Options -> Linker settings (make sure the project is selected on the left, not a build target) and add in the left list the library "ws2_32" (not a path!).That works for me.Also, where is MingW installed at? Within CodeBlocks directory?   ;  Hi  Decrius,Thankyou for replying.I have tried what you suggested and I still get the same error.In toolchain executables I have E:\Utilities\Dev-Cpp which is correct.I have various SDL libraries I link to and these all link fine, so I don'tunderstand why I cannot link the libws2_32.a.I still think it is looking in the wrong place for the library even though in the settings I have set it to the correct folder.-------------- Build: Debug in clientserver ---------------Linking console executable: clientserver_debug.exemingw32-g++.exe: C:\Program Files\CodeBlocks\MinGW\lib\libws2_32.a: No such file or directoryProcess terminated with status 1 (0 minutes, 0 seconds)0 errors, 0 warnings Asimov500   ;  Hi Decrius,Thankyou I have now got it working.There are linker settings for debug and release and even though I put it in debug and release links, it was being over ruled by the global settings which I have now changed.I have now managed to link the library. Now all i gotta do is to work out how to use it heh heh.Thankyou very muchAsimov500   ;  Good to hear ;) have fun linking :D   