naemon release 0.8.0

Signed-off-by: Sven Nierlein <Sven.Nierlein@consol.de>
lib/iobroker: Silence valgrind on careless iobroker_close() use

When iobroker_close() was called with a negative filedescriptor we
still issued close() on it, which makes valgrind scream bloody
murder. This patch should fix that.

Signed-off-by: Andreas Ericsson <ae@op5.se>
Make it a bit easier to build addon projects against naemon headers

The previous defaults.h file included autotool macros that were only
set as preprocessor macros on the command line, which made defaults.h
unusable from addon projects.

With this patch we add a buildopts.h, where projects that don't want
to link against the naemon sources but still want to know which
defaults to use (for whatever reason) can #include the defaults.h
file and get the compile-time defaults.

Signed-off-by: Andreas Ericsson <ae@op5.se>
lib/worker: Be more anal about not loosing check output

When multiple checks run concurrently, we can get a signal while still
reading check output. This could cause us to forget about reading the
rest of the output. Be careful not to do that.

This fixes bug op5#8331.

Reviewed-and-discovered-by: Robin Sonefors <robin.sonefors@op5.com>
Signed-off-by: Andreas Ericsson <ae@op5.se>
configure.ac: Make autoreconf run cleanly on cent5

First, it turns out that autoconf 2.59 actually works out. Second,
AC_PROG_LIBTOOL should be used by autoconf projects when they use
libtool - at least older versions. Third, the m4 directory isn't checked
in and isn't autocreated, so remove the AC_CONFIG_MACRO_DIR again - if
you want to use it, go do something sane with m4. I'm not a fan of m4.

Signed-off-by: Robin Sonefors <robin.sonefors@op5.com>
lib/worker: Stop reading if nothing more to read

In the last patch, I over-the-shoulder-programmed away the support for
exiting gather_output when the process is shutting down. Ooups.

Change-Id: I6b041736df4d05899d1686d875e42a1d3c9ce056
Signed-off-by: Robin Sonefors <robin.sonefors@op5.com>
workers: Count correctly when workers are chocked

When a worker is choked, we would decrement the number of active jobs
without first incrementing them. This leads to seemingly 4.2 billion
active jobs on said worker, which makes nagios refuse to schedule any
more checks in that direction. Increment before decrementing, so the
numbers add up.

Change-Id: I85bda501b1671274750f26db0873a24e79ca9e0c
Signed-off-by: Robin Sonefors <robin.sonefors@op5.com>
Merge branch 'dev/lost-output'