Correctly gather return value from compile commands