First-order phase transition in the SU(3) gauge theory at finite temperature