configure.ac: Decreased required autoconf version.

To be able to compile on Ubuntu Precise. There is nothing AC 2.69 version
specific thing in configure.ac, it can happily compile with 2.68, which
is present in Precise.
Also added m4/ directory, because it seems, that autoreconf does not
create this automatically.
trigger-source: Add an option to set the triggered message text

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
trigger-source: Code cleanup

Instead of having trigger_freq and trigger_message in both TriggerSource
and TriggerSourceDriver (a borrowed reference in the former), have an
inline struct in TriggerSourceDriver, to which a pointer is stored in
TriggerSource.

This way adding new options in the future becomes much easier, as they
will be available to TriggerSource automatically.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
rss: Added rss destination module.

A very simple destination module, which can offer log messages as
an rss feed.

Example config:

destination d_rss {
   rss(
     port(5555)
     feed_title("RSS")
     entry_title("$MESSAGE")
     entry_description("$MESSAGE")
   );
};

Signed-off-by: Tusa Viktor <tusavik@gmail.com>
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
Makefile.am: Disable a big set of bison warnings

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
configure.ac: Remove the bison check

The bison check was inflexible and buggy, removed. If any platforms
break because of this, I'll add more documentation to point at needing
bison.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
README.md: Mention the RSS destination too

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
README.md: Update the license

With the RSS destination included, it's time to improve the wording of
the copyright text.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
NEWS: Finalise the 0.1.0 release date

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
Makefile.am: Add -d to AM_YFLAGS

We need the -d flag to create the header files too.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
riemann: Fix a compiler warning

Use a gint64 when dealing with 64-bit numbers, instead of a glong.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
basicfuncs-plus, rss: Link against syslog-ng and eventlog

Although the linking is not necessary, because both libsyslog-ng and
libeventlog will be loaded by the parent program anyway, it's nicer if
we do link to them, and it avoids warnings too. Plus we get better
dependency information.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
Makefile.am: Do not ship generated grammar files

The generated grammar files are tied to a particular syslog-ng version,
and are not reusable. The tarball should compile with all supported
versions of syslog-ng, regardless of grammar files.

For this reason, BUILT_SOURCES have been dropped, and nodist_* variables
are used instead. This also means that one needs flex & bison to compile
the Incubator, which is now noted in the README.

This fixes #5.

Reported-by: Peter Czanik <czanik@balabit.hu>
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
README.md: Update the syslog-ng github repo URL

The source repository has been moved to an unversioned repo some time
ago, so update the reference. While the versioned repository will
continue working, it is better to point people towards the canonical one
instead.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
basicfuncs-plus: Disable $(state) when glib is too old

When compiling on systems with glib older than 2.32, disable the
$(state) template function, because that requires features not present
in earlier versions. This fixes #4.

Reported-by: Peter Czanik <czanik@balabit.hu>
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
riemann: Fix the Makefile.am

The recent change that added nodist_* prefixes broke the Riemann
destination, and made automake emit a warning. Fixed the variable name
that caused all this.

Reported-by: Peter Czanik <czanik@balabit.hu>
Signed-off-by: Gergely Nagy <algernon@balabit.hu>
Revert "Makefile.am: Do not ship generated grammar files"

This reverts commits cb12ba8ef1fcac6b789485e9c8381ea04c59fda2 and
6872bd6360689e42875535096b5049f67ba23367.
Makefile.am: Do not ship generated grammar files, properly

This patch prevents make dist from shipping generated grammar files,
doing so in a more portable, reliable way than the previous, now
reverted patches.

Reported-by: Peter Czanik <czanik@balabit.hu>
Signed-off-by: Gergely Nagy <algernon@balabit.hu>
lua: Added simple version of lua destination.

Usage:

  destination d_lua {
    lua(
      script("test.lua")
      init-func("test_init")
      queue-func("test_queue")
      template("$MESSAGE")
    );
  };

Parameters:
 * script: the name of the Lua file which contains the functions for the
   destination.
 * init-func: the name of the Lua function which is called during
   initialization of the destination.
 * queue-func: each message reaching this destination is formatted using
   the template parameter, and passed to this function as a Lua string.
 * template: can be omitted, it's default value is "$MESSAGE"

Each lua destination has it's own state, so init and queue functions can
have side effects, and global variables are kept between init and
queue calls.

Example lua file:

--BEGIN
function test_init()
  print "Init called!"
  counter = 0
end

function test_queue
  counter = counter + 1
  print(msg  .. " " .. tostring(counter))
end
--END
README.md: Add a pointer and some notes about the Lua destination

Signed-off-by: Gergely Nagy <algernon@balabit.hu>