Problem is the term "greatest" is meaningless in this context.
What are the criteria and how do you weight them.
Speed? Technical virtuosity? Origianlity? Influence on other musicians? Should credit be given to song/melody writing ability? Showmanship? Energy level of live performance?
If you wanted to do a poll without clear criteria; I think your most accurate method would be polling the top 50 highest paid studio musicians in LA or at very least polling people who actually make a living playing guitar not wanna-bees and air guitarists.
You are so right. I certainly have musicians I admire, but I admire them because they play their instruments so as to best help the song or tune and not to create a musical aside. Virtuosity means nothing outside the context of the actual music. Too many music fans get charged up over a certain musician's ability to play his guitar whether the kind of music emanating from the instruments fits the music or not.
This is especially true of rock guitarists. I don't know how many rock fills I've heard was just the guitarist aimlessly playing up and down the fretboard with no harmonizing or helping the basic sound whatsoever. In short, many rock fans get hung up on flash, effects, and noise. Hopefully as they get older they'll realize that there's a lot more to good guitar (or any instrument for that matter) playing than just turning the amp to eleven and cavorting around the stage like a monkey on amphetamines.