Fixes for restore objects in python-fd
Refactor restore object handling.

- Send also FT_PLUGIN_CONFIG restore objects as part of the
  send_restore_objects() function.
- Send override plugin options before sending any restore objects.
- send_restore_objects() function got two extra arguments that allow you
  to pass a JobId and a boolean if it needs to send the global restore
  objects or the ones specific to the given JobId.
- On an incremental and differential backup we lookup the previous Job on
  which we are based and lookup the restore objects created by that Job
  and send those to the file daemon so they can be used as information
  on what config the previous backup either used or generated as
  information for a next backup.
Use normal read/write API instead of fread/fwrite.

Attribute spooling for whatever reason uses fread/fwrite for
reading and writing spool files but it also has all kind of
other low level interface calls. See little sense in using
stdio buffering for writing attribute spool files.
Fix problem with Job Lookup.

Only perform lookup of previous Job when we found a JobName.
Drop the duplicate hash table implementation.

Findlib has a hash table implementation for keeping hardlinked files
its cleaner to use the htable class we already have in the generic
library. So this patch adds support for binary keys in the htable class
so we can store there the combined inode/device key. We now also use the
hash_malloc of the htable class which allocates memory from a big memory
block so it should also scale a bit better.
Add proper headers to python scripts.
Remove trademark symbol from Python header.
Use an enum and bit fields for File Option flags.

We will run out of bits for the fileopts on 32 bits so switch to a
proper bitmap and use the set_bit/clear_bit/bit_is_set macros.
Hooks for doing acl/xattr save and restore from plugin.
Make python-fd work with new flags bitmap.
Skip autoexcluding FilesNotToBackup if configured

If the autoexclude = no fileset option is set, we do
not automatically exclude entries form the FilesNotToBackup
Registry Key
Fix problems with autoexlude

- We now do not always create a new options block, only if none exists.

- Because of known wrong-formatted entry in FilesNotToBackup Registry
  Key in W2k3/XP SP1 we check for single characters and skip them.

- We print an information output if we skip files because of an empty
  options block.

Fixes #360: Incremental Backups with fd Version 14 fail to
include files
Refactor daemon plugin handling.

Major refactoring for allowing to drop the one-to-one plugin and
plugin context relationship. We eventually want to allow multiple
instances of one plugin (python plugin comes to mind). When we use
an alist for storing the plugin context which has a pointer to the
actual plugin that the context is linked to we can easily use the
actual callback we need to call in the plugin with the active context.
As we are no longer walking the shared plugin alist we also don't need
to always use the foreach_alist_index to be sure we don't run into
problems with multi threading.

Some state is captured in the shared plugin data which is used by
multiple threads in the filed. This is probably not to smart as it
means that the state is shared between multiple threads and so multiple
backup jobs what is not something you want. As this is mostly core code
and probably not used by any important plugin in the wild it might for
now not be a big problem but it may become a problem if we implement
some more filed plugins.

Added the bDirEventNewPluginOptions event which will allow the dir to
implement the loading of multiple instances of the same plugin each with
its private context.

Added the bsdEventNewPluginOptions event which will allow the storage
daemon to implement the loading of multiple instances of the same plugin
each with its private context.
First attempt to move python-dir plugin to use plugin options.
First attempt to move python-sd plugin to use plugin options.
Don't print an extra \n for protocol messages.
Implement missing SD plugin variables.

Seems when designing the SD plugin variables a copy was made of the
stuff available in the director. That of course doesn't work to well in
the SD as some info is just not available there. Implemented now as many
vars which can be filled with valuable info and removed the others
which make little sense.

Also did a cleanup of all plugin files to output the debug messages
generated for a variable retrieval to look the same.
Add new plugin variable handling to python-sd plugin.
Fix syslog message destinations.

- Up until now every message send to syslog was logged as LOG_DAEMON and LOG_ERR
- This code adds the knowledge to use the right log level for things
  like debug, notice, info, error and critical errors into syslog.
- The message destination parsing now also allows you to specifiy an
  syslog facility that should be used to log the syslog messages against.

e.g. the following should now work:

  syslog = local0 = all

To get all messages logged using the right log level to the LOG_LOCAL0 facility.
Add ANSI label compatibility with Bacula ANSI labels.