warmcat/libwebsockets — pull request #159 by mhaberler (2014-08-11 11:08:01+00:00)
Title: config: introduce integer LWS_LIBRARY_VERSION_NUMBER, micro numbering

the current LWS_LIBRARY_VERSION macro is a string, which makes it hard
to test for version-dependent features in using code.

This patch adopts the Google version number method, which encodes a version
as an integer as 'major * 10^6 + minor * 10^3 + micro'.

This makes it easy to test:

#if defined(LWS_LIBRARY_VERSION_NUMBER) && (LWS_LIBRARY_VERSION_NUMBER > 1003000)
// use feature introduced post 1.3.0
#endif

Also, spin out version information into a separate include since
including library build information from lws_config.h is a bad idea as
it interferes with using code.

Signed-off-by: Michael Haberler