When I had my windshield replaced a couple years ago, the tech put the gasket around the windshield prior to lifting it up and placing it in position. The 4 corner pieces were popped in after the windshield install. This was a 1 piece windshield.
I don't remember if the adhesive they put around the window opening stuck to the glass or the gasket. I think it would be risky to try replacing the gasket with the windshield in place.
I would call a glass company and ask for a quote to see what they say.
Earl & Sharon, 2008 Fleetwood Expedition, ISB 6.7
1995 Jeep YJ/2013 Chevy Sonic