retroarch
depends on nvidia-cg-toolkit
so it gets removed if you remove nvidia-cg-toolkit
.
As a side note sudo apt-get purge nvidia*
most likely doesn't do what you want:
First the shell will try to expand nvidia*
. So if you have for example a file named nvidia.txt
in your current folder the shell will actually run
sudo apt-get purge nvidia.txt
If the shell can't expand nvidia*
apt-get
will interpret it as a regular expression (not a shell pattern!) meaning "nvidi
followed by zero or more a
" and then search for packages with names containing a matching substring.
That is apt-get
will purge all packages with a name containing nvidi
(without the a
because the "zero" in "zero or more").
Better use
sudo apt-get purge 'nvidia.*'
for all package containing nvidia
or
sudo apt-get purge '^nvidia.*'
if you want to remove all packages starting with nvidia
.