For a lyricist writing the lyrics first and have the composer set them to music obviously is the easy way.
When I write for myself I normally start with an idea for the chorus. A few lines of text and the tune seem to come to my mind at the same moment, I couldn't tell which one comes first. As for the verses I usually begin with the text. Maybe I have an idea for the accompaniment, but that would be rather vague and easily adaptable.
When I write for others there already is a melody that they have composed, so I have to match my text with it. Holger from Motorplanet sends me complete recordings with bass and drums and all. And he sings the complete song using some kind of nonsense text. What I would do then is count the notes and make notes of the stresses. Holger's music is either Blues or Rock, or Blues-Rock. Namely the verses for Blues and Rock can be treated rather flexibly, and Holger's singing often indicates where and which variations may be acceptable.
The common meter is 4/4 or 2/4, and the accent lies on the first beat. In the 4/4 meter the third beat usually is also accented with a slighter stress. I would note down both meters like this ('X' stands for an accented note):
X - X - X - X - ...
This basic pattern is actually quite simple and it's easy to match a text with. Since a spoken or read text does not necessarily begin with a stress you might need an extra note at the beginning, though:
- X - X - X - X -
The extra note would be an upbeat note in the preceding meter. Let me illustrate the meter with vertical lines (and the slighter stress on the third beat of a 4/4 meter with 'x'):
- | X - x - | X - x -
The chorus of my own song "lost" would look like this, for example:
I am lost: - - | X
I don't know a way out: - | X - x - - ...
I don't feel: - - | X
quite fit for a scout: X - x - -
When I'm writing for Karsten things look quite different. The tune is finished and has its intonation and I try to find matching lines of text. Especially with longer lines this can prove next to impossible. As a little exercise you might try finding lines which fit this pattern:
X - - X - - X - X - - X - X - - X - X - X -
See what I mean?
After splitting the melody into two lines I wrote:
"I'm caught in your eyes and I could be losing myself
but your smile always puts me at ease"
Although the syllable count looks alright and the second line can be done (sung), the stresses in the first line on "I'm" and "your" are rather weird and the intonation is pretty messed up starting from "be".
The text should better read:
"Caught in your eyes I could be losing myself ..."
But then Karsten will have to rewrite the tune. That would mean some kind of interaction: neither text nor music comes first, but the text is written to match the tune but also requires re-adjusting it.