Further daemonization

- Added cfg file cmd line arg
- Changed Daemon class to be more RAII
- Added log file and redirected stdout/stderr to it
- Fixed cygwin build
Added precompiled header