Piety definitely increases when a general as governor builds a church. It's almost automatic for low-piety generals to gain +1 piety for building a small church at the beginning of the game. However, subsequent church upgrades and the recruitment of priests don't seem to help so much as time goes on. I think there's a fractional system of "piety points" between the levels shown on character cards, so that it takes increasing numbers of "pious deeds" to gain levels. OTOH, of course, as time goes on many generals pick up anti-pious traits and retainers so that might be why you don't see piety increase when building a cathedral--you might not have noticed its decrease beforehand.

I haven't seen any general gain piety just from having a priest around.

Unlike Big Tex, I don't see any real connection between chivalry and piety--they seem independent to me. You gain dread any time you do something "dreadful" like butcher prisoners and exterminate a city, regardless of whether the victims were believers or infidels of your religion. OTOH, you can gain piety for butchering beaucoup infidels, so it's possible to end up with high levels of both dread and piety.

I'm not certain, but I think giving LOTS money to the Pope and being his ally will give your king a piety boost.

This concern about a general's piety is out of fear of the Inquisition, but IMHO there's no real reason to worry about that. Inquisitors only seem to come around when either you've got the Pope hating you or you've allowed significant levels of heresy in your domains. If you keep His Venality well bribed, and you have sufficient priests roaming around to have all your provinces 95%+ Catholic, the Inquisition won't bother you. Then your generals are free to have low piety. But if an inquisitor does come around, high piety won't save them anyway. It seems to be a straight-up contest of piety between your guy and the inquisitor, and inquisitors all seem to have 10 piety, so even your 8-piety general's gonna burn. Hence, worrying about piety is pointless ;).

This all might sound a bit counterintuitive and frustrating, but only if you assume the *M2TW* Pope and your generals are actually sincere about religion. If you instead view them all as cynical men of the world, concerned only with money and power, then it all makes perfect sense. Piety is as you are seen in the eyes of the superstitious people, not the pope :).

IMHO, the best way to view the *M2TW* Catholic Church is as a huge organized crime syndicate. The pope is the godfather and all temporal rulers, including your generals, are his capos running territories for the pope. The primary purpose of the syndicate is to make the pope rich from the pyramid scheme starting with the collection plate in every parish church. It's your job as one of the pope's capos to ensure that the roots of this pyramid in your territory function smoothly. The pope hates heresy because that diverts the peasants' pennies from his cash flow into that of the rival sect. And of course your ruler, as a capo, has to render tribute and cuts of all his own deals to the godfather as well.

So, if you fail in either of these jobs, the pope/godfather will send his inquisitors/enforcers to rub you out. If you get into a fight with another capo, that's also bad for the pope's pyramid scheme because money's diverted to your arsenals instead of going to him. That's why you get excommunicated, so the other capos can beat on you, and you could well see some enforcers, too, and it will all be a strong lesson to the other capos. But if you do your job right, so the peasants are all dutiful tything Catholics and you dump a lot of your take in the pope's lap, then your generals can be huge sinners and the pope won't care.

So what's the purpose of piety in this arrangement? Like I said, it's how the common people see your ruler. The pope's goal, of course, is to make the whole world Catholic, so everybody will tythe to him. But making the world Catholic requires crusades, which in turn require cannonfodder, and that only flocks to the banner if there's an overtly religious overtone. Thus, you need some public show of sharing the public's superstitions ;).