The static potential in QCD to two loops