Config engine redesign Phase 1

This whole wad is the first phase of a bigger full overhaul of the config
engine. The following is in here:

1)
   Instead of using function pointers for storing the config parser function
   to call use integer types which are translated at runtime to the correct
   function to call. This should work around hardening being performed on
   shared libraries on some Linux platforms. On those platforms the actual
   comparing of the function pointers fail, using integers for the different
   data types makes it also possible to use an elegant switch to jump to the
   correct parsing function instead of using an endless set of ifs needed when
   comparing memory addresses of functions.

   An extra side effect of not using function pointers is that the store functions
   don't need to be global so the parse_conf.c in the shared library only exports
   10 instead of 32 symbols and also the daemon specific store function can be
   local only functions. The only thing needed is a callback to a dispatch function
   in the daemon when it uses non standard config items which are not of a generic
   type (e.g. not bool, integer etc but things like protocol etc.) which leads to a
   very small extra payload which is probably not even measurable.

2)
   Bring config engine to 2013 and don't polute namespace.

   Implement a TODO from June 2008 and get ride of a slack of global
   variables used by the config engine. The code seems to be have been
   refactored in 2008 to access most configfile parsing via the CONFIG
   class and it already has most of the needed structures which also were
   kept as global variables. From now on the config engine is accessed via
   the CONFIG class and only res_all is left as global variable. As a side
   effect the config CLASS is now available as my_config and is a global
   variable.

   Global variable introduced:

   - CLASS CONFIG *my_config (Global configuration)

   Global variables removed:

   - res_all_size
   - r_first
   - r_last
   - resources
   - res_head

   It should be possible also to get ride of res_all but that needs some
   more testing. And is currently not very high on our urgency map.

3)
   Fix long standing TODO to remove the MAXSTRING definition.
   Use POOLMEM and POOL_MEM to replace the fixed sized buffers.

4)
   First basic part of printing config information out from the internal
   tables. We will enhance this in the second phase to be more generic
   and to allow it to write out the config maybe in different formats.
   (JSON/XML comes to mind).

Fixes #59: bareos failed to start when linked with hardening linker flags LDFLAGS
Fixes #164: Remove MAXSTRING variable
Fixes #202: Config engine redesign
Rebuild configure and config.h.in
Updated version to 13.4.0
Enable __builtin_va_copy on mingw.
Fix problems in qt programs with new config engine.
Fix to get ride of last MAXSTRING variables.

And fixes to make testfind work again after some time. As no one
probably uses this ever it was broken for some time already.
See if enabling hardening on Ubuntu is now fixed.

We remove the unsetting of the LDFLAGS so on Ubuntu it should now start
using the default hardening flags again.
When using multiple catalogs always the first is chosen.

With the introduction of the autoselection of the right catalog when
none is selected we also auto select a catalog in the pool resource.
That is of course wrong as that means every pool always has an
explicit override of the catalog to use to the first catalog which
makes the override in the client useless.

Fixes #229: When using multiple catalogs always the first is chosen.
Fix problem with copy/migrate jobs.

Now we select the right catalog and not always set a pool override of
the catalog we run into a crash in set_jcr_defaults as that now
derefences the job->client pointer which for copy/migrate jobs may not
have been set. This patch adds an extra catalog override method to
allow you to set a job specfic catalog setting. If none is set the
default (first) catalog is choosen for the copy/migration Job.
Update README.md with important new stuff in 13.3.x
Fix typo.
Fix compiler warning.

NULL is NOT 0 (zero).
Fix typo.
Fix compiler warning.
Missing handling of "close" errors

When backing up on a CIFS target (others?), a full (remote) file system
is not detected until close() returns (returning -1 and setting errno).
However, the return value is not verified, and the incorrect write
operation is not detected. The final job result is "ok", but the volume
files are small or empty.

Fixes #233: Missing handling of "close" errors

Signed-off-by: Marco van Wieringen <marco.van.wieringen@bareos.com>
Tweak layout.
Fix compiling without any compression.

When you don't have zlib, lzo2 or fastlz the code didn't compile
due to one missing dummy prototype. And two dummy prototypes had
wrong typed arguments to their non dummy counterparts.
Merge branch 'master' of https://github.com/bareos/bareos