This is a C library for developing cross-platform applications and web-services.
How it started:
I wanted to get something for rapidly designing multi-thread/networking application with keeping cross-platform capabilities (include legacy os, like: OS/2, Solaris 10, Win2003, ...).
As well as having small, easy-to-use, embeddable web-server with extension features (similar to java servlets).
There are libraries, such as: Apache Portable Runtime or libre, which I actively using but they are not always suitable.
The result was this library, which is a combination of ideas from libre, apr and other ones.
This is an open-source project and available on GitHUB
Was tested with: gcc-11x and make-4.3
Tested with: clang-10x and make-4.3
Tested with: gcc-5.5, binutils-2x, gnu make-4.x)
Tested with: gcc-6.3, binutils-2.x, gnu make-3.8
It also can work on earlier versions but with one condition: winsock should be not less 2.2
Tested with: gcc-3.2x, binutils-2x, make-3x
The primitives for writing multithreaded applications and synchronisations.
Alos provides high level things such as: queues, workers (see:
examples/test-queue.c and
examples/test-worker.c )
High level interface for implementation plugins system
Provides API for using types such as: hashtable or linked list.
Organize storage based on it.
Provides API for string manipulations: concat, replace, etc (see: wstk-str.h )
Provides up/low-level API for interaction with the sockets and its functions.
API to arrange polling by: select, epoll and kqueue methods.
Ready made multi-threaded tcp/udp servers.
Advanced multi-threaded server that provides functions:
- directory browsing and file downloading
- API and primitives for organizing authorization
- servlets mechanism for functionality expansion
- adjustable mime-types and encodings
- collection of ready made servlets:
- servlet-jsonrpc - provides an easy way to write json-rpc services (see: examples/test-httpd-jsonrpc.c)
- servlet-websock - provides an api to use websockets (see: examples/test-httpd-websock.c)
- servlet-upload - a simple way to upload files into the server (see: examples/test-httpd-upload.c)
Things such as: mbuf, fmt, pl, regex, and so on (from libre)
The library doesn't use any autotool scripts and so on, all the configuration options described in Makefile and wstk-core.h.
Therefore, a building operation looks quite standard: make clean all. After that you'll get two file: libwstk.so and libwstk.a (depends on the target platform).
For examples, just perform: cd examples and make clean all TNAME={name} (make clean all TNAME=list).
will appear soon, still preparing...
Actually most of cases shown in the examples with short descriptions and can be used as a brief manual.