Ideally, sure, the government would make sure to prioritize everything in an optimal way. Realistically, the government is run by politicians, who are in turn run by vested interests.
Not saying that's the way it should be, just that it's the way it is.
So, installing rooftop solar (and/or geothermal cooling/heating) is a good thing to do, if you can afford it. It won't solve the problem, but it will ameliorate it enough to buy us a little more time for the vested interests to figure out that letting the world burn (figuratively) is bad for business.