Noob Question Thread: Ask Any Questions About Linux!
Noob Question Thread: Ask Any Questions About Linux!
Why do programs install somewhere instead of asking me where to?
EDIT: Thank you all, well explained.
/bin has the executables, and /usr/share has everything else.
They do! /bin has the executables, and /usr/share has everything else.
Apps and executables are similar but separate things. An app is concept used in GUI desktop environments. They are a user-friendly front end to one or more executable in /usr/bin that is presented by the desktop environment (or app launcher) as a single thing. On Linux these apps are usually defined in a .desktop file. The apps installed by the Linux distribution’s package manager are typically in /usr/share/applications, and each one points to one of the executables in /usr/bin or /usr/libexec. You could even have two different “apps” launch a single executable, but each one using different CLI arguments to give the appearance of different apps.
The desktop environment you use might be reconfigured to display apps from multiple sources. You might also install apps from FlatHub, Lutris, Nix, Guix, or any of several other package managers. This is analogous to how in the CLI you need to set the “PATH” environment variable. If everything is configured properly (and that is not always the case), your desktop environment will show apps from all of these sources collected in the app launcher. Sometimes you have the same app installed by multiple sources, and you might wonder “why does Gnome shell show me 'OpenTTD` twice?”
There is no easy solution, no one agreed-upon algorithm to keep things easy for end users who install apps from multiple other sources besides the default app store. Windows, Mac OS, and Android all have the same problem. But I have always felt that Linux (especially Guix OS) has the best way of solving this problem things.