Nile Rodgers, cofounder of Chic and a legendary producer and songwriter, has few peers in today’s music world: He co-wrote “We Are Family,” “Le Freak” and “Good Times,” the song that essentially created the backbone of hip-hop when interpolated by the Sugarhill Gang; he’s produced massive albums and songs by Madonna, David Bowie, Diana Ross, Duran Duran, INXS, the B-52s and collaborated with Daft Punk (on the Grammy-winning “Get Lucky”) Pharrell, Disclosure, Lady Gaga and dozens and dozens of others.

He also worked extensively and was close friends with DJ and artist Avicii — who died of undisclosed causes Friday at the age of just 28 — although just one song has emerged, 2013’s “Lay Me Down,” which was sung by Adam Lambert.

Fresh from two sets with Chic at Coachella and just ahead of his annual We Are Family Foundation benefit in New York on Friday — and with a new Chic album coming later this year — Rodgers (pictured above, far right, with Avicii (center) and Incubus guitarist/co-writer Mike Einziger) talked with Variety about his friend.

How did you and Avicii first meet?
I first met him at Radio City Music Hall [in 2012] — somebody said I should check it out. I pretty much know people at every venue in New York, even if I don’t have a ticket people think if I walk up, “Oh Nile’s here, he must be playing with that guy” and just let me in. So they let me in the back door but I hadn’t told anyone I was coming, so I’m standing backstage and he hadn’t arrived yet so I’m going “What do I do now?” So I hung out with his fans and they were really nice, I was like “Wow, this is so unlike some of the crazier DJ crowds I’m accustomed to,” so I figured if his fans were so nice, I gotta meet this guy.

I watched his set and afterwards I met him and he didn’t recognize me right away, so somebody introduced us and he went, “Nile Rodgers! Half of the stuff that I play in my set is his!” We laughed and got along and I said “I’m coming out to LA to work with David Guetta, maybe we could knock out a couple of songs together.”

I went out there and he had his gear set up in the studio and I plugged in my guitar and played one little riff, and right away he asked the notes and he made a beautiful melody out of it, and we were off and running. He was extremely tired that night because he had just come in from Vegas so he ran out of gas early, but I was ready to go. So I called Prince and he said “I want you to meet these girls that I’m managing called King,” so he sent them over and they’re extraordinary, and I had just met Adam Lambert, who had hired me to play on his record, and this friend named Russell Graham who’s now in Chic was working on “American Idol” — so I put together a supergroup in about ten minutes! We finished the song, and when Tim woke up I said “Check your inbox!” He was like “What the hell? This is amazing!”

We just had that kind of relationship, and we always started from nothing — he would just come in and say “What do you want to do today, Nile?” I might say there’s a classical composer named Boccherini, and there’s one little passage that I used to play when I was a young classical guitar player, let’s turn it into a lick,” and he would interpolate it and turn it into something else – that quick.

How many times did you work together?
It’s hard to count the days because they’re days in a row. The first time was 2-3 days, the next time was out in the Hamptons for another five days or so, and because things had gone so well with Adam Lambert we had him fly in, and then we did another thing where he rented Jimmy Iovine’s studio in Santa Monica, and then one other time. And we did three live gigs together — and that was the last time I saw him, at a live gig about three years ago. That’s the heartbreaking incident I talk about where he had told me he was never gonna drink again. I roll backstage and I’m so thrilled to see him, and he was woozy because he had been drinking so much and he hadn’t even gone onstage yet. I’m like dude, how can you be that drunk before you even go onstage? But of course I loved him so we were all cool, and I’ve had my own fair share of drinking problems — I’m clean and sober 24 years in a couple of months. So I get it, and I wasn’t gonna preach to him, that’s not where I’m coming from. But he’s the one who told me he wasn’t drinking — that’s the story I want people to get straight. I was not telling him not to drink; I know better than that. He was telling me. So I was a little depressed because he had gone on and on in this long diatribe about how he’s not drinking, and I get to the show and he’s lit! It made me cry because I cared about him so much. He was like my little brother, a young dude, “you’re gonna kill this industry if you’re doing this at such an early point in your career.”

Did that kill the friendship?
Oh hell no, please, no way. Other people drinking doesn’t bother me — it’s just the fact that he brought it up to me. If he hadn’t said anything and was just enjoying being drunk I would have been fine. It was that he was drunk and said “I have to stop drinking” that I got alarmed, because that means you know something’s wrong.

Did he remind you of anyone else you’ve worked with over the years?
Not really, because most everybody that I work with has a solid musical sense. I would say the artist who melodically remind me of Tim and don’t have formal music training would be the B-52s. Typically when they write, they’re very melodic (hums “Deadbeat Club”) — sweet and almost nursery rhymey in their cadence quality, and that’s what Avicii had. Most people once they learn a little more about music and scales and references to tonal centers and things like that they become intellectually more developed, so that more innocent thing goes away, and it’s very hard to keep it once you get smarter and smarter. That’s one reason I liked him, he was like this diamond in the rough, the music business never said “You have to do THIS,” he was a young kid writing these songs that everybody can relate to.

It’s interesting, Mike from Incubus said the same thing to us about him not losing that innocent quality to his music.
Yeah, that’s a great thing that Mike picked up on. When you sit down to work with Avicii, I don’t care who you are, he’s not intimidated because you’re from Incubus or you’re Chris Martin from Coldplay — to Tim he was just making music and he was so happy that he was now in this arena. And he knew inherently that he could add something through his beautiful melodies. He really had this thing for melodies, that’s a hard thing as you get older.

Just one more question, is there anything you recorded together that hasn’t come out?
There’s tons! Tons! We would go in in the morning and write 5-6 songs every single time we worked together. I played some stuff for Keith Urban and he said “I would do any of those songs, any of those songs would be a hit.”