How did Prussia build up its power?