There are some debian tools to deal with "orphaned" packages, like deborphan. Its usage is pretty simple:
.. follows a list of "orphaned" packages
I find more interesting the utility named "cruft". I use it like this:
# cruft -d /usr/lib > report.cruft.txt
This checks for files that must be in the system and files that should not be in the filesystem.
# cat report.cruft.txt | grep libGL
These files should not have been there. So, I can delete them.
I'm not aware of all the options yet, but I'll look into it when I have some time to spend...
It's convenient to check what package provides some file:
# apt-file search libGL.so.1
Also, you can use dpkg:
# dpkg -S libGL.so.1