Walking into Vila Autódromo, a poor neighbourhood next to Rio de Janeiro's Olympic Park, is like entering a bomb site.

Debris is everywhere; iron rods that once supported the small, modest homes now protrude from the ground, twisted and rusty.

Piles of garbage line the unpaved streets and dirty water collects in abandoned tanks.

The slum has been razed except for a few dozen buildings — Vila Autódromo is in fact a war zone in many ways.

The remaining 120 families have resisted eviction for the past two years and are now fighting Rio's city government in court.

Rio's mayor, Eduardo Paes, wants the families out to make way for a vital access road to the Olympic Park, where most of the venues for this year's competitions are located.

And Mayor Paes has the law on his side — the relocations have been authorised by statutes covering the public use of the land.

Mayor Paes also says some residents have been squatting for years in an area that borders Jacarepaguá lagoon, protected by Brazil's environmental laws.

The home of a family which is fighting eviction stands among the rubble of Rio's Vila Autodromo slum. ( Adriana Brasileiro )

Residents, helped by public defenders, say they have titles for the land and cannot be removed just because the city government decides they should disappear.

Rio de Janeiro will host this year's Olympic Games in August and the immovable residents of Vila Autódromo are the final barrier to the completion of the access road, essential public works and beautification.

"I love this place and I won't leave, not for one million, not for two or even three," says Sandra de Souza, 47, who has lived at Vila Autódromo for 23 years.

Residents describe the area as an oasis in the middle of Rio's chaotic life.

They talk with pride about its small-town camaraderie and a strong sense of community and they all swear that drug-dealing and violence was never a problem in their neighbourhood. Drugs are rife in most of Rio's slums.

But public defenders aren't hopeful.

"So far we've been fighting what seems to be a lost battle," says João Helvécio de Carvalho, a co-ordinator at Rio de Janeiro's Public Defenders' Office.

He concedes that municipal decrees allow the city's government to demolish the slum.

As a compromise, a group of architects and academics have proposed a plan to revitalise the area and incorporate Vila Autódromo into Rio's Olympic plans. But the project has been rejected by Mayor Paes.

Squatters start an authentic community

Children in the streets of Vila Autodroms, the partly-demolished slum area neighbouring Rio's Olympic Park. ( Adriana Brasileiro )

The half-moon-shaped strip of land wedged between the Jacarepaguá lagoon and the Olympics complex has always belonged to the city.

In the mid-1980s, fishermen and their families began to illegally occupy the land. More squatters followed and soon the settlement had more than 150 families.

In 1989, the government began to give ownership titles to the families of Vila Autódromo and in the years that followed, the community was able to obtain basic services such as piped water and garbage collection.

According to Rio city records, the neighbourhood grew to about 600 families in the early 2000s.

Vila Autódromo still displays the characteristics of a squatter settlement. The streets, named after famous Formula One drivers such as Gilles Villeneuve, are unpaved and most of the buildings are modest, cinder block units with a couple of bedrooms.

The roads are full of potholes and, when it rains, they often flood.

But in recent years, multi-story houses with verandas and even pools have been built in the most-prized areas, such as those overlooking the lagoon.

Nearly 80 per cent of the original families have agreed to move in exchange for apartments in a nearby complex and cash. The city has spent more than 100 million reais ($35 million) in compensation.

Despite increasing offers of financial compensation, the remaining residents say they won't leave.

A sign in Rio's Vila Autodromo says: "We are being kicked out by an elitist and exclusionary process." ( Adriana Brasileiro )

Maria da Penha Macena, 50, lives with her husband and daughter in a large three-story house near the lagoon.

The concrete building is surrounded by trees and large potted plants.

On the lower floor is her home with a living room, small kitchen and two bedrooms; the second floor houses three apartments that Maria rents out to couples and the top floor is a balcony for parties.

"This is where I'm happy. No money in the world can buy that feeling and that's why I'm not going to leave," the former house cleaner says.

She points to the fruit trees in her lush backyard: avocado, guava, acerola, mango and cajá.

Since 2013, the city has made her offers to leave the house — the last more than $700,000 — plus a two-bedroom apartment measuring 40 square metres in a nearby housing project, Parque Carioca.

The apartment complex has 900 units, a playground and a pool. It's an improvement for most families in Vila Autódromo, who suffer the torments of life in a Rio slum, but for others, Parque Carioca feels more like a prison.

"I built my life here, in this beautiful piece of land next to nature. I'm not going to live in a tiny box,'' Maria says.