Theldus / wsServer

wsServer - a tiny WebSocket server library written in C
https://theldus.github.io/wsServer
GNU General Public License v3.0
427 stars 86 forks source link

How to compile on windows? #90

Open Cool-Joe opened 3 months ago

Cool-Joe commented 3 months ago
[D:\Download\dev\wsServer-master] make
"  CC      src/ws.o"
src/ws.c:20:21: fatal error: pthread.h: No such file or directory
 #include <pthread.h>
                     ^
compilation terminated.
make: *** [src/ws.o] Error 1

Windows does not (and is unlikely to ever) support pthreads natively. So I wonder how this code can be compiled on windows?

Theldus commented 3 months ago

Hi @Cool-Joe, yes, you're right. wsServer is compatible with Windows only via builds with MinGW/MSYS2.

On Building on Windows there is a detailed step-by-step guide on how to do this.