How To Change Default Install Location [portable] — Newest
sudo flatpak --system override --filesystem=/mnt/bigdrive/flatpak flatpak install --user --reinstall flathub app-id Snap locations are hardcoded ( /snap , /var/lib/snapd/snaps ). Workaround: symlink:
setup.exe /DIR="D:\MyApps" /VERYSILENT /SUPPRESSMSGBOXES Use msiexec for MSI files:
./configure --prefix=/mnt/bigdrive/usr/local make && sudo make install For , no global default change — use bind mounts: how to change default install location
1. Executive Summary Changing the default installation directory prevents system drive (C:) saturation, improves performance for large applications, and enables logical separation of OS and programs. However, modifying this setting incorrectly can break system updates, application functionality, and security permissions. This report provides authoritative methods for Windows, macOS, and Linux, including native settings, symbolic links, and environment variable manipulation. 2. Windows 2.1 Native Method (Registry & Settings) Scope: Affects new installations via standard MSI installers and some UWP (Store) apps.
export PATH="$HOME/bin:$PATH" export LD_LIBRARY_PATH="$HOME/lib:$LD_LIBRARY_PATH" export PKG_CONFIG_PATH="$HOME/lib/pkgconfig" export CMAKE_INSTALL_PREFIX="$HOME/.local" Build tools respect DESTDIR : However, modifying this setting incorrectly can break system
robocopy "C:\Program Files" "D:\Program Files" /E /COPYALL /DCOPY:T rmdir "C:\Program Files" /S /Q mklink /J "C:\Program Files" "D:\Program Files" Repeat for C:\Program Files (x86) if needed.
# Install Homebrew elsewhere export HOMEBREW_PREFIX="/opt/homebrew" /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" Or migrate existing: Windows 2
sudo dnf install --installroot=/mnt/bigdrive/fakeroot --releasever=38 package-name APT (advanced): Use dpkg override directory: