Build up and pinning of linear polarization in the Bose condensates of exciton polaritons