4 ms·
Why does 64-bit Windows need a separate “Program Files (x86)” folder?
- tempestn 10y agoThere are a number of different answers there, with varying levels of accuracy. It seems to me what it comes down to is 1) organization is good, and it just makes sense to separate fundamentally different types of programs into separate directories, and 2) (the main technical reason) that it will be relatively common for both 32 and 64-bit versions of the same program to be installed. And therefore: > Installers aren't magic. They have to be written by programmers and are applications (with possible bugs) like any other application out there. So let's look at the situation an imaginary programmer would have to face with and without the current system: > 1 Program Files folder > The developer maintains 2 installers. One for the 32bit and one for the 64bit version of his application. The 32bit installer will write to C:\Program Files\App\ and the 64bit installer will write to C:\Program Files\App\sixtyfour\. > 2 Program Files folders > The developer maintains 1 installer. The installer will always write to %PROGRAMFILES% and depend on the operating system to expand the path accordingly (you actually don't use environment variables for these cases, you'd use SHGetKnownFolderPath with FOLDERID_ProgramFiles to retrieve the correct path). > Everything finds it's place automatically and the pattern is identical with every application you install. [1] Contrary to many of the answers, it doesn't seem to have anything to do with programs finding the correct DLL files, as the install location has no bearing there as far as I know. [1] http://superuser.com/a/442250/210589 http://superuser.com/a/442250/210589