Properly cleaning unsused packages

I have this system installed for 3 years and wondered about cleaning some packages. The wiki reports pacman -Qqd | pacman -Rsu --print - as the command to such situations
But looking the list of packages some of them seem quite important. What other alternatives do I have?

yasm-1.3.0-9
yarn-1.22.22-2
xorg-xsetroot-1.1.3-2
xorg-server-xvfb-21.1.21-1
xerox-phaser-3020-debug-1.00.25-1
wpebackend-fdo-1.16.1-1
wlogout-debug-1.2.2-0
wayland-protocols-1.46-1
wasi-libc++-21.1.6-1
wasi-libc++abi-21.1.6-1
wasi-compiler-rt-21.1.6-1
wasi-libc-1:0+503+ac020b86-1
vulkan-headers-1:1.4.328.1-1
vlc-3.0.21-32
vlc-gui-qt-3.0.21-32
vlc-plugins-video-output-3.0.21-32
vlc-plugin-pulse-3.0.21-32
vlc-plugin-lua-3.0.21-32
vlc-cli-3.0.21-32
visual-studio-code-insiders-bin-debug-1732700562-1
uvicorn-0.35.0-1
utf8cpp-4.0.6-1
usbmuxd-1.1.1-4
uad-ng-bin-debug-1.1.2-1
tk-8.6.16-1
threadweaver5-5.116.0-2
teams-debug-1.5.00.23861-1
syntax-highlighting5-5.116.0-2
sublime-text-4-debug-4.4200-1
sublime-merge-debug-2112-1
stremio-debug-4.4.169-1
squashfs-tools-4.7.4-1
sqlcipher-4.6.1-1
source-to-image-bin-debug-1.5.1-1
simplescreenrecorder-debug-0.4.4-4
scdoc-1.11.4-1
qt6pas-6.2.10-2
qt6-wayland-6.10.1-1
qt5pas-1:1.2.16-1
qt5-tools-5.15.18+kde+r3-1
qt5-sensors-5.15.18-1
qt5-remoteobjects-5.15.18-1
qca-qt5-2.3.10-4
python2-debug-2.7.18-12
python2-2.7.18-12
python-websockets-15.0.1-1
python-waitress-3.0.2-1
python-validate-pyproject-0.24.1-1
python-uvloop-0.21.0-2
python-ujson-5.11.0-1
python-tomli-2.2.1-1
python-setuptools-scm-9.2.2-1
python-setuptools-reproducible-0.1-1
python-send2trash-1.8.3-2
python-responses-0.25.8-1
python-pytest-cov-6.1.1-1
python-pytest-benchmark-4.0.0-7
python-pytest-asyncio-0.26.0-1
python-pytest-1:8.4.2-1
python-pysocks-1.7.1-10
python-py-cpuinfo-9.0.0-5
python-prometheus_client-0.23.1-1
python-portend-3.2.1-1
python-tempora-5.8.1-1
python-poetry-2.2.1-1
python-virtualenv-20.35.4-1
python-tomlkit-0.13.3-1
python-shellingham-1.5.4-3
python-requests-toolbelt-1.0.0-3
python-poetry-plugin-export-1.9.0-1
python-poetry-core-2.2.1-1
python-pkginfo-1.12.1.2-1
python-pexpect-4.9.0-4
python-ptyprocess-0.7.0-8
python-pdm-backend-2.4.6-1
python-tomli-w-1.2.0-1
python-pyproject-metadata-0.9.0-2
python-pbs-installer-2025.10.31-1
python-ordered-set-4.1.0-7
python-lark-parser-1.3.1-1
python-keyring-25.7.0-1
python-secretstorage-3.3.3-6
python-jsonschema-4.25.1-1
python-jsonschema-specifications-2025.9.1-1
python-referencing-0.37.0-1
python-rpds-py-0.29.0-1
python-jaraco.classes-3.4.0-2
python-installer-0.7.0-10
python-iniconfig-2.1.0-1
python-importlib-metadata-8.7.0-1
python-zipp-3.21.0-2
python-httpx-0.28.1-3
python-sniffio-1.3.1-4
python-httptools-0.6.4-2
python-httpcore-1.0.9-2
python-hatchling-1.28.0-1
python-trove-classifiers-2025.11.14.15-1
python-pluggy-1.6.0-1
python-pathspec-0.12.1-3
python-h11-0.16.0-1
python-grpcio-1.76.0-2
python-grpcio-tools-1.76.0-2
python-google-api-core-2.19.1-2
python-pytz-2025.2-1
python-googleapis-common-protos-1.72.0-1
python-protobuf-33.1-1
python-google-auth-2.43.0-1
python-standard-cgi-3.13.0-3
python-oauth2client-4.1.3-11
python-pyasn1-modules-0.4.2-1
python-httplib2-0.31.0-1
python-pyparsing-3.2.5-1
python-gbinder-debug-1.1.2-3
python-flask-cors-6.0.1-1
python-flask-3.1.2-1
python-werkzeug-3.1.3-1
python-itsdangerous-2.2.0-1
python-flaky-3.8.1-2
python-findpython-0.7.1-1
python-fastjsonschema-2.21.2-1
python-fastapi-0.123.0-1
python-starlette-0.50.0-1
python-pydantic-settings-2.12.0-1
python-pydantic-extra-types-2.10.6-1
python-editables-0.5-5
python-dunamai-1.25.0-1
python-dulwich-0.24.10-1
python-dotenv-1.2.1-1
python-distro-1.9.0-3
python-distlib-0.4.0-1
python-decorator-5.2.1-1
python-coverage-7.12.0-1
python-cleo-1:2.1.0-1
python-rapidfuzz-3.14.3-1
python-crashtest-0.4.1-4
python-cachy-0.3.0-11
python-cachetools-6.2.2-1
python-build-1.3.0-1
python-pyproject-hooks-1.2.0-3
python-blinker-1.9.0-1
python-async-timeout-5.0.1-1
python-asgiref-3.10.0-1
python-argcomplete-3.6.2-1
python-anyio-4.12.0-1
python-annotated-doc-0.0.4-1
purpose5-5.116.0-1
proj-9.7.0-1
prison5-5.116.0-1
popsicle-debug-1.3.3-2
poppler-qt5-25.11.0-1
plutovg-debug-1.3.1-1
plutosvg-debug-0.0.7-1
plasma5-integration-6.5.3-2
plasma-framework5-debug-5.116.0-2
plasma-framework5-5.116.0-2
phonon-qt5-gstreamer-4.10.0-5
phonon-qt5-debug-4.12.0-8
phonon-qt5-4.12.0-8
pegtl-3.2.7-2
patchelf-0.18.0-3
pandoc-cli-3.5-2
pacseek-debug-1.8.5-1
openssl-1.1-1.1.1.w-2
openmpi-5.0.9-2
prrte-3.0.12-1
openucx-1.19.1-1
openpmix-5.0.9-1
opencv2-debug-2.4.13.7-7
oh-my-posh-bin-debug-28.1.0-1
nvm-0.40.3-1
npm-11.6.4-1
noisetorch-debug-0.12.2-4
node-gyp-12.1.0-1
semver-7.7.3-1
nodejs-nopt-7.2.1-1
net-tools-2.10-3
nasm-3.01-1
mold-2.40.4-1
mimalloc-2.2.4-1
meson-1.9.1-2
python-tqdm-4.67.1-2
ninja-1.13.2-1
mbedtls2-2.28.10-1
maven-3.9.11-1
mathjax-4.0.0-1
lua52-5.2.4-8
lomoco-debug-1.0-12
llvm-21.1.6-1
libwpe-1.16.3-1
libupnp-1.14.25-1
libtar-1.2.20-7
libomxil-bellagio-0.9.3-5
libmatroska-1.7.1-2
libmad-0.15.1b-10
libksane5-24.08.3-1
libkexiv2-qt5-25.08.3-1
libkate-0.4.3-1
python-wxpython-1:4.2.3-3
wxwidgets-gtk3-3.2.8.1-2
wxwidgets-common-3.2.8.1-2
libmspack-1:1.11-1
liboggz-1.1.3-1
libinstpatch-1.1.7-2
libicns-0.8.1-11
libgtop-2.41.3-2
libgnome-keyring-1:3.12.0+r14+g23438cc-1
libglibutil-debug-1.0.80-1
libgbinder-debug-1.1.42-2
libfabric-2.3.1-1
libebml-1.4.5-1
libdvbpsi-1:1.3.3-3
libcamera-0.6.0-1
libcamera-ipa-0.6.0-1
libblake3-1.8.2-1
lib32-libxrandr-1.5.4-1
lib32-libxkbcommon-1.13.0-1
lib32-libxi-1.8.2-1
lib32-libxcursor-1.2.3-1
lib32-libxrender-0.9.11-2
lib32-libunwind-1.8.1-1
lib32-libpcap-1.10.5-3
lib32-libnl-3.11.0-1
lib32-harfbuzz-12.2.0-2
lib32-gettext-0.26-1
lib32-acl-2.3.2-1
kwayland5-5.116.0-2
kunitconversion5-5.116.0-1
ksanecore5-24.08.3-1
kpty5-5.116.0-2
kpeople5-5.116.0-1
kparts5-5.116.0-2
kooha-git-debug-2.3.1.r34.g7307fde-1
knewstuff5-5.116.0-4
syndication5-5.116.0-2
kjs-5.115.0-1
kitemmodels5-5.116.0-1
kemoticons-5.116.0-2
kdoctools5-debug-5.116.0-3
kdoctools5-5.116.0-3
kdesignerplugin-debug-5.116.0-2
kdesignerplugin-5.116.0-2
kdelibs4support-debug-5.116.0-2
kddockwidgets-qt6-debug-2.2.5-1
kcontacts5-5.116.0-1
kcolorpicker-qt5-0.3.1-4
kactivities5-5.116.0-2
jre17-openjdk-17.0.17.u10-1
jdk-openjdk-25.0.1.u8-1
imake-1.0.10-2
ibus-1.5.33-1
libibus-1.5.33-1
hslua-cli-1.4.3-81
help2man-1.49.3-2
perl-locale-gettext-1.07-16
hdf5-1.14.6-5
libaec-1.1.4-2
haskell-type-equality-1.0.1-3
haskell-socks-0.6.1-338
haskell-sha-1.6.4.4-22
haskell-pandoc-server-0.1.0.9-2
haskell-wai-cors-0.2.7-483
haskell-servant-server-0.20.3.0-58
haskell-wai-app-static-3.1.9-224
haskell-wai-extra-3.1.18-32
haskell-warp-3.4.0-10
haskell-word8-0.1.3-25
haskell-simple-sendfile-0.2.32-189
haskell-recv-0.1.1-71
haskell-wai-logger-2.5.0-135
haskell-wai-3.2.4-147
haskell-servant-0.20.3.0-44
haskell-vault-0.3.1.5-297
haskell-singleton-bool-0.1.8-46
haskell-some-1.0.6-72
haskell-pandoc-lua-engine-0.3.3-2
haskell-pandoc-lua-marshal-0.2.9-6
haskell-pandoc-3.5-2
haskell-typst-0.6-12
haskell-yaml-0.11.11.2-198
haskell-toml-parser-2.0.1.2-63
haskell-regex-tdfa-1.3.2.5-7
haskell-regex-base-0.94.0.3-3
haskell-texmath-0.12.8.11-8
haskell-xml-1.3.14-33
haskell-typst-symbols-0.1.6-2
haskell-tagsoup-0.14.8-326
haskell-skylighting-0.14.3-16
haskell-skylighting-format-latex-0.1-284
haskell-skylighting-format-context-0.1.0.2-249
haskell-skylighting-format-blaze-html-0.1.1.3-139
haskell-skylighting-format-ansi-0.1-285
haskell-skylighting-core-0.14.3-16
haskell-pretty-show-1.10-20
haskell-ordered-containers-0.2.4-100
haskell-monad-control-1.0.3.1-268
haskell-transformers-base-0.4.6-268
haskell-mmorph-1.2.1-2
haskell-lpeg-1.1.0-36
lua-lpeg-1.1.0-4
haskell-libyaml-0.1.4-154
haskell-lexer-1.2-2
haskell-juicypixels-3.3.9-91
haskell-jira-wiki-markup-1.5.1-122
haskell-ipynb-0.2-276
haskell-hunit-1.6.2.0-425
haskell-http2-5.1.0-9
haskell-time-manager-0.0.1-146
haskell-unliftio-0.2.25.1-89
haskell-safe-exceptions-0.1.7.4-188
haskell-network-control-0.1.3-16
haskell-psqueues-0.2.8.2-51
haskell-network-byte-order-0.1.7-4
haskell-http-media-0.8.1.1-114
haskell-utf8-string-1.0.2-255
haskell-http-date-0.0.11-238
haskell-http-client-tls-0.3.6.4-130
haskell-http-client-0.7.19-54
haskell-mime-types-0.1.2.0-4
haskell-http-api-data-0.6.1-39
haskell-text-iso8601-0.1.1-54
haskell-http-types-0.12.4-134
haskell-hslua-repl-0.1.2-141
haskell-isocline-1.0.9-4
haskell-hslua-module-zip-1.1.3-41
haskell-zip-archive-0.4.3.2-105
haskell-hslua-module-version-1.1.1-138
haskell-hslua-module-text-1.1.0.1-162
haskell-hslua-module-system-1.1.2-48
haskell-temporary-1.3-899
haskell-hslua-module-path-1.1.1-96
haskell-hslua-module-doclayout-1.2.0-2
haskell-hslua-list-1.1.4-23
haskell-hslua-2.3.0-194
haskell-hslua-packaging-2.3.1-145
haskell-hslua-objectorientation-2.3.1-43
haskell-hslua-typing-0.1.1-137
haskell-hslua-classes-2.3.1-24
haskell-hslua-aeson-2.3.1.1-42
haskell-hslua-marshalling-2.3.1-135
haskell-hslua-core-2.3.2-28
haskell-lua-2.3.3-99
haskell-haddock-library-1.11.0-176
haskell-gridtables-0.1.1.0-18
haskell-glob-0.10.2-190
haskell-ghc-bignum-orphans-0.1.1-4
haskell-generics-sop-0.5.1.3-5
haskell-sop-core-0.5.0.2-4
haskell-fast-logger-3.2.4-35
haskell-unix-compat-0.7.4.1-46
haskell-easy-file-0.2.5-121
haskell-doctemplates-0.11.0.1-69
haskell-text-conversions-0.3.1.1-164
haskell-djot-0.1.2.3-6
haskell-doclayout-0.5-10
haskell-digest-0.0.2.1-2
haskell-dec-0.0.6-2
haskell-crypton-connection-0.4.5-19
haskell-tls-2.0.6-64
haskell-unix-time-0.4.17-69
haskell-old-time-1.1.0.4-5
haskell-serialise-0.2.6.1-167
haskell-crypton-x509-validation-1.6.14-53
haskell-iproute-1.7.15-84
haskell-crypton-x509-system-1.6.7-137
haskell-crypton-x509-store-1.6.12-2
haskell-crypton-x509-1.7.7-65
haskell-pem-0.2.4-386
haskell-crypton-socks-0.6.2-17
haskell-network-bsd-2.8.1.0-311
haskell-crypton-1.0.4-10
haskell-cookie-0.5.0-2
haskell-constraints-0.14.2-79
haskell-commonmark-pandoc-0.2.2.3-38
haskell-commonmark-extensions-0.2.5.5-48
haskell-network-uri-2.6.4.2-133
haskell-th-compat-0.1.6-83
haskell-emojis-0.1.4.1-82
haskell-commonmark-0.2.6.1-7
haskell-unicode-transforms-0.4.0.1-177
haskell-unicode-data-0.6.0-34
haskell-citeproc-0.8.1.1-77
haskell-xml-conduit-1.9.1.4-143
haskell-xml-types-0.3.8-11
haskell-conduit-extra-1.3.8-69
haskell-typed-process-0.2.13.0-153
haskell-streaming-commons-0.2.3.1-2
haskell-zlib-0.7.0.0-67
haskell-network-3.1.4.0-121
haskell-conduit-1.3.6.1-126
haskell-resourcet-1.2.6-242
haskell-unliftio-core-0.2.1.0-4
haskell-mono-traversable-1.0.21.0-128
haskell-vector-algorithms-0.9.1.0-116
haskell-split-0.2.5-146
haskell-uniplate-1.6.13-335
haskell-unicode-collation-0.1.3.6-120
haskell-th-lift-instances-0.1.20-152
haskell-th-lift-0.8.6-2
haskell-text-icu-0.8.0.5-104
haskell-safe-0.3.21-105
haskell-pandoc-types-1.23.1-157
haskell-syb-0.7.3-67
haskell-file-embed-0.0.16.0-2
haskell-data-default-0.7.1.3-33
haskell-data-default-instances-old-locale-0.0.1.2-2
haskell-old-locale-1.0.0.7-33
haskell-data-default-instances-dlist-0.0.1.2-136
haskell-data-default-instances-containers-0.1.0.3-4
haskell-data-default-class-0.1.2.2-2
haskell-cereal-0.5.8.3-4
haskell-cborg-0.2.10.0-79
haskell-half-0.3.3-67
haskell-cassava-0.5.4.1-38
haskell-only-0.1-25
haskell-case-insensitive-1.2.1.0-374
haskell-call-stack-0.4.0-382
haskell-byteorder-1.0.4-27
haskell-bsb-http-chunked-0.0.0.4-497
haskell-boring-0.2.2-2
haskell-blaze-html-0.9.2.0-103
haskell-blaze-markup-0.8.3.0-113
haskell-blaze-builder-0.4.4.1-26
haskell-bitvec-1.1.5.0-36
haskell-base64-bytestring-1.2.1.0-270
haskell-base16-bytestring-1.0.2.0-180
haskell-base-unicode-symbols-0.2.4.2-16
haskell-auto-update-0.1.6-449
haskell-attoparsec-iso8601-1.1.1.0-20
haskell-integer-conversion-0.1.1-54
haskell-async-2.2.5-270
haskell-asn1-parse-0.9.5-330
haskell-asn1-encoding-0.9.6-331
haskell-asn1-types-0.3.4-309
haskell-memory-0.18.0-108
haskell-basement-0.0.16-4
haskell-hourglass-0.2.12-346
haskell-appar-0.1.8-16
haskell-ansi-wl-pprint-1.0.2-234
haskell-prettyprinter-compat-ansi-wl-pprint-1.0.2-236
haskell-aeson-pretty-0.8.10-143
haskell-cmdargs-0.10.22-4
haskell-attoparsec-aeson-2.1.0.0-167
haskell-aeson-2.1.2.1-183
haskell-witherable-0.4.2-230
haskell-uuid-types-1.0.6-224
haskell-time-compat-1.9.8-28
haskell-text-short-0.1.6-180
haskell-strict-0.5.1-18
haskell-semialign-1.3.1-53
haskell-these-1.2.1-227
haskell-semigroupoids-6.0.1-97
haskell-contravariant-1.5.5-6
haskell-statevar-1.2.2-5
haskell-bifunctors-5.6.2-58
haskell-th-abstraction-0.5.0.0-2
haskell-comonad-5.0.9-121
haskell-distributive-0.6.2.1-413
haskell-assoc-1.1.1-40
haskell-indexed-traversable-instances-0.1.2-125
haskell-vector-0.13.2.0-329
haskell-vector-stream-0.1.0.1-4
haskell-tasty-1.5.2-67
haskell-optparse-applicative-0.18.1.0-257
haskell-transformers-compat-0.7.2-4
haskell-prettyprinter-ansi-terminal-1.1.3-468
haskell-prettyprinter-1.7.1-360
haskell-ansi-terminal-1.0.2-156
haskell-ansi-terminal-types-0.11.5-196
haskell-colour-2.3.6-406
haskell-unordered-containers-0.2.20.1-17
haskell-quickcheck-2.15.0.1-92
haskell-random-1.2.1.3-178
haskell-splitmix-0.1.3-6
haskell-erf-2.0.0.0-27
haskell-indexed-traversable-0.1.4-176
haskell-generically-0.1.1-88
haskell-base-orphans-0.9.3-84
haskell-dlist-1.0-386
haskell-data-fix-0.3.4-142
haskell-base-compat-batteries-0.14.1-45
haskell-onetuple-0.4.2-182
haskell-foldable1-classes-compat-0.1.2-56
haskell-tagged-0.8.9-3
haskell-base-compat-0.14.1-2
haskell-attoparsec-0.14.4-175
haskell-scientific-0.3.8.0-150
haskell-primitive-0.9.1.0-112
haskell-integer-logarithms-1.0.4-142
haskell-hashable-1.4.7.0-19
haskell-os-string-2.0.8-88
gtkglext-debug-1.2.0-20
grub-customizer-debug-5.2.5-2
graphviz-14.0.5-1
gts-0.7.6.121130-5
netpbm-10.86.48-1
granite-1:6.2.0-1
gputest-debug-0.7.0-1
gperf-3.3-1
gnome-common-3.18.0-5
yelp-tools-42.1-2
yelp-xsl-49.0-1
mallard-ducktype-1.0.2-12
itstool-1:2.0.7-3
intltool-0.51.0-6
gtk-doc-1.35.1-1
glib2-docs-2.86.2-1
glib2-devel-2.86.2-1
glew-2.2.0-7
gl2ps-1.4.2-3
ghc-libs-9.6.6-1
numactl-2.0.19-1
geoclue-2.8.0-1
gdb-16.3-1
source-highlight-3.1.9-16
gdb-common-16.3-1
gconf-debug-3.2.6+11+g07808097-15
gconf-3.2.6+11+g07808097-15
gcc14-14.3.1+r25+g42e99e057bd7-1
gcc14-libs-14.3.1+r25+g42e99e057bd7-1
gcc13-debug-13.4.1+r80+gd6ebfe4-1
gcc13-13.4.1+r80+gd6ebfe4-1
gcc13-libs-13.4.1+r80+gd6ebfe4-1
gcc12-libs-12.5.0-2
gcc10-debug-10.5.0-2
gcc10-10.5.0-2
gcc10-libs-10.5.0-2
gcc-d-15.2.1+r301+gf24307422d1d-1
gcc-ada-15.2.1+r301+gf24307422d1d-1
fcitx5-5.1.16-1
fancontrol-gui-debug-0.8-3
extra-cmake-modules-6.20.0-1
execstack-debug-20130503-10
evernote-beta-bin-debug-10.56.9-1
electron-1:38-1
electron38-38.7.2-1
eigen-5.0.1-1
dotnet-sdk-9.0.9.sdk110-1
dotnet-targeting-pack-9.0.9.sdk110-1
netstandard-targeting-pack-9.0.9.sdk110-1
docbook-xsl-1.79.2-9
docbook-xml-4.5-11
dlib-debug-20.0-1
dejagnu-1.6.3-15
expect-5.45.4-5
darknet-git-debug-r455.f6afaabc-1
cython-3.2.2-1
code-insiders-bin-debug-1.95.0_1728049707-1
cmake-4.2.0-1
rhash-1.4.6-1
cppdap-1.58.0-2
cert-viewer-debug-0.9.0-2
cbindgen-0.29.2-1
bridge-utils-1.7.1-2
breeze5-6.5.3-2
frameworkintegration5-5.116.0-2
box2d-3.1.1-1
botan2-2.19.5-2
boost-1.89.0-3
blueprint-compiler-0.18.0-1
autoconf-archive-1:2024.10.16-3
attica5-5.116.0-2
aribb24-1.0.3-4
appstream-qt5-1.0.5-2
antigravity-debug-1.11.9-1
android-udev-20250525-1
ca-certificates-20240618-1
ca-certificates-mozilla-3.118.1-1
adobe-source-code-pro-fonts-2.042u+1.062i+1.026vf-2

It looks to me like you just have a lot of orphans because you haven’t cleaned them in years. Most of those are either build dependencies or old dependencies for other packages. That being said, I didn’t go through every package on the list.

I usually use paru -c to clean orphans as it doesn’t remove optional dependencies but there should be no huge risk in removing those packages if you prefer to do it that way the wiki recommends.

5 Likes

You are right I haven’t done it in ages. Should I add a hook to pacman?

No, you should always review the list before removing the packages. You don’t really want to do it too often either, especially if you build AUR packages. Otherwise you will be constantly removing and reinstalling the same packages. Personally, I only remove orphans a few times per year unless I hit a problem I think removing orphans might cause.

2 Likes

Tip: assuming the haskell* packages come from pandoc-cli only, you can remove them by replacing pandoc-cli with pandoc-bin (in AUR).

2 Likes

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.