Galileo was not treated fairly but you mustn't forget that he was a Christian, was supported by a lot of ChristiansIt's true that he had a lot of christian friends, among them, before he published "Dialogue", the pope. But it's worth noting that even though the pope even had had written poems to Galileo and enjoyed long conversations with him, their friendship ended after "Dialogue". After publication they never talked again, perhaps mainly because the pope thought (more or less correctly) that one of the fictional characters in the book was a caricature of him.
Again, Galileo was not treated fairly. But he was not treated as horribly as is commonly thought, and the Church was not generally anti-science. And Christianity is certainly not anti-science.