add daemon and debug flags