The first step would be a colony that can produce and clean its own air and water and some of its food. This seem achievable in the near term. The second step is a full ecosystem (needs almost no nutrients from earth), which is much harder but I think biosphere 2 is a good proof of concept. Mars is much colder with less sunlight so it is a much harder problem on Mars. The finial step is an independent industrial base. You mentioned medicine, but I'm more concerned with the microprocessors to keep the automation running. Humanity can survive without medicine, and with a few easy things like penicillin we can do quite well (we can also avoid bringing the majority of diseases to Mars in the first place). Without automation I don't think one person can produce enough resource to sustain themselves in such a hostile environment.
Self-sufficiency is hard and I think a million people is a good estimation of how large a Mars colony would be before it became truly self sufficient.
The issues with getting something like an ecosystem on Mars would be much more dramatic, esp. given that while there are some ways of getting O2 and carbon, there isn't a source of nitrogen on Mars that we know (we assume there's fixed nitrogen in minerals, though that's very hard to breathe). Any loss of significant life forms would need to be replenished from Earth. And while some life forms will probably manage in 38% gravity, there's no reason to assume many would have long term viability (especially vertebrates like humans who depend on Earth gravity to function).
Getting an ecosystem on Mars that could support humans doesn't seem like it's in the realm of possibility to me, especially when there's good reason to believe humans themselves wouldn't be able to survive for long periods there unless something managed to solve that very hard problem. You could use a centrifuge for the long trip out (and nobody could survive without that), but you can't just live in a centrifuge on Mars forever.