"We love you for coming to see us", he said, dedicating "The Kids Are Alright" to "the young ones" in the crowd.
Woodstock was a muddy mess, he said, and once you got in, you couldn't get out.
Desert Trip, forecast to be the most lucrative music festival in history, is bringing together six of the biggest names in rock over back-to-back weekends with identical lineups.
The 73-year-old singer-songwriter also denounced war and addressed the Black Lives Matter movement in his 2 ½-hour set that closed out the three-day classic rock concert in Indio, California.
It was an ill-timed "woo!" to say the least.
The final night of the festival got political as The Who and Roger Waters took the stage for their performances.
Be proactive - Use the "Flag as Inappropriate" link at the upper right corner of each comment to let us know of abusive posts.
Ford performance power packages now available for EcoBoost- and V8-equipped Mustang
In automatic-equipped cars, the performance package provides optimized shift schedules. The performance calibration kits will be made available by Ford Performance Parts.
After playing "Welfare Mothers", Young suggested that it should become Donald Trump's new campaign song. Other songs played included the John Lennon-led Plastic Ono Band's single "Give Peace A Chance" and the McCartney-sung song from The Beatles' 1968 album The White Album. "Both McCartney and Young were all smiles sharing the stage, then tore into the raw Beatles oddity "Why Don't We Do It in the Road?" leaving room for Young to set his guitar aflame with a joyfully ragged solo, a searing moment likely to be remembered long after this weekend".
"Come back because Roger's gonna build a wall and make Mexico great again", Young said, a play on Trump's statements to build a wall and his "Make America Great Again" slogan. Women dressed as farmers, in plaid shirts and overalls, pretended to throw seeds and tend small plants onstage before Young came out.
Describing Young as "a really good friend of ours that I've known through the years" - it was Young who initiated McCartney as a solo artist into the Rock and Roll Hall of Fame in 1999 - the two rock icons first doled out the Sgt. Pepper'scloser, which Young had performed in the past with the former Beatles bassist.
"I'm a Beatles fanatic", she said. "I love that boy".
Young also stated that Trump may have another message from Sunday's headliner Roger Waters, the force behind Pink Floyd's The Wall.
This version has been corrected to show that McCartney had four band members, not five.