In the battle against HIV/AIDS, one of the biggest challenges for developing countries is finding a way to provide affordable, effective treatment. South Africa has decided to give free AIDS medicines to any citizen who needs them. Brazil has had a similar program for years. But the only way poor countries can afford to do that is by using cheaper generic versions of patented AIDS drugs.

The medicines in question are called anti-retroviral drugs. They can allow AIDS patients to live longer and more productive lives. But they are expensive. In the United States, a daily dose of three different anti-retrovirals can cost $10,000 a year for one person.

Multiply that by five-million, the number of South Africans with HIV, and a national treatment program seems out of reach. But generic versions of the drugs can bring the cost down to more manageable levels of less than $140 per person per year.

South Africa has joined a growing list of countries that are finding a way to give anti-retrovirals to any citizen who needs them by using generic drugs.

One of the major hurdles in getting to that point has been patent laws, and especially the TRIPS agreement, an international treaty governing intellectual property rights.

Drug companies in India started making generic anti-retrovirals years ago, but India has not yet signed the TRIPS accord, and so international patent regulations do not apply there. That meant the Indian companies could make their own versions of patented drugs, without the permission of the companies that hold the patents.

Other countries, including Brazil and Thailand, got around the TRIPS regulations by declaring AIDS a national emergency. That allowed them to waive the TRIPS patent protections and start producing generic AIDS drugs.

But South Africa, which has proportionally more HIV-positive people than any other country on earth, has never declared a state of emergency over AIDS. And South Africa is a signatory of the TRIPS accord. So, most South African drug companies stayed away from the anti-retroviral debate entirely.

One company was different. Aspen Pharmacare, the largest generic drug maker in Africa, started pursuing its own strategy for getting into the anti-retroviral business, without violating TRIPS. Aspen's chief operating officer, Linda Philip, says the company decided to go ahead, without waiting for government to lead the way.

"Remember, we were sitting with a government that said that the virus doesn't even cause AIDS. Now, if you've got a government sitting with that, they haven't even got their minds around what causes the disease, you're years off them rolling out any program," he said. "And they're only going to declare a national emergency when they have a program, they've accepted the fact that the virus causes the disease, and they're actually doing something about it. And we just figured that, if we waited till then, you would wait forever. It would happen eventually, but you'd wait too long."

Quietly and with very little publicity, Aspen Pharmacare started approaching the major international pharmaceutical companies, trying to talk them into giving Aspen what is known as a voluntary license. That means Aspen would have permission to make generic versions of the bigger companies' patented anti-retrovirals.

After years of work, the first company finally agreed. In June of this year, Aspen began making Stavudine, the first generic anti-retroviral drug to be manufactured in Africa. The company also has licenses for five other drugs, and hopes to begin making those as soon as the South African Medicines Control Council approves them.

Ms. Philip says voluntary licensing was almost unheard-of in the pharmaceutical industry before AIDS.

"People don't give up their patents. Because they've got to recoup the $800-million that they spent getting it to market. .... What you've got now is a social disease, with a lot of emotion attached to it. And they were in a new arena completely. They'd never had to do this negotiation around voluntary licensing," he said.

One of the things that helped convince the multi-national drug companies, activists say, was publicity. AIDS activists were calling the big drug makers greedy and insensitive, saying they cared more about profits than peoples' lives.

Ms. Philip says the pressure extends to Aspen and other generic manufacturers, as well. She says, from a public relations perspective, the company had to put Stavudine on the market at the lowest possible price, with minimal profit. But she says there was never really a question of giving the drugs away for free.

"That was never our chosen route," he said. Supplying free drugs is not sustainable for a business.... because they need their business to be sustainable. And it's very nice to be socially inclined and worry about the poor and dying. But unless you're getting some sort of return from a business point of view, how do you keep doing that?"

Ms. Philip says Aspen got into the anti-retroviral business not so much to make a profit, but because it is a South African company, with South African workers and South African customers. AIDS, she says, could hurt the company in exactly the same way it is hurting the rest of the country.

Aspen is currently in the process of rolling out its own treatment program for its employees, as other companies have already done, including mining giant Anglo American. Anglo decided that spending money on anti-retrovirals would, in the end, be cheaper than having to train thousands of new workers to replace the ones who were dying of AIDS.

But for Aspen Pharmacare, another part of the puzzle was the desire to show the South African government and the world that it is possible to produce a local solution to Africa's greatest crisis.

"To my way of thinking, Stavudine was symbolic," he said. "More than the actual medicine, it was symbolic of the fact that South Africa could come up with a solution. .... What we're hoping is that government will pick up not only on the supply of medicine, but the building of a capacity. Because today, it's AIDS - what's the disease going to be tomorrow? Is Africa going to go back again to the West and say, please, drop it in our hands? Or are we going to start taking ownership of these problems and developing our own solution?"

Aspen Pharmacare and three Indian drug makers have signed an agreement with the Clinton Foundation, set up by former U.S. President Bill Clinton to manufacture low-priced generic anti-retrovirals for nine countries in Africa and the Caribbean. As part of the deal, the companies agreed to open their books to Clinton Foundation experts, who found ways of cutting the prices of the drugs even lower than they had been.

The foundation says only about $50,000 people in sub-Saharan Africa are currently on anti-retroviral therapy, while another four million people need it right now.