WASHINGTON – Roger Clemens’ lawyer accused the baseball legend’s former strength coach of changing testimony “on the fly,” and the judge in the perjury trial imposed a time limit Friday on all future witnesses in an effort to speed things up.

Under relentless questioning in his fifth day on the stand, Brian McNamee admitted he “misspoke” while explaining some of the medical evidence he saved in a beer can.

“Isn’t this a classic example of you making up this stuff on the fly?” asked attorney Rusty Hardin, who spent three days of cross-examination trying to portray McNamee as a serial liar.

McNamee is the main prosecution witness against Clemens, who is accused of lying to Congress when he denied using performance-enhancing drugs. McNamee testified that he injected the seven-time Cy Young Award winner with steroids and human growth hormone.

Meanwhile, U.S. District Judge Reggie Walton told both sides that the trial needs to end by June 8 — or else it will have to recess for about a month because of various scheduling conflicts.

“And then we’ll have some real unhappy jurors,” Walton said.

The trial was supposed to last four to six weeks, but it’s now wrapping up its fifth week — and the government said Friday it still has nine witnesses to call. That’s a decrease from the 14 witnesses the government stated on Thursday, but it wasn’t enough to keep Walton from imposing a 90-minute limit for each side on each witness once McNamee is done.

“I’ve never done this, and I hate to,” said Walton, who has been a judge for more than four decades.

McNamee has said he kept medical evidence after injecting Clemens with steroids in 2001 and stored some of the material in a Miller Lite beer can. But under cross-examination, he acknowledged that some of the items in the can were not in fact used on Clemens, such as a small bottle of human growth hormone, a needle to inject HGH and a bottle of saline solution used for such injections.

McNamee also testified that a pin included in the beer can might not have been used on Clemens. He said it was either used on Clemens or another player, whom he did not name.