Maybe some individual country will have some collapse, but all of human civilization will not.
I.maintain that if you're worried about any of that, you are still better off stockpiling panels now, than developing ways to make your own much worse ones in your backyard.
DIY photovoltaics can be a fun hobby but for someone worried about an actual collapse they can acquire a lifetime supply of solar panels and batteries for less money and time than setting up a custom fab that's able to operate in a collapse situation.