By "many" you perhaps mean "many American". In Russian engines it's mostly a single shaft.
> The main cost of doing it over gas generators (other than oxidation-resistant superalloys...) is that all parts of the engine sort of circularly depend on each other...
Yes, rocket engine is usually a complex dynamic system, with deep feedback loops. You can still get gas generator and turbines with pumps tested separately, but you need to measure dynamic properties - like resonance frequencies - in order to have better chances of the good work when the system is integrated.