added flycheck mode support, reintroduced compile-mode