logmatcher: added LogMatcherOptions struct and related cfg-grammar rules

Whenever a LogMatcher instance was to be created (most notably in filter and
rewrite rules) we had a chicken and egg problem. The flags to be used by
the LogMatcher instance was stored within the LogMatcher instance, however
the kind of LogMatcher instance (posix, pcre, etc) was also parsed together
with flags.

This meant that parsing code had to create a default LogMatcher, which
was replaced when the actual type was parsed. This replacement
was not straightforward though, we had to keep the flags value in case
it had been parsed previously.

This patch delegates LogMatcher parsing to the core cfg-grammar, users
only need to invoke the matcher_option rule and set last_matcher_options
in vein similar to other *Options stuff.

The patch also improves error handling, as flags/regexp compile
errors are propagated back to the grammar, so we get a nice error page. This
required an API change to return a GError in case of failure.

Signed-off-by: Balazs Scheidler <bazsi@balabit.hu>