daemonization, io socket and file redirection
implement err.h

valgrind reported invalid reads/writes with glibc err[x]|warn[x] (in
glibc printf) when stdio had been redirected in between.

define _progname (pointing to argv[0])
Merge pull request #405 from LudwigOrtmann/issue161

daemonization, io socket and file redirection
reduce minimal timer from 100ms to 10ms
fix: native hwtimer backend emulation

searching for the next pending timer was broken
this commit rewrites this functionality