Got some personal experience having no less than 3 different cats at home at any point in my life.
Now, I see some damn good advice up above for making sure it is healthy and all that, but how to ensure that warms up to you? I'll provide a few tips on that. Note, this might vary from cat to cat, but I had high success with befriending strange cats, so I'm willing to share this.
1: Cats have a strong instinct to rub their head against anything resembling a flat surface, since that's how they mark their territory. (When they rub against their leg, they are marking you as the same) Anyhow, when they are still getting used to you, it is best that you lock yourself in with the cat, not moving around so it doesn't get nervous (if you intend to use food as bait, give a few pieces that isn't right in front of you.) and give it the chance to get used to your scent. How I do this having my hand extended so they can sniff it, preferably by shaping your hands completely stretched out fingers completely entended and
tuck your fingers like this, but flatter like a wall itself. Let it sniff and rub against your head, but don't pet it until it starts getting comfortable getting close to you, then work your way up from there.
2: Even once it's comfortable with you, big rule of thumb is NOT to rub or pet their stomach until you're 100% sure that your friendship is secure. It is a "weak-point" to them and they guard it carefully, with scratch and bites and they won't be happy with you. In large animals like lions, the belly was the weakpoint, and the cats seem to have kept this perspective.
and on a very important side note, if your cat ever can or will go outside, or if your garage is indoors, keep it very clean and free of spills or better yet block it off. Stuff like Anti-freeze is sweet-tasting but utterly toxic.