Bill Cosby goes on trial June 5 for sexual assault, and he's spent the last few weeks setting the tone for his defense. In several media appearances and courtroom interactions, the comedian and his supporters have tried endearing themselves to black observers by painting Cosby's trial as a racist witch hunt.

"My father has been publicly lynched in the media," Cosby's daughter, Ensa Cosby, said in a pre-recorded statement to New York City radio talk show the Breakfast Club on May 15. Cosby's attorney, Brian McMonagle, added that jury selection for the trial reflected a "systemic exclusion of African-Americans," after prosecutors struck two black women from the panel Wednesday, according to the Associated Press.

This language seems intended to link Cosby's trial with America's legacy of anti-black racism. As Mic's Jamilah King wrote last week, these tensions are compatible. There is both a long history of black people being lynched in the United States — to the tune of 4,075 between 1877 and 1950 — and a pattern of excluding black people from juries. At the same time, Cosby has faced roughly 40 years of plausible accusations that he drugged and sexually assaulted more than 50 women. There is no evidence that this has anything to do with his race.

But perhaps the most striking part of Cosby's campaign is how shameless it is. By angling to gain black sympathy in the court of public opinion, Cosby is glossing over the years he spent castigating poor black people for their alleged pathologies. In an infamous 2004 speech, the comedian lambasted low-income blacks for not "holding their end in this deal" after years of landmark civil rights legislation gave them more opportunities. At one point, he even suggested that death was an appropriate punishment for black people who engaged in petty theft.

"People getting shot in the back of the head over a piece of pound cake!" Cosby said. "Then we all run out and are outraged. 'The cops shouldn't have shot him.' What the hell was he doing with the pound cake in his hand?"

For years after his "Pound Cake Speech," Cosby went on a nationwide tour giving "fireside chats" urging black people to take more responsibility for their problems. Regular targets for his derision included black youth sagging their pants, black teenage pregnancy and how politicians no longer ran on "law and order" platforms in black communities because they were scared they'd be accused of "picking on the poor" (this was 2008, eight years before Donald Trump was elected president).

Meanwhile, absent from these lectures was any real mention of the unique barriers to progress black people face — like the decades of forced segregation that relegated many to economically distressed neighborhoods, and the 1.5 million black men "missing" from daily life due to high rates of incarceration and premature death. For years, these conditions have splintered black families, incubated the conditions for high crime rates in their neighborhoods and subjected them to disproportionate police violence.

But now, Cosby is hoping the same people he's spent years berating will look at him in a sympathetic light as his trial unfolds. In many ways, this approach echoes that of O.J. Simpson. In 1995, Simpson was acquitted in the brutal murders of his ex-wife, Nicole Brown Simpson, and her friend, Ronald Goldman. The evidence against Simpson was significant. But his defense team successfully convinced black jurors — and much of the black public — that he was a victim of a Los Angeles Police Department frame-up. This was a plausible explanation — the LAPD was know for its vicious racism against blacks. But the defense team's gravitation toward Simpson's blackness was a stark turnaround from how the football star lived his life. At every given opportunity, Simpson rejected his affiliation with black people, even going so far as to appreciate how he once heard a white woman say, "Look at those niggers sitting with O.J."

"Don't you understand?" Simpson reportedly said to sports journalist Robert Lipsyte at the time. "She knew I wasn't black. She saw me as O.J."

While their philosophies for doing so often differed, Simpson and Cosby both conveniently invoked their blackness to curry favor with the black public when they faced criminal charges — even as they rejected, scolded and derided black people in their daily lives. In Simpson's case, he was rewarded with an acquittal. The outcome for Cosby is yet to be determined. But as his trial unfolds, black Americans might do well to remember that while they were busy navigating the perils of American racism, Cosby was on tour telling the rest of the country how deficient and irresponsible many of them were. And if his many accusers are to be believed, he did so while raping women at the same time.