Where do new packages get installed?

Hello. I recently migrated from Windows to Manjaro and have been adapting pretty well so far. I got only one question for the moment, when installing software with pacman, be it via terminal or with the desktop interface, how do I select where I want to install it? Let me explain.
I have a SSD and a HDD, I selected the SSD to install Manjaro and then mounted my HDD in my home directory so all my media files, Steam games, etc. can get stored there. As far as I know all packages installed with pacman do not go in my /home directory, I think they get installed in /etc or other directories but I am still not sure.
Where do packages (or most of them) get installed? How do I change where I want to install it if, for example, I want to store a program in my HDD?
Thanks in advance.

You dont. Without getting into super-technical bits … the packages have installation paths for different files across the system. I think it might have been on the previous forum, but someone did a pretty good write-up of common places … especially in accordance with the FHS.

For example … lets take a look at firefox.

$ pacman -Ql firefox
firefox /usr/
firefox /usr/bin/
firefox /usr/bin/firefox
firefox /usr/lib/
firefox /usr/lib/firefox/
firefox /usr/lib/firefox/Throbber-small.gif
firefox /usr/lib/firefox/application.ini
firefox /usr/lib/firefox/browser/
firefox /usr/lib/firefox/browser/chrome/
firefox /usr/lib/firefox/browser/chrome/icons/
firefox /usr/lib/firefox/browser/chrome/icons/default/
firefox /usr/lib/firefox/browser/chrome/icons/default/default128.png
firefox /usr/lib/firefox/browser/chrome/icons/default/default16.png
firefox /usr/lib/firefox/browser/chrome/icons/default/default32.png
firefox /usr/lib/firefox/browser/chrome/icons/default/default48.png
firefox /usr/lib/firefox/browser/chrome/icons/default/default64.png
firefox /usr/lib/firefox/browser/crashreporter-override.ini
firefox /usr/lib/firefox/browser/defaults/
firefox /usr/lib/firefox/browser/defaults/preferences/
firefox /usr/lib/firefox/browser/defaults/preferences/vendor.js
firefox /usr/lib/firefox/browser/features/
firefox /usr/lib/firefox/browser/features/doh-rollout@mozilla.org.xpi
firefox /usr/lib/firefox/browser/features/formautofill@mozilla.org.xpi
firefox /usr/lib/firefox/browser/features/screenshots@mozilla.org.xpi
firefox /usr/lib/firefox/browser/features/webcompat-reporter@mozilla.org.xpi
firefox /usr/lib/firefox/browser/features/webcompat@mozilla.org.xpi
firefox /usr/lib/firefox/browser/omni.ja
firefox /usr/lib/firefox/crashreporter
firefox /usr/lib/firefox/crashreporter.ini
firefox /usr/lib/firefox/defaults/
firefox /usr/lib/firefox/defaults/pref/
firefox /usr/lib/firefox/defaults/pref/channel-prefs.js
firefox /usr/lib/firefox/dependentlibs.list
firefox /usr/lib/firefox/distribution/
firefox /usr/lib/firefox/distribution/distribution.ini
firefox /usr/lib/firefox/firefox
firefox /usr/lib/firefox/firefox-bin
firefox /usr/lib/firefox/fonts/
firefox /usr/lib/firefox/fonts/TwemojiMozilla.ttf
firefox /usr/lib/firefox/gmp-clearkey/
firefox /usr/lib/firefox/gmp-clearkey/0.1/
firefox /usr/lib/firefox/gmp-clearkey/0.1/libclearkey.so
firefox /usr/lib/firefox/gmp-clearkey/0.1/manifest.json
firefox /usr/lib/firefox/gtk2/
firefox /usr/lib/firefox/gtk2/libmozgtk.so
firefox /usr/lib/firefox/liblgpllibs.so
firefox /usr/lib/firefox/libmozavcodec.so
firefox /usr/lib/firefox/libmozavutil.so
firefox /usr/lib/firefox/libmozgtk.so
firefox /usr/lib/firefox/libmozsandbox.so
firefox /usr/lib/firefox/libmozsqlite3.so
firefox /usr/lib/firefox/libmozwayland.so
firefox /usr/lib/firefox/libxul.so
firefox /usr/lib/firefox/minidump-analyzer
firefox /usr/lib/firefox/omni.ja
firefox /usr/lib/firefox/pingsender
firefox /usr/lib/firefox/platform.ini
firefox /usr/lib/firefox/plugin-container
firefox /usr/lib/firefox/removed-files
firefox /usr/share/
firefox /usr/share/applications/
firefox /usr/share/applications/firefox.desktop
firefox /usr/share/icons/
firefox /usr/share/icons/hicolor/
firefox /usr/share/icons/hicolor/128x128/
firefox /usr/share/icons/hicolor/128x128/apps/
firefox /usr/share/icons/hicolor/128x128/apps/firefox.png
firefox /usr/share/icons/hicolor/16x16/
firefox /usr/share/icons/hicolor/16x16/apps/
firefox /usr/share/icons/hicolor/16x16/apps/firefox.png
firefox /usr/share/icons/hicolor/192x192/
firefox /usr/share/icons/hicolor/192x192/apps/
firefox /usr/share/icons/hicolor/192x192/apps/firefox.png
firefox /usr/share/icons/hicolor/22x22/
firefox /usr/share/icons/hicolor/22x22/apps/
firefox /usr/share/icons/hicolor/22x22/apps/firefox.png
firefox /usr/share/icons/hicolor/24x24/
firefox /usr/share/icons/hicolor/24x24/apps/
firefox /usr/share/icons/hicolor/24x24/apps/firefox.png
firefox /usr/share/icons/hicolor/256x256/
firefox /usr/share/icons/hicolor/256x256/apps/
firefox /usr/share/icons/hicolor/256x256/apps/firefox.png
firefox /usr/share/icons/hicolor/32x32/
firefox /usr/share/icons/hicolor/32x32/apps/
firefox /usr/share/icons/hicolor/32x32/apps/firefox.png
firefox /usr/share/icons/hicolor/384x384/
firefox /usr/share/icons/hicolor/384x384/apps/
firefox /usr/share/icons/hicolor/384x384/apps/firefox.png
firefox /usr/share/icons/hicolor/48x48/
firefox /usr/share/icons/hicolor/48x48/apps/
firefox /usr/share/icons/hicolor/48x48/apps/firefox.png
firefox /usr/share/icons/hicolor/64x64/
firefox /usr/share/icons/hicolor/64x64/apps/
firefox /usr/share/icons/hicolor/64x64/apps/firefox.png
firefox /usr/share/icons/hicolor/symbolic/
firefox /usr/share/icons/hicolor/symbolic/apps/
firefox /usr/share/icons/hicolor/symbolic/apps/firefox-symbolic.svg

So in this case, most everything is going in /usr/ … which is pretty common.
Though it is split up - the binary in /usr/bin, extra libraries in /usr/lib, etc.

But looking at something that is more structural - pacman

$ pacman -Ql pacman
pacman /etc/
pacman /etc/makepkg.conf
pacman /etc/pacman.conf
pacman /usr/
pacman /usr/bin/
pacman /usr/bin/checkupdates
pacman /usr/bin/makepkg
pacman /usr/bin/makepkg-template
pacman /usr/bin/paccache
pacman /usr/bin/pacdiff
pacman /usr/bin/paclist
pacman /usr/bin/paclog-pkglist
pacman /usr/bin/pacman
pacman /usr/bin/pacman-conf
pacman /usr/bin/pacman-db-upgrade
pacman /usr/bin/pacman-key
pacman /usr/bin/pacscripts
pacman /usr/bin/pacsearch
pacman /usr/bin/pacsort
pacman /usr/bin/pactree
pacman /usr/bin/rankmirrors
pacman /usr/bin/repo-add
pacman /usr/bin/repo-elephant
pacman /usr/bin/repo-remove
pacman /usr/bin/testpkg
pacman /usr/bin/updpkgsums
pacman /usr/bin/vercmp
pacman /usr/include/
pacman /usr/include/alpm.h
pacman /usr/include/alpm_list.h
pacman /usr/lib/
pacman /usr/lib/libalpm.so
pacman /usr/lib/libalpm.so.12
pacman /usr/lib/libalpm.so.12.0.2
pacman /usr/lib/pkgconfig/
pacman /usr/lib/pkgconfig/libalpm.pc
pacman /usr/lib/systemd/
pacman /usr/lib/systemd/system/
pacman /usr/lib/systemd/system/etc-pacman.d-gnupg.mount
pacman /usr/lib/systemd/system/paccache.service
pacman /usr/lib/systemd/system/paccache.timer
pacman /usr/lib/systemd/system/pacman-init.service
pacman /usr/share/
pacman /usr/share/bash-completion/
pacman /usr/share/bash-completion/completions/
pacman /usr/share/bash-completion/completions/makepkg
pacman /usr/share/bash-completion/completions/pacman
pacman /usr/share/bash-completion/completions/pacman-key
pacman /usr/share/libalpm/
pacman /usr/share/libalpm/hooks/
pacman /usr/share/locale/
pacman /usr/share/locale/ar/
pacman /usr/share/locale/ar/LC_MESSAGES/
pacman /usr/share/locale/ar/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/ar/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/ast/
pacman /usr/share/locale/ast/LC_MESSAGES/
pacman /usr/share/locale/ast/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/ast/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/bg/
pacman /usr/share/locale/bg/LC_MESSAGES/
pacman /usr/share/locale/bg/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/bg/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/bg/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/br/
pacman /usr/share/locale/br/LC_MESSAGES/
pacman /usr/share/locale/br/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/br/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/br/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/ca/
pacman /usr/share/locale/ca/LC_MESSAGES/
pacman /usr/share/locale/ca/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/ca/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/ca/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/cs/
pacman /usr/share/locale/cs/LC_MESSAGES/
pacman /usr/share/locale/cs/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/cs/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/cs/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/da/
pacman /usr/share/locale/da/LC_MESSAGES/
pacman /usr/share/locale/da/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/da/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/da/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/de/
pacman /usr/share/locale/de/LC_MESSAGES/
pacman /usr/share/locale/de/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/de/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/de/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/el/
pacman /usr/share/locale/el/LC_MESSAGES/
pacman /usr/share/locale/el/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/el/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/el/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/en_GB/
pacman /usr/share/locale/en_GB/LC_MESSAGES/
pacman /usr/share/locale/en_GB/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/en_GB/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/en_GB/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/eo/
pacman /usr/share/locale/eo/LC_MESSAGES/
pacman /usr/share/locale/eo/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/eo/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/eo/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/es/
pacman /usr/share/locale/es/LC_MESSAGES/
pacman /usr/share/locale/es/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/es/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/es/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/es_419/
pacman /usr/share/locale/es_419/LC_MESSAGES/
pacman /usr/share/locale/es_419/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/es_419/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/es_419/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/eu/
pacman /usr/share/locale/eu/LC_MESSAGES/
pacman /usr/share/locale/eu/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/eu/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/eu/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/eu_ES/
pacman /usr/share/locale/eu_ES/LC_MESSAGES/
pacman /usr/share/locale/eu_ES/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/eu_ES/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/eu_ES/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/fi/
pacman /usr/share/locale/fi/LC_MESSAGES/
pacman /usr/share/locale/fi/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/fi/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/fi/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/fr/
pacman /usr/share/locale/fr/LC_MESSAGES/
pacman /usr/share/locale/fr/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/fr/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/fr/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/gl/
pacman /usr/share/locale/gl/LC_MESSAGES/
pacman /usr/share/locale/gl/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/gl/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/gl/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/hr/
pacman /usr/share/locale/hr/LC_MESSAGES/
pacman /usr/share/locale/hr/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/hr/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/hu/
pacman /usr/share/locale/hu/LC_MESSAGES/
pacman /usr/share/locale/hu/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/hu/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/hu/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/id/
pacman /usr/share/locale/id/LC_MESSAGES/
pacman /usr/share/locale/id/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/id/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/id/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/it/
pacman /usr/share/locale/it/LC_MESSAGES/
pacman /usr/share/locale/it/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/it/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/it/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/ja/
pacman /usr/share/locale/ja/LC_MESSAGES/
pacman /usr/share/locale/ja/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/ja/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/ja/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/kk/
pacman /usr/share/locale/kk/LC_MESSAGES/
pacman /usr/share/locale/kk/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/ko/
pacman /usr/share/locale/ko/LC_MESSAGES/
pacman /usr/share/locale/ko/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/ko/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/ko/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/lt/
pacman /usr/share/locale/lt/LC_MESSAGES/
pacman /usr/share/locale/lt/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/lt/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/lt/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/nb/
pacman /usr/share/locale/nb/LC_MESSAGES/
pacman /usr/share/locale/nb/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/nb/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/nb/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/nl/
pacman /usr/share/locale/nl/LC_MESSAGES/
pacman /usr/share/locale/nl/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/nl/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/nl/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/pl/
pacman /usr/share/locale/pl/LC_MESSAGES/
pacman /usr/share/locale/pl/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/pl/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/pl/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/pt/
pacman /usr/share/locale/pt/LC_MESSAGES/
pacman /usr/share/locale/pt/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/pt/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/pt/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/pt_BR/
pacman /usr/share/locale/pt_BR/LC_MESSAGES/
pacman /usr/share/locale/pt_BR/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/pt_BR/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/pt_BR/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/ro/
pacman /usr/share/locale/ro/LC_MESSAGES/
pacman /usr/share/locale/ro/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/ro/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/ro/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/ru/
pacman /usr/share/locale/ru/LC_MESSAGES/
pacman /usr/share/locale/ru/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/ru/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/ru/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/sk/
pacman /usr/share/locale/sk/LC_MESSAGES/
pacman /usr/share/locale/sk/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/sk/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/sk/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/sl/
pacman /usr/share/locale/sl/LC_MESSAGES/
pacman /usr/share/locale/sl/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/sl/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/sl/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/sr/
pacman /usr/share/locale/sr/LC_MESSAGES/
pacman /usr/share/locale/sr/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/sr/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/sr/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/sr@latin/
pacman /usr/share/locale/sr@latin/LC_MESSAGES/
pacman /usr/share/locale/sr@latin/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/sr@latin/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/sr@latin/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/sv/
pacman /usr/share/locale/sv/LC_MESSAGES/
pacman /usr/share/locale/sv/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/sv/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/sv/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/tr/
pacman /usr/share/locale/tr/LC_MESSAGES/
pacman /usr/share/locale/tr/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/tr/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/tr/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/uk/
pacman /usr/share/locale/uk/LC_MESSAGES/
pacman /usr/share/locale/uk/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/uk/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/uk/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/zh_CN/
pacman /usr/share/locale/zh_CN/LC_MESSAGES/
pacman /usr/share/locale/zh_CN/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/zh_CN/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/zh_CN/LC_MESSAGES/pacman.mo
pacman /usr/share/locale/zh_TW/
pacman /usr/share/locale/zh_TW/LC_MESSAGES/
pacman /usr/share/locale/zh_TW/LC_MESSAGES/libalpm.mo
pacman /usr/share/locale/zh_TW/LC_MESSAGES/pacman-scripts.mo
pacman /usr/share/locale/zh_TW/LC_MESSAGES/pacman.mo
pacman /usr/share/makepkg-template/
pacman /usr/share/makepkg/
pacman /usr/share/makepkg/buildenv.sh
pacman /usr/share/makepkg/buildenv/
pacman /usr/share/makepkg/buildenv/buildflags.sh
pacman /usr/share/makepkg/buildenv/compiler.sh
pacman /usr/share/makepkg/buildenv/debugflags.sh
pacman /usr/share/makepkg/buildenv/makeflags.sh
pacman /usr/share/makepkg/executable.sh
pacman /usr/share/makepkg/executable/
pacman /usr/share/makepkg/executable/ccache.sh
pacman /usr/share/makepkg/executable/checksum.sh
pacman /usr/share/makepkg/executable/distcc.sh
pacman /usr/share/makepkg/executable/fakeroot.sh
pacman /usr/share/makepkg/executable/gpg.sh
pacman /usr/share/makepkg/executable/gzip.sh
pacman /usr/share/makepkg/executable/pacman.sh
pacman /usr/share/makepkg/executable/strip.sh
pacman /usr/share/makepkg/executable/sudo.sh
pacman /usr/share/makepkg/executable/vcs.sh
pacman /usr/share/makepkg/integrity.sh
pacman /usr/share/makepkg/integrity/
pacman /usr/share/makepkg/integrity/generate_checksum.sh
pacman /usr/share/makepkg/integrity/generate_signature.sh
pacman /usr/share/makepkg/integrity/verify_checksum.sh
pacman /usr/share/makepkg/integrity/verify_signature.sh
pacman /usr/share/makepkg/lint_config.sh
pacman /usr/share/makepkg/lint_config/
pacman /usr/share/makepkg/lint_config/ext.sh
pacman /usr/share/makepkg/lint_config/paths.sh
pacman /usr/share/makepkg/lint_config/source_date_epoch.sh
pacman /usr/share/makepkg/lint_config/variable.sh
pacman /usr/share/makepkg/lint_package.sh
pacman /usr/share/makepkg/lint_package/
pacman /usr/share/makepkg/lint_package/build_references.sh
pacman /usr/share/makepkg/lint_package/dotfiles.sh
pacman /usr/share/makepkg/lint_package/file_names.sh
pacman /usr/share/makepkg/lint_package/missing_backup.sh
pacman /usr/share/makepkg/lint_pkgbuild.sh
pacman /usr/share/makepkg/lint_pkgbuild/
pacman /usr/share/makepkg/lint_pkgbuild/arch.sh
pacman /usr/share/makepkg/lint_pkgbuild/arch_specific.sh
pacman /usr/share/makepkg/lint_pkgbuild/backup.sh
pacman /usr/share/makepkg/lint_pkgbuild/changelog.sh
pacman /usr/share/makepkg/lint_pkgbuild/checkdepends.sh
pacman /usr/share/makepkg/lint_pkgbuild/conflicts.sh
pacman /usr/share/makepkg/lint_pkgbuild/depends.sh
pacman /usr/share/makepkg/lint_pkgbuild/epoch.sh
pacman /usr/share/makepkg/lint_pkgbuild/fullpkgver.sh
pacman /usr/share/makepkg/lint_pkgbuild/install.sh
pacman /usr/share/makepkg/lint_pkgbuild/makedepends.sh
pacman /usr/share/makepkg/lint_pkgbuild/optdepends.sh
pacman /usr/share/makepkg/lint_pkgbuild/options.sh
pacman /usr/share/makepkg/lint_pkgbuild/package_function.sh
pacman /usr/share/makepkg/lint_pkgbuild/package_function_variable.sh
pacman /usr/share/makepkg/lint_pkgbuild/pkgbase.sh
pacman /usr/share/makepkg/lint_pkgbuild/pkglist.sh
pacman /usr/share/makepkg/lint_pkgbuild/pkgname.sh
pacman /usr/share/makepkg/lint_pkgbuild/pkgrel.sh
pacman /usr/share/makepkg/lint_pkgbuild/pkgver.sh
pacman /usr/share/makepkg/lint_pkgbuild/provides.sh
pacman /usr/share/makepkg/lint_pkgbuild/source.sh
pacman /usr/share/makepkg/lint_pkgbuild/util.sh
pacman /usr/share/makepkg/lint_pkgbuild/variable.sh
pacman /usr/share/makepkg/source.sh
pacman /usr/share/makepkg/source/
pacman /usr/share/makepkg/source/bzr.sh
pacman /usr/share/makepkg/source/file.sh
pacman /usr/share/makepkg/source/git.sh
pacman /usr/share/makepkg/source/hg.sh
pacman /usr/share/makepkg/source/local.sh
pacman /usr/share/makepkg/source/svn.sh
pacman /usr/share/makepkg/srcinfo.sh
pacman /usr/share/makepkg/tidy.sh
pacman /usr/share/makepkg/tidy/
pacman /usr/share/makepkg/tidy/docs.sh
pacman /usr/share/makepkg/tidy/emptydirs.sh
pacman /usr/share/makepkg/tidy/libtool.sh
pacman /usr/share/makepkg/tidy/purge.sh
pacman /usr/share/makepkg/tidy/staticlibs.sh
pacman /usr/share/makepkg/tidy/strip.sh
pacman /usr/share/makepkg/tidy/zipman.sh
pacman /usr/share/makepkg/util.sh
pacman /usr/share/makepkg/util/
pacman /usr/share/makepkg/util/compress.sh
pacman /usr/share/makepkg/util/config.sh
pacman /usr/share/makepkg/util/dirsize.sh
pacman /usr/share/makepkg/util/error.sh
pacman /usr/share/makepkg/util/message.sh
pacman /usr/share/makepkg/util/option.sh
pacman /usr/share/makepkg/util/parseopts.sh
pacman /usr/share/makepkg/util/pkgbuild.sh
pacman /usr/share/makepkg/util/schema.sh
pacman /usr/share/makepkg/util/source.sh
pacman /usr/share/makepkg/util/util.sh
pacman /usr/share/man/
pacman /usr/share/man/man1/
pacman /usr/share/man/man1/makepkg-template.1.gz
pacman /usr/share/man/man3/
pacman /usr/share/man/man3/libalpm.3.gz
pacman /usr/share/man/man5/
pacman /usr/share/man/man5/BUILDINFO.5.gz
pacman /usr/share/man/man5/PKGBUILD.5.gz
pacman /usr/share/man/man5/alpm-hooks.5.gz
pacman /usr/share/man/man5/makepkg.conf.5.gz
pacman /usr/share/man/man5/pacman.conf.5.gz
pacman /usr/share/man/man8/
pacman /usr/share/man/man8/checkupdates.8.gz
pacman /usr/share/man/man8/makepkg.8.gz
pacman /usr/share/man/man8/paccache.8.gz
pacman /usr/share/man/man8/pacdiff.8.gz
pacman /usr/share/man/man8/pacman-conf.8.gz
pacman /usr/share/man/man8/pacman-key.8.gz
pacman /usr/share/man/man8/pacman.8.gz
pacman /usr/share/man/man8/pacsort.8.gz
pacman /usr/share/man/man8/pactree.8.gz
pacman /usr/share/man/man8/repo-add.8.gz
pacman /usr/share/man/man8/repo-remove.8.gz
pacman /usr/share/man/man8/updpkgsums.8.gz
pacman /usr/share/man/man8/vercmp.8.gz
pacman /usr/share/pacman/
pacman /usr/share/pacman/PKGBUILD-split.proto
pacman /usr/share/pacman/PKGBUILD-vcs.proto
pacman /usr/share/pacman/PKGBUILD.proto
pacman /usr/share/pacman/proto.install
pacman /usr/share/pkgconfig/
pacman /usr/share/pkgconfig/libmakepkg.pc
pacman /usr/share/vim/
pacman /usr/share/vim/vimfiles/
pacman /usr/share/vim/vimfiles/ftdetect/
pacman /usr/share/vim/vimfiles/ftdetect/PKGBUILD.vim
pacman /usr/share/vim/vimfiles/ftplugin/
pacman /usr/share/vim/vimfiles/ftplugin/PKGBUILD.vim
pacman /usr/share/vim/vimfiles/syntax/
pacman /usr/share/vim/vimfiles/syntax/PKGBUILD.vim
pacman /usr/share/zsh/
pacman /usr/share/zsh/site-functions/
pacman /usr/share/zsh/site-functions/_pacman
pacman /var/
pacman /var/cache/
pacman /var/cache/pacman/
pacman /var/cache/pacman/pkg/
pacman /var/lib/
pacman /var/lib/pacman/

And as you can see here still the bulk is in /usr/, but there are also some directories and files in /var/ and /etc/ as well.

EDIT.
Found a pretty good explanation here

5 Likes

Expanding on what @cscs wrote:

TL;DR

  • Windows uses multiple disks or partitions under multiple drive letters
  • Linux uses the Linux Filesystem Hierarchy Standard and has only one filesystem (/- that can reside on multiple partitions, not disks like Windows and any partition can be mounted anywhere.
    • /boot contains all the bootloader files (GRUB, kernel files, …)

    • /bin, /sbin: contains user binaries and system binaries (aka sudo binaries) respectively

    • /etc contains system configuration files.

    • /home contains user data and user config files (E.G. if you have one user who sets their resolution to HD whereas you have a UHD screen that’s where this is set)

    • /root contains the home directory for the root user.

    • /lib contains shared libraries that the essential binaries in /bin and /sbin need to be able to run and where kernel modules are stored.

    • /usr contains the UNIX system resources and is intended to be a read-only directory that stores files that aren’t required to boot the system. In general, when you install additional software from your distribution, its binaries, libraries and supporting files go here in their corresponding /usr/bin, /usr/sbin or /usr/lib directories.

    • /opt: contains “optional” software. In general, this is where games install themselves..
      If you would want to move /opt to your HDD, just:

      1. create a new partition on your HDD twice the size of your current /opt
      2. Boot from a USB drive
      3. Copy all files from the old /opt to the new /opt
      4. Add a mount for the new /opt to your /etc/fstab
      5. shut down
      6. Remove USB stick
      7. Boot and test
      8. If OK, boot again with the USB stick
      9. Delete the old /opt (as you copied, remember and if anything went wrong with your fstab, you can just take out the line you added and be back where you started
      10. Reboot again.

The long version:

  • Most people run / on their SSD and /home on their HDD, just like you do.
  • You can move any directory on any partition by using an extra mount in your fstab . For more information read man mount.
    E.G. I have both / and /home on my SSD, but my Music and Videos are on the HDD)
  • Read the full FHS standard (V3.0 at the time of this writing) here and why this is the long version as that’s 43 pages… :smiling_imp:
3 Likes

You can still have ‘programs’ stored in your home, just that these programs will not be installed in the system the normal way, you would need to download and/or compile them to end up with an executable file for example that you could place where you want. I myself have some executable files in my home that I made start menu entries for (with .desktop files). But the programs you install in the system from the tools like pacman must be installed in their predefined places so the whole system is functioning as intended (Linux system generally speaking are a whole bunch of interconnected programs and libraries which work as an ecosystem, and modifying what is intended to be is not good as you will break things in the system because other programs may rely on things not at the places they were supposed to be.

2 Likes