Do not write manifest down if there was a compilation error, closes #1833