I think you are getting something very wrong here.
You don't have to like the person, you have to be able to tolerate the person and collaborate with the person.
I believe collaboration is best when you like each other.
Yes and no...Collaboration is best when you have a common goal, if your friend worked with you, your common goal would be to complete project X in time. You may be motivated to help because you like your friend and you want him to succeed. You don't have to have the same interests, but you do need to have the same goal.
If the person you dislike and you have to work in a project together, if they are unwilling to help or simply don't want to work on the project, it doesn't matter if they are your Nemesis or your lover, you're not getting that project done.
I have worked with someone who I despised before, I can't put into words how much his personality was just...intolerable for me. I trained this person many times and worked night shifts and weekend shifts on my own him, we still performed above expectations.
Sometimes you go to work and make friends, you love the work environment, the job, the salary.
Sometimes one of this fails, but the others are true. If too many of them fail, you need a new job. You can work somewhere, where you love your work, the work environment is great, the salary is great but you have no friends, just colleagues. That is completely fine as well!
Don't fret about it, just be professional and make sure you treat them the same way you treat others.