Reunification of Poland by Silesian branch of Piast dynasty (most senior one) is good start (they were descendants of Władysław the Exile, oldest son of Bolesław III, while Cuiavian Piasts, who ruled reunited Poland IOTL, were descendants of youngest one, Kazimierz the Just. Even among Cuiavian branch Władysław Łokietek and Kazimierz the Great were not the most senior line, so they're unlikely to came with idea of Salic Law. There must be also precedence of king's brother taking throne over king's daughter or female line grandson (better more that once, so that became ingrained in tradition-medieval monarchies rarely had clearly definied rules of succession).
Also-canonize Mieszko I (so we have House of Piast descending from Saint, who brought Poland to Christian faith) that should help too.