In essence, a film would only have to make �2 million and one penny to be in profit, in your example. But how to do that?...
First thing to mention is that all film producers would secure a form of insurance called a 'completion bond' from one of the several firms who specialise in this area. Just in case something terrible happens, like the set being wiped out in a flood, as happened to the recent Terry Gilliam project 'Don Quixote'.
Once that is done, and you've presumably made the film, you need a distributor if anyone is going to see the film in a movie theatre. Why do you need a distributor? Because they take the risk of printing thousands of copies of your film print to send around the world to each theatre. They are interested in making a profit, so they prefer action-packed Hollywood films that they reckon will get a big mainstream audience.
So what if your film isn't so mainstream? Your main hope then is to convince a big distributor to add your film as a rider with a larger more populist film. The distributor basically makes movie theatres accept a contract that forces them to show a few other films alongside the big exciting film they really want.
Nowadays, most movie theatre chains and distributors are owned by the same corporations - and they often own a few 'independent' risk-taking film production companies as well, eg Buena Vista/Disney own Miramax films. This makes it easier for them to judge whether they should risk a film project, I guess. But it makes it harder for a true 'independent' to show a film and make any money.