Thousands of fans packed a Cape Town stadium on Saturday to pay their respects to the South African singer, Brenda Fassie.
10,000 crammed the Cape Town stadium to pay respects
A number of fans were taken to hospital after they were crushed against barricades by the crowds.
Fassie, who had been at the forefront of South African music for 20 years, died earlier this month after a long battle against drug addiction.
President Thabo Mbeki used his funeral address to oppose drug abuse.
"We need to ensure that we save our artists from those problems. We know that even here in Cape Town, even in our schools we already have the problem of drugs," Mr Mbeki told the mourners.
"We have got to fight this problem throughout our society, because we had wanted Brenda to live until she was 80 years old," he added.
Described as the "Madonna of the Townships", Brenda Fassie shot to fame in the early 1980s with the hit Weekend Special.
Known for outbursts of temper and a long battle with drugs, she had many fans across Africa, including Nelson Mandela.
She is also remembered for articulating the aspirations of black South Africans during the apartheid years with songs like Black President, dedicated to Mr Mandela who was then in prison.
Despite being written off by critics numerous times, Fassie had a host of fans across Africa.
The BBC's Richard Hamilton in Cape Town says her journey from humble beginnings to superstardom made her an inspiration for millions of ordinary South Africans.
When she sang at a concert marking the handover of the presidency from Mr Mandela to Thabo Mbeki, the cheers for Fassie were reported to be the loudest.
Fassie's coffin was taken for a private cremation
Her family say her fans should not mourn her but instead celebrate her memory with her music.
After the ceremony, Fassie's coffin was taken away for a private cremation.
The crowds remained to dance and sing as some of South Africa's biggest musicians performed live.