src/Makefile: Link rrdcached against ALL_LIBS directly.

rrdcached uses glib and, thus, needs to be linked against the lib directly.
While some linkers work fine since librrd_th is linked against ALL_LIBS, some
other linkers don't.
Fixed various unused variable compiler warnings.
Fixed invalid type conversions.
rrd_daemon: Fixed the resolved_path argument passed to realpath().

The function expects a character pointer, not a pointer to an array of
character pointers.
added option to strip path away when using rrdcached
enabled template for rrdcached updates
this essentially "expands" the template to a "normal" update
based on the structure from the file itself.
This structure is cached in a GTree until the process dies - no validation is done to check if the file changed in the meantime
Merge pull request #462 from msperl/master-cached+template

enable --template when using --daemon
Merge pull request #460 from tokkee/build

Fixed various compiler warnings
Fix #463 - account for step in xport json

Final element check changed from end to end-step
Merge pull request #464 from aelse/issue463-fix-xport-json

Fix #463 - account for step in xport json