Id just let them decide what they're going to do with the baby. You can still be with him if he helps with the kid, as long as he doesnt get involved with your friend, who hopefully wont cos she sounds like a really close friend..
But anyway just let them decide about this, he shouldnt leave you if he loves you as much as it sounds like you love him, but its not exactly a great situation. Just dont influence either of them on what to do with the baby, its a big decision theyve got to decide with each other. Be there to help them, and things'll sort themselves out.
Ok im fairly sure im no help at all, but i wanted to try
good luck with what ever you do!