Good deal!! Free bikes and supportive friends are the best! That's how I got into road biking.
$500-800 gives you lots of options in the hardtail MTB dept. I personally started on a Raleigh Mojave 4.0 in this price range. Solid frame, basic components, did the job.
Giant Revel
Giant Talon 4 (27.5" wheels, I want to check this one out in person, looks like a well rounded bike with lots of goodies for the price)
Raleigh Talus 4.0 or 5.0 (also check their 29" line-up)
Trek 4300 (probably best option components-wise)
Trek 3700 (buddy has one. Basic, but can take a thrashing)
Specialized HardRock sport (29" is an option)
Specialized Rockhopper 29 (just a touch above your $800 limit, again, better components than some I'm listing)
I think $800 is about that cut-off between price point and solid bikes. Below it you'll find basic bikes with basic forks, above it, you start finding more desirable components and/or forks, but not the whole package. You picked a good price range to find lots of bikes that will start you off on the right foot.
Also, I'm a Giant fanboy. (on my second one) You might have to take my suggestions with a grain of salt and hunt through some bais.