Dominions shipbuilding capabilities lied predominantly in automation.
The Federation had this kind of technology for a long time - its not our problem the writers progressively made the Feds stupid as times went on and showed automation and proper use of advanced technology in only a fraction of things (which was mostly a reflection of our real-life abilities taken to practical level).
It was also mentioned that the Federation WAS able to match the Dominion in ship-building just barely.
However, we essentially got an impression that humanoids would be working as much as they do today - which was completely idiotic given the level of technology that WE have to automate just over 75% of jobs today, let alone the Federation which is supposed to be some 370 years ahead of us and doesn't use money at all.
The Dominion however had a distinct advantage in pumping out armies of clones.
Mind you, the Feds have the same capabilities (mostly), but they just don't opt to using them due to their ways of thinking (and the Feds aren't war oriented).
Alternatively, wars of this scale would probably be fought with fully automated ships (and remotely controlled) ships.
One little mishap that happened in the past would hardly stop the Feds from pursuing the technology (only in a bit more cautious capacity).
What we saw was basically: 1 issue that unfortunately resulted in deaths, and the whole project gets scrapped.
If anything the M5 computer was a viable project that should have been pursued even more after the accident, learning from it.
However, scifi writers also apparently have this insatiable and idiotic (not to mention groundless) desire to create ridiculous circumstances where technology is always somehow bound to 'turn against its creators' (which is utter stupidity).