minimize library footprint for embedded server-only
case
+--without-daemonize Don't build daemonize.c / lws_daemonize
+
+
Externally configurable important constants
-------------------------------------------
from your own main loop as shown in the test app sources.
+Daemonization
+-------------
+
+There's a helper api lws_daemonize built by default that does everything you
+need to daemonize well, including creating a lock file. If you're making
+what's basically a daemon, just call this early in your init to fork to a
+headless background process and exit the starting process.
+
+Notice stdout, stderr, stdin are all redirected to /dev/null to enforce your
+daemon is headless, so you'll need to sort out alternative logging, by, eg,
+syslog.
+
+
Fragmented messages
-------------------
fi
AM_CONDITIONAL(NO_CLIENT, test x$no_client = xyes)
+#
+#
+#
+AC_ARG_WITH(daemonize,
+ [ --without-daemonize dont build the daemonization api ],
+ [ no_daemonize=yes
+ ])
+
+AM_CONDITIONAL(NO_DAEMONIZE, test x$no_daemonize = xyes)
+
#
#
AC_ARG_ENABLE(mingw,
extension-deflate-frame.c extension-deflate-frame.h\
private-libwebsockets.h
+if NO_DAEMONIZE
+else
+dist_libwebsockets_la_SOURCES+= daemonize.c
+endif
+
if NO_CLIENT
else
dist_libwebsockets_la_SOURCES+= client.c \
void *buf, int len);
LWS_EXTERN int
+lws_daemonize(const char *_lock_path);
+
+LWS_EXTERN int
lws_send_pipe_choked(struct libwebsocket *wsi);
LWS_EXTERN unsigned char *