Drug development is generally not publically funded. It is an expensive, long-term, high risk investment. In 2001, the
average cost of developing a new prescription drug was $802 million, and took from 10 to 15 years. That does not include any marketing costs. Yes drug companies spend a ton of money on marketing,
eclipsing their spending on R&D. Yes drug companies are
highly profitable, high-risk investments generally produce higher return than low risk investments. Investment and advertising seem like things generally associated with free markets.
If you want to argue whether drug companies are sleezy and annoying and shouldn't be allowed to advertise on TV and are filthy rich and should do more to offer life-saving drugs to people who can't afford them, you'll have to find someone else, because I agree with you.
Your assertion that the US has "relatively low levels of access to basic health care" is also true, but unrelated. I have relatively low levels of access to a Ferrari. That doesn't mean the automotive industry is not a free market.
You are correct that even a capitalist like me can not cure viral disease. But neither can any other economic system. But what about productivity lost for conditions for which there are known treatments? In Canada, the median wait time to get treatment from a specialist is more than 17 weeks (see page 25 in
this study, warning, it's a PDF). That's 17 weeks of reduced productivity for patients with conditions that have known treatments.
The economics of the US healthcare industry are complex. The Hippocratic Oath is often at odds with the economic desires of those who provide care. Crafting public policy that works for patients as well as providers is where all the action and debate is at, not whether the US healthcare industry is a free market or not.