How to uninstall TrueCrypt

Development on TrueCrypt has been stopped and so it is a good idea to uninstall TrueCrypt and switch to other alternatives. Since TrueCrypt is not installed from a package, you might have forgotten how to uninstall it.

  • First make sure that you have unmounted all TrueCrypt volumes.

  • Uninstall TrueCrypt using the script it had placed during installation:

$ sudo /usr/bin/truecrypt-uninstall.sh

Tried with: TrueCrypt 7.2 and Ubuntu 15.04

How to remove driver in Windows

20150806_primesense_driver

If you work with lots of devices in Windows, you are sure to run into problems with device drivers. Sometimes, a particular version of a device driver might cause problems and removing it might be the only solution.

Using Device Manager

This is an easy removal method if you have the device and know that its driver is being used when the device is plugged in. For such a case, plug in the device and open Device Manager. Right-click on the device and choose Properties. In the Driver tab, choose Uninstall.

Using Driver Store Explorer

If you do not have the device or plugging it in causes problems, then the Driver Store Explorer (RAPR) can be used to remove the driver as described here.

Tried with: Windows 7 x64

How to use checkinstall instead of make install

There are many situations where you need to build an application from source code and install it. The typical method to install it is:

$ sudo make install

One of the major problems with installing like this is that uninstalling is not possible. You will need to know what files were installed to what destination directories and manually remove those files!

The CheckInstall application can be used to convert such an installation into a package, which can be installed and uninstalled easily using your distribution’s package tools.

  • Install checkinstall: First, we have to install this application:
$ sudo apt install checkinstall
  • Creating a package file: Turning the above make install into the installation of a package is as easy as:
$ sudo checkinstall

This will take you through some prompts where you provide the meta information for the package. You can choose to just press Enter through these sections. After that, a package file is created and is also installed for you. For example, a foo_amd64.deb package was created for me and it was installed.

  • Package name: Note that the directory name from where you are running this becomes the default package name. If you do not want that, specify a package name:
$ sudo checkinstall --pkgname foobar_by_joe
  • I can now use the .deb file created by checkinstall to install on other computers or pass it to other people on the team:
$ sudo gdebi foo_amd64.deb
  • Uninstalling is as easy as:
$ sudo apt remove foo

Tried with: CheckInstall 1.6.2 and Ubuntu 14.04

How to install and uninstall Python module from source code

A lot of Python modules are only available as source code. To install such a Python module, use its setup.py file:

$ sudo python setup.py install

To uninstall this module is a bit tricky. We need to find out what files it installed and then use that list to remove those files:

$ sudo python setup.py install --record install-files.txt
$ cat install-files.txt | sudo xargs rm -rf

Tried with: Python 2.7.6 and Ubuntu 14.04