It worked after `unmerging` it and merging it again using the appropriate USE flags and restarting the system. And I didn't enable the `qt4` flag. I don't know how it works but I think enabling the `X` flag made it work for me. And I had to enable the `pulseaudio` flag too to make the audio work - which was not mentioned in the vlc site here : http://www.videolan.org/vlc/download-gentoo.html