It can, capital depreciated continuously and there'd be an annual budget for replacing panels. If the new panels are much more expensive, we'd expect the cost to start rising.
Obviously everyone would rather be using solar rather than oil if there is going to be a war because the feedback loop is slower, but it is still affected by foreign events.
> This is in process now, but there are efforts by the fossil fuel industry to prevent that.
Maybe, but the environmentalists have been flailing and failing to stop the fossil fuel industry for decades, because people want cheap energy. If renewables actually work the fossil fuel industry will have about as much success stopping them, ie, none whatever. There wasn't ever strong enough political support for renewables to escape economics, but there is even less for fossil fuels. Nobody is in favour of them on an ideological basis.