Commits


update imsg test: amused now needs the new APIs


add compat for getdtablesize()


add an libao audio backend This backend uses libao to play music. It's a bit convoluted since libao doesn't provide an async interface, so we have to run it in a separate thread. Then, there's some notification via a shared socketpair because the main loop is around poll(). This actually doesn't work OOTB on OpenBSD due to a restrictive pledge(), but it's not a issue since sndio should be used there. libao is the last resort.


move timespecsub compat out of ev.c


tweak the configure - more consistent naming for libs (LDADD_LIB_*) - allow to change CC and CFLAGS as arguments - allow to specify the LDADD_LIB_* as arguments


add configure check for libmd; needed on some OSes for amused-web On the BSDs the SHA1Init() and friends are part of libc, while on linux (and maybe other systems as well) we need an implementation of these function: libmd for example.


fix the test for getdtablecount The configure ran it but wasn't present in the tests.c file. Will need to switch away from this all-in-one someday...


switch from libevent to a smaller, thin wrapper around poll() libevent is a very cool library, I like its APIs and enjoy using it. However, for amused it is maybe a bit too much since it doesn't deal with too many file descriptors. Amused only needs to monitor one fd for the player process and the currently connected clients. Given that it runs per-user locally, having more than a dozen of fds open is very, very rare.


configure: allow to select the audio backend


fix sndio detection the compiler may complain that there's no return: tests.c: In function 'main': tests.c:954: warning: control reaches end of non-void function spotted by the OpenBSD bulk builds on sparc64 (using gcc 4.2)


fix landlock detection apparently it's not always possible to include both linux/prctl.h and sys/prctl.h.


use (a modified version of) kristaps' oconfigure see GitHub issue #1