fix typo, localststedir->localstatedir
pull in libgen.h, needed for basename()
Merge pull request #401 from sthen/master

fixes for rrdupdate, and rrdcached doc