Hi, perhaps it is a dumb question, but...
I have Dev-C++, and Allegro, but
how can I do any network programming?
Is the library included? I come from
the unix world, where I just
link the net library and use
functions such as bind, open,
write, etc. How do I do it now???
Thanks!
You could get libnet or HawkNL. Otherwise you would have to deal with windows sockets which are evil.
kazzmir: Not just evil, but exceptionally evil. 
... but I still prefer it like that. It's more hands-on, and you learn more that way.
Although I haven't implemented anything yet, there is Raknet. Check it out, its got a full version for non-commercial projects, and as of today, is cross platform with linux. The interface seems to be really easy as compared to doing your own sockets.
I plan on checking it out when I have some free time. I looked into libnet and HawkNL as those seem to be two that the Allegro community loves, but on the whole seem somewhat lowtech. (Sorry for not mentioning GNE Gillius, but thats above my head until you get the high level stuff finished
)
There are a few more nice networking libs floating around, my personal recommendation is to goto the gamedev.net networking forums and just try browsing around. Warning though, the gamedev crowd does not take kindly to stupid questions.
Good luck,
-Flecko

I am still having problems with this.
1. I downloaded the precompiled
libraries, now how do I link my program
against the library?
There is a NLstatic.lib and a HawkNL.lib
should not I need a whatever.a file???
2. I downloaded the source code, tried
to make the .a library but the compiling
stops at the multithreading module.
Any help?
(Im sorry I just got back to bussiness
after a one year break)
1. The .lib files are for MSVC, so you can't use them with MinGW/Dev-C++. You'll have to build it from the sources.
2. The problem lies with the pthread library that HawkNL uses by default for threading in Windows. Try this: delete the .o files that were created, and then add #define NL_WIN_THREADS in nl.h - this tells HawkNL to use native Windows threads instead of pthreads. Then recompile. This should work.
IIRC, there's no "make install" option, so you'll have to copy the relevant libraries and header files to the proper directories yourself.
[EDIT]
Weird. Now I can't get it to work. Anyway, since I still have libNL.a and NL.dll from before I lost my mojo, I uploaded them to my university account:
hawkcomp.zip [44 kB]
[EDIT 2]
It seems you can get it to compile - by manually removing -lpthreadsGC from the makefile.
Does MinGW have network libraries? If so, could you give me links to some networking tutorials?
Evil? Isn't WinSock a close clone of BSD Sockets? I used them to make an HTTP server. They are quite easy to use...
ARRGHH I'm currently on microsoft.com and have found the freakin networking refference, but how can I download this all, not just view pages that describe one function each.



use the forum search, I found a thread that linked to several good resources for WinSock.
// Nevermind, I fix the problem
//duh
with the exception of doing ipv6 (takes special code) and doing asynchronous DNS lookups (get the lib adns for that) I think winsock and bsdsock are the best ways to do networking. the only exception is when you just want to throw some crap together. which I hope you aren't 
as for hawkNL or any similar lib, I consider it close to crap. while it indeed brings you closer to the code you want, it adds another library dependance and 99% of it is just renamed commands.
the alternative (for those crap programs) is to move out all the stuff that makes sockets hard into "big" commands. but that will make you lose so much speed MS word will have higher FPS.
the best way is to make your own abstraction layer that suits your game the best - but then you will prefer to get your hands dirty because of the extra control it gives.
edit: and to really answer the first question:
winsock is the traditional bsd sock. only, you have to call a function at start and the #includes are different. so a simple #ifdef WIN32 will give you portability windows<->any other OS.
,ahpgny: Go see my link at the top of this thread and try to solve my problem. Good luck to you.
you forget I do C, not C++
that code surely does not look like ordinary sockets 
Edit: but I have some well encapsulated code you can borrow that does what you want; just look me up on IRC if interested.
The class encapsulates ordinary BSD sockets. Go and actually READ them, why don't you?
I'm dumb!. it had so much other "crap" with threads and stuff I started wondering what you were up to