Reverting problems caused by checkinstall with gcc build

Posted by slavik262 on Ask Ubuntu See other posts from Ask Ubuntu or by slavik262
Published on 2011-10-28T14:03:01Z Indexed on 2012/11/03 5:26 UTC
Read the original article Hit count: 289

I recently downloaded the GCC 4.6.2 source in order to play around a bit with C++11. Having been told about checkinstall and its usefulness in installing programs from source, I created a Debian package from the install using sudo checkinstall -D make install.

Wanting to see how well the newly created package worked, I removed it using Synaptic Package Manager. As it turns out, the package checkinstall created from make install tried to remove every single file the installation process touched, including shared gcc libraries like /lib64/libgcc_s.so. Despite not being able to run a bunch of programs due to this missing dependency, I was able to restore my system back to normal by reinstalling the package from command line using dpkg.

At this point I want to remove the package from the package manager since it's so dangerous, but not remove the installed files. I was looking around in /var/lib/dpkg and found that the package manager seems to be based on text files which list packages and such - can I just remove all mention of the package from the files in /var/lib/dpkg, or is there a safer way to go about this?

© Ask Ubuntu or respective owner

Related posts about package-management

Related posts about gcc