configure.ac: Support compiling against a syslog-ng with internal ivykis

If syslog-ng was compiled with an internal ivykis, it will (in upcoming
versions) install the ivykis headers and adjust CFLAGS accordingly, so
that modules can be compiled against libsyslog-ng alone. This will be
marked with an "ivykis=internal" in the syslog-ng pkg-config control
file. When that is found, the Incubator need not look for a system-wide
Ivykis installation.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
configure.ac: Do not clobber LIBS when looking for libperl

We're using ExtUtils::Embed to figure out the libraries needed for the
perl module, do not clobber the global LIBS when verifying that libperl
exists. Previously, everything got linked against libperl, which is
undesired.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
rss: Fix the module linking

Correct the name of a variable, so that the RSS module will get
correctly linked to libsyslog-ng and others.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
configure.ac: Use ExtUtils::Embed to detect libperl

Reported-by: Peter Czanik <czanik@balabit.hu>
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
Merge pull request #45 from algernon/h/viral-libperl-fix

perl fixes
Merge pull request #46 from algernon/h/rss/linking-fix

rss: Fix the module linking
release: Preparations for 0.3.1
configure.ac: Added disable switches for features dependending on external libs.

This makes packagers' work easier, because can choose whether they want to introduce new dependency for
their package.
configure: enable-*=yes options make features mandatory.

If a feature is switched on by --enable-feature=yes, then if a
dependency for this feature is missing, configure fails. If it is
switched on by --enable-feature=auto, then if a dependency is missing,
the feature is switched off.
Merge pull request #44 from algernon/f/internal-ivykis

configure.ac: Support compiling against a syslog-ng with internal ivykis
getent: Remove an unnecessary include statement

We do not use <features.h> anywhere, no need to include it. This makes
the Incubator compile again on FreeBSD, thus fixes #50.

Reported-by: Peter Czanik <czanik@balabit.hu>
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
Add support for $(getent protocols)
add the new protocols file to EXTRA_DIST
Merge pull request #54 from algernon/h/tfgetent-freebsd

getent: Remove an unnecessary include statement
Merge pull request #55 from ccin2p3/f/getent-protocols

Add support for $(getent protocols)
lua: Reworked Lua destination to be a threaded destination.

Lua was the simplest destination driver of all kind, but because it lacked any
kind of queue management or synchronization, it was easy to get it killed by
several parallel input connections. Not it was fixed by switching to threaded
destination driver.
lua: Globals are now contants and params feature added.

Globals are now constants as they should ever be. There is a new feature
with the params() option, which works exactly as the old globals(), eg.
uses value pairs, and templates can be used. The result is manifested as a lua
table as the second parameter of the queue func. Although the same result
can be achieved by using raw mode and Template "class" in Lua, using params
is more comfortable in some cases (eg: SCL).

Examples:

conf:

destination d_lua {
  lua( queue-func("test_queue") globals( var1("test") ) params( param1("$HOST") ) );
};

lua:

function test_queue(msg, params)
  print(msg)
  print(params.param1)
end
perl: Run the entire Perl thing in a single thread

Instead of having init/deinit in one thread and queue in another, pull
all of them together into the worker thread. We can avoid confusing Perl
to the point of crashing by organizing things this way. This fixes #53.

Reported-by: Fabien Wernli
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
Merge pull request #61 from algernon/h/perl/same-thread

perl: Run the entire Perl thing in a single thread
Merge pull request #59 from talien/f/lua-threaded-dest-driver

lua: Reworked Lua destination to be a threaded destination.