I also had and solved my MacBook Pro Lion's problem manifested by the endless spinning wheel under the apple during boot. I'll describe all the things I've tried below, but what what I ended up having to do is to buy a new internal hard drive and fresh install Mac on it.
What you can try (might fix the problem if your HDD is not broken):
- Verbose safe boot by powering on while pressing [Shift]-[Command]-[V]
- NVRAM/PRAM reset by powering on while pressing [Command]-[Option]-[P]-[R]
- Repair disk by powering on while pressing [Command]+[R] --> Disk Utility --> HDD selection --> Repair Disk, note this repair would not affect your data
- Apple Hardware Test
- Independent HDD Check by taking out the HDD, putting it into a SATA to USB adapter, and plugging it into another Mac. It could not be found on the other Mac.
Since none of these solved the problem for me, I went to the Apple store for the "Genius Bar". An Apple rep ran a Mac Resource Inspector (a specs checker available only at Apple stores) and pinpointed my problem to my hard drive. My Toshiba HDD's SMART Status was Failing, which according to the Apple rep I can only replace it and do data recovery on the broken HDD.
Everything is pointing to the speculation that my laptop tries to detect the HDD without success, so it couldn't load anything, thus the endless spinning disk.
To fix my Mac, I bought a new 2.5" laptop internal hard drive no more than 9.5mm in height. I got a more reliable brand, since my Toshiba HDD didn't even last 2 years. I followed instructions on iFixit to replace the hard drive. Note a T6 Torx screwdriver is needed, which Apple stores do not loan out nor sell at the time of this posting.
I made a bootable USB stick with createinstallmedia after downloading the Maverick installer on another Mac. The computer complained the boot app can't be verified, which I solved by changing the system date on the terminal (Google "Changing system date from Terminal – OS X recovery"). It then installed successfully and I finally got my Mac back!
I have yet to do data recovery.