Director Spike Lee during a press conference for the film "BlacKkKlansman" in Cannes. File picture: Stephane Mahe/Reuters

Spike Lee believes his explosive new film about race in 1970s America is a wake-up call to the US in the Trump era. The movie's global release is timed to coincide with the first anniversary of the deadly Charlottesville riots.

Berlin - Spike Lee's latest film - a blistering attack on racism in Donald Trump's America - is due to hit cinemas a year after a deadly clash in Charlottesville, Virginia, between Nazi-inspired groups and protesters that prompted much soul-searching.

Set in the 1970s - during the tensions unleashed in the US by the Vietnam War, student protests and the rise of black militancy - "BlacKkKlansman" tells the true and extraordinary story of African-American undercover detective Ron Stallworth, who infiltrated the Ku Klux Klan (KKK).

Eventually, Stallworth became a card-carrying member of "the organization," as the group is called in the film, which blends satire with a tough political commentary, as well as chilling film footage from the violent Charlottesville rally.

But Lee believes that the story of "BlacKkKlansman" is not something from the past, rather a work that helps to shed light on current events unfolding in the US, with the movie linking the Trump administration to the activities of white supremacists.

"BlacKkKlansman" is "on the right side of history," Lee told reporters at the film's premiere in May at the Cannes Film Festival.

Lee said Trump had failed to show moral leadership in his response to last August's "Unite the Right" rally in Charlottesville in the US state of Virginia.

The rally drew hundreds of conservative protesters - some of them sporting Klan garb and Nazi flags - for a joint march. Counter-protesters quickly came out. One death was recorded when Heather Heyer, a civil rights activist, was hit by a car ploughed into a group of people demonstrating against the march.

Trump has come under fire from across the political spectrum for failing to adequately condemn the extreme right-wing groups that joined the rally, with the president claiming there was "blame on both sides."

But Lee, the 61-year-old feisty director of the 1989 Oscar-nominated "Do the Right Thing," is even more outraged.

"That motherfucker had the chance to say we are about love and not hate," Lee told reporters in Cannes. "That motherfucker did not denounce the Klan and ... the Nazis."

Trump failed to say "in America, we're better than that," according to Lee, who refused to mention Trump by name, but regular calls the US president "Agent Orange."

"BlacKkKlansman" draws to an end with KKK members chanting "America First" - Trump's centrepiece slogan - before showing original film footage of the Klan's former grand wizard, David Duke, praising Trump's plans for the US.

"BlacKkKlansman" stars John David Washington, a former American football player and the son of Hollywood star Denzel Washington, as  Stallworth, who worked alongside a Jewish undercover agent, Flip Zimmerman, to infiltrate the KKK.

The real-life Ron Stallworth joined the Colorado Springs police force in 1978 at age 21 as its first black member.

Eager for interesting police work, Stallworth spotted a KKK newspaper advertisement and began writing to the group.

As his character in the film says, he tells the Klan: "I really hate those black rats and anyone who doesn't have white Aryan blood running through their veins."

While Stallworth worked the phones talking to Klan leaders, including Duke, Zimmerman, played by US actor Adam Driver, made the face-to-face contact with its members, pretending to be Stallworth.

Now retired, Stallworth has expressed amazement at how easy it was to fool the Klan and its leaders. However, the KKK was so impressed with his message of hate that it quickly accepted him as a member.

Stallworth has said in interviews in the run-up to the "BlacKkKlansman" worldwide release that Duke had contacted him to ask how he would be portrayed in the film.

"BlacKkKlansman" is also dedicated to Heyer. Heyer's mother gave Lee permission to use film footage showing the attack that led to Heyer's murder.

Lee also believes the film's message should be a wake-up call for the rest of the world, warning that the activities of the radical right were not confined to the US.

"This bullshit is all over the world," Lee said. "We have to wake up. We can't be silent."