Fix enabling compilation-mode for remote file