Work a tech job for 5-10 years saving money for when you quit, avoid expensive relationships / having dependents or have a spouse who can support you, save enough to live on ramen in the middle of nowhere for a couple of years with a bunch of roommates. Is that really Andrew Carnegie level of wealth?
Many of us have done exactly that, it just takes years of planning and being fortunate enough not to have severe medical conditions or loves ones you need to take care of with all of your finances.
Again, most people would much rather tell themselves that the reason why they're not entrepreneurs is because they're not Bill Gates rich, rather than making the sacrifices most entrepreneurs have to make to get things going.
I think the problem is that if you work a tech job for 5-10 years you are way out of the middle class. Middle class is generally 50-100k/year. 5-10 years of experience in tech should put you well past 100...
Your idea of "saving money for when you quit" doesn't work for middle class as the amount you save is not enough for "living on ramen for a few years" -- it will likely not be enough to even pay rent.
Really depends on where you live, though. If you make 75k-100k in the Bay Area, you're far from wealthy, I believe poverty line was 100k for a family of 4 there as of this year.
100k in Dallas is a different conversation though.
Put another way, the definitions of middle-class that encompass such people are ones that separate them from the regular joe, limiting the "middle" class to the top 30% or so of the income distribution rather than placing them at the median.