Added exitting when compile failed.