And this is the way it stayed for a while. It was mostly academics enjoying the fruits of their collaborative labors. Industry wasn't too worried. They had mostly provided software to these folks for free or for heavy discounts anyway, and there were plenty of good ideas and useful little tidbits of software coming out of this movement.
So there was a certain amount of idealism involved, though it was a sort of scientific idealism and an aversion to the kind of wasted parallel effort that the competitive commercial process naturally engenders. But it was far from being anti-capitalistic. In fact, it allowed ideas to compete in an open marketplace, not just in the enclosed sandboxes of corporate-sponsored R&D facilities.
But let's not denigrate the sandboxes. The ideas that had been coming out of places like Bell Labs and Xerox PARC were pretty amazing. In fact, if the open source movement has taught us one thing, it's that there's really no substitute for the kind of sponsorship of R&D that's done by corporations, academic institutions, and governments. What we learned, though, was that a lot of the dynamism that was coming out of these fertile nesting grounds was never making it into profitable commercial products, and ended up lying idle. That's generally a source of great frustration for the software producing class. In fact, even most software that ends up working great and being useful never ends up being a profitable product, because most software is actually not written to be sold but is for internal use in a particular company or institution.
This is the hidden bonanza that really made the open source movement take off like it did. As it worked out, not that much software ended up in the open source ecosystem because some well meaning programmer decided that the world needed a better widget. Most of the software that ended up being open source was the result of work that was done to achieve a particular self-interested purpose, and would either "go to waste" if it weren't shared, or the author preferred to share the burden of maintaining and advancing the software with others. Why share it? Because it's less work that way!
It turned out that there were some very real financial incentives for individuals and organizations to participate in software sharing. That's why they did it. It wasn't because they hated Capitalism. It was because of Capitalism. They could save money on the front side by using free software instead of licensing commercial software, then when they had to do a little tweaking, or even had to write applications to run on top of the free software they'd used, it was to their benefit to share that code with other people in the community, because by collaborating on software they all needed instead of each person re-inventing the wheel in isolation, they could all save time and effort. Now, this is the standard open source sales pitch, and to be perfectly honest, I'm sure there are many examples of companies that have gone down this route with the intention of saving money that could actually have spent less money licensing off-the-shelf software instead, when all is said and done. Some of these firms may even have been influenced by engineers who were more enthusiastic about using the open source software because of some ideological ulterior motive or even a simple hatred of Microsoft (or Oracle, or whoever). Open source is no panacea, but it's not snake oil either. For the vast majority of open source software users, it's all about money. And most of the largest implementations were only made after the green eyeshade folks gave it an enthusiastic thumbs up.