[Libwebsockets] v4.1 released

Andy Green andy at warmcat.com
Mon Sep 7 06:38:26 CEST 2020


Hi -

lws v4.1 is out along with v4.1-stable.

https://libwebsockets.org/git/libwebsockets/tree/changelog

One feature that came after the -rcs is that by default on unix, if any 
event libs are enabled for build the event lib support is built as 
runtime-loaded plugins; if user code indicates it wants to use, eg, 
libuv, then the libuv plugin is loaded and used during context creation.

The advantage of that is all the event libs can be built in isolation, 
so the cases where their namespace conflict no longer matter, and each 
plugin can be packaged separately in distros, solving a headache there.

If a particular lws user packageset doesn't need event lib support 
because they use the built-in poll() loop, then no event loop plugins 
are pulled in; otherwise only the event lib plugin packages that have 
packages that depend on them them are installed along with their related 
event libs like libuv.  There's then no conflict or problem to install 
packages that, eg, want libuv and other packages that want glib, and no 
problem any more even with the livevent vs libev whose public namespace 
conflicts, you can install and use both simultaneously with different 
user apps that want them.

Without this, distros had a problem about what event lib support to 
build in, for example the ecosystem around supporting glib is nontrivial 
and objectionable if your system was constrained and did not already 
want glib.  This way the default is no dependency by lws on event libs, 
and only people who install something that already wants, eg, glib will 
pull in lws glib support too.

If you are already building static with event libs, and don't want extra 
plugins, the old build static built-in event lib behaviour is still 
supported with -DLWS_WITH_EVLIB_PLUGINS=0, see the readme on the topic 
for the details

https://libwebsockets.org/git/libwebsockets/tree/READMEs/README.event-libs.md

Another significant change is the removal of SaaS travis and appveyor / 
bintray on stable, replaced by selfhosted Sai CI.  This builds on a lot 
more platforms each time (193 build on 16 platforms currently) including 
additional things like fedora/risc-v and freebsd/x86_64 in qemu and a 
variety of crossbuilds for Android, iOS and freertos-based systems, and 
runs CTest-based testing not only on the systemd-nspawn and qemu-based 
platforms, but also flashes and tests on physical (currently, esp32) 
devices.

-Andy


More information about the Libwebsockets mailing list