Was the Civil War inevitable? Or was it avoidable?

Was the Civil War inevitable? Or was it avoidable? Could Lincoln have done any different to avoid the war?