In terms of build quality and finish, a Yamaha SG will definitely give a Gibson Les Paul a run for it's money. I have a Yamaha SG for the last 25 years and it's always been a great guitar that never had any problems, and it's one of the lower spec models. I do love my studio 60's LP also. They are both great guitars, but very different.
I think you need to play both and decide which you like best in terms of feel, playability and tone. The only thing negative I would say about the Yamaha SGs is that there doesn't seem to be many shops stocking them(well, that's from looking online), and there never seems to be any spare parts available to buy online for them. You shouldn't need any parts because of their quality, but if you were thinking of customizing your guitar it may be an issue.