delete existing files explicitly in windows installer

Earlier, we just removed the installation directory recursively.
The uninstallation code was refactored and reused at the time of
installation to remove files explicitly mentioned, which prevents
problems when the installation directory is incorrectly chosen i.e.
fixes #1585