You are not logged in.
Why did mkfontscale start to remove /usr/share/fonts/encodings/encodings.dir and /usr/share/fonts/encodings/large/encodings.dir?
I have to re-install xorg-fonts-encodings after, to restore them.
Offline
https://man.archlinux.org/man/mkfontscale.1
It's supposed to (re)write that - what exactly are you running why?
Offline
Running this command removes both encodings.dir files:
sudo mkfontscale -- "/usr/share/fonts/100dpi" "/usr/share/fonts/75dpi" "/usr/share/fonts/misc" "/usr/share/fonts/TTF" "/usr/share/fonts/OTF" "/usr/share/fonts/noto" "/usr/share/fonts/Type1" "/usr/share/fonts/cantarell" "/usr/share/fonts/cyrillic" "/usr/share/fonts/encodings" "/usr/share/fonts/encodings/large" "/usr/share/fonts/gsfonts" "/usr/share/fonts/oiio" "/usr/share/fonts/util" "/usr/share/fonts/awesome-terminal-fonts" "/usr/local/share/fonts"Here is what happened. Last Thursday (yesterday) I updated Arch with sudo pacman -Syu. I noticed that the Noto font was one of the packages that would be updated. I confirmed to start the updates.
Immediately I noticed these two lines (that were never ever there before). They were just before pacman started showing messages of Updating xxxxxxxxx .
warning: could not get file information for usr/share/fonts/encodings/encodings.dir
warning: could not get file information for usr/share/fonts/encodings/large/encodings.dirAfter pacman finished I checked the files with:
ls -lah /usr/share/fonts/encodings/encodings.dir /usr/share/fonts/encodings/large/encodings.dir
ls: cannot access '/usr/share/fonts/encodings/encodings.dir': No such file or directory
ls: cannot access '/usr/share/fonts/encodings/large/encodings.dir': No such file or directoryI recreated the files with:
sudo pacman -S xorg-fonts-encodings
[sudo] password for wildflower:
warning: xorg-fonts-encodings-1.1.0-2 is up to date -- reinstalling
resolving dependencies...
looking for conflicting packages...
Packages (1) xorg-fonts-encodings-1.1.0-2
Total Installed Size: 0,61 MiB
Net Upgrade Size: 0,00 MiB
:: Proceed with installation? [Y/n]
(1/1) checking keys in keyring [########################################################################################################] 100%
(1/1) checking package integrity [########################################################################################################] 100%
(1/1) loading package files [########################################################################################################] 100%
(1/1) checking for file conflicts [########################################################################################################] 100%
(1/1) checking available disk space [########################################################################################################] 100%
warning: could not get file information for usr/share/fonts/encodings/encodings.dir
warning: could not get file information for usr/share/fonts/encodings/large/encodings.dir
:: Processing package changes...
(1/1) reinstalling xorg-fonts-encodings [########################################################################################################] 100%
:: Running post-transaction hooks...
(1/2) Arming ConditionNeedsUpdate...
(2/2) Updating fontconfig cache...Then I rechecked the files with:
ls -lah /usr/share/fonts/encodings/encodings.dir /usr/share/fonts/encodings/large/encodings.dir
-rw-r--r-- 1 root root 2,3K 2026-04-09 19:01 /usr/share/fonts/encodings/encodings.dir
-rw-r--r-- 1 root root 832 2026-04-09 19:01 /usr/share/fonts/encodings/large/encodings.dirThen I remembered that I had re-installed the font Victor Mono Nerd with sudo pacman -Syu ttf-victor-mono-nerd the day before, and had finished up with the following commands:
sudo mkfontscale -- "/usr/share/fonts/100dpi" "/usr/share/fonts/75dpi" "/usr/share/fonts/misc" "/usr/share/fonts/TTF" "/usr/share/fonts/OTF" "/usr/share/fonts/noto" "/usr/share/fonts/Type1" "/usr/share/fonts/cantarell" "/usr/share/fonts/cyrillic" "/usr/share/fonts/encodings" "/usr/share/fonts/encodings/large" "/usr/share/fonts/gsfonts" "/usr/share/fonts/oiio" "/usr/share/fonts/util" "/usr/share/fonts/awesome-terminal-fonts" "/usr/local/share/fonts"
sudo mkfontdir -- "/usr/share/fonts/100dpi" "/usr/share/fonts/75dpi" "/usr/share/fonts/misc" "/usr/share/fonts/TTF" "/usr/share/fonts/OTF" "/usr/share/fonts/noto" "/usr/share/fonts/Type1" "/usr/share/fonts/cantarell" "/usr/share/fonts/cyrillic" "/usr/share/fonts/encodings" "/usr/share/fonts/encodings/large" "/usr/share/fonts/gsfonts" "/usr/share/fonts/oiio" "/usr/share/fonts/util" "/usr/share/fonts/awesome-terminal-fonts" "/usr/local/share/fonts"
sudo fc-cache --really-force --verbose
xset fp rehashSo I retraced by issuing those commands again (bare in mind that I had just restored the encodings.dir files).
ls -lah /usr/share/fonts/encodings/encodings.dir /usr/share/fonts/encodings/large/encodings.dir
-rw-r--r-- 1 root root 2,3K 2026-04-09 19:01 /usr/share/fonts/encodings/encodings.dir
-rw-r--r-- 1 root root 832 2026-04-09 19:01 /usr/share/fonts/encodings/large/encodings.dir
sudo mkfontscale -- "/usr/share/fonts/100dpi" "/usr/share/fonts/75dpi" "/usr/share/fonts/misc" "/usr/share/fonts/TTF" "/usr/share/fonts/OTF" "/usr/share/fonts/noto" "/usr/share/fonts/Type1" "/usr/share/fonts/cantarell" "/usr/share/fonts/cyrillic" "/usr/share/fonts/encodings" "/usr/share/fonts/encodings/large" "/usr/share/fonts/gsfonts" "/usr/share/fonts/oiio" "/usr/share/fonts/util" "/usr/share/fonts/awesome-terminal-fonts" "/usr/local/share/fonts"
ls -lah /usr/share/fonts/encodings/encodings.dir /usr/share/fonts/encodings/large/encodings.dir
ls: cannot access '/usr/share/fonts/encodings/encodings.dir': No such file or directory
ls: cannot access '/usr/share/fonts/encodings/large/encodings.dir': No such file or directoryI didn't go any further.
Last edited by Wildflower (2026-04-10 12:55:14)
Offline
and had finished up with the following commands
Why? At all, but also see https://gitlab.archlinux.org/archlinux/ … =heads#L40
Offline
and had finished up with the following commands
Why? At all, ...
I guess because old learned habits stick: https://wiki.archlinux.org/title/Fonts# … plications
And therefore because of package xorg-xfontsel: https://wiki.archlinux.org/title/X_Logi … escription.
But my question is still unanswered. Why did mkfontscale start to delete encodings.dir files?
Offline
"maintainence", I guess - the file is esp. not written by your command so pot. it just cleans up.
Are you suggesting this is a regression?
https://gitlab.archlinux.org/archlinux/ … mmits/main wasn't udpated in a year and the last upstream version was released 2 years ago
Likewise https://gitlab.archlinux.org/archlinux/ … n/PKGBUILD
Offline
No, I'm not suggesting anything. And if it's a regression it's caused because of some other process (which was recently updated) influencing mkfontscale's decision making. I'm just trying to understand what is going on. I'm running mkfontscale often and the issue popped somewhere around the 9th April I think. Not entirely sure.
Offline
https://gitlab.freedesktop.org/xorg/app … eads#L1071 removes the file before creating it - numEncodings is gonna be 0, so it will not be created again.
It's always™ been like that, https://gitlab.freedesktop.org/xorg/app … ge=2#L1071
Offline
https://gitlab.freedesktop.org/xorg/app … eads#L1071 removes the file before creating it - numEncodings is gonna be 0, so it will not be created again.
It's always™ been like that, https://gitlab.freedesktop.org/xorg/app … ge=2#L1071
What makes you say that "numEncodings is gonna be 0"?
Line 292 "ll = listLength(encodingsToDo);". "ll" is then passed to function "doDirectory()" (2nd argument) on line 295 or line 298 (depending on the number of arguments (argc) that were passed to function main()). The second argument of "doDirectory" is named "numEncodings".
I did pass a shed load of font directories. So argc, therefore ll is never going to be zero.
Also, package xorg-mkfontscale has a build date of 09 apr 2026 19:04:40 CEST, and package xorg-fonts-encodings has a build date of 09 apr 2026 19:01:44 CEST.
I've been running those four commands for years after font updates. And the encodings.dir files were never removed before by running mkfontscale. Something changed somewhere. Maybe someone (who is able to explain this sudden behaviour) should update the Arch Wiki here https://wiki.archlinux.org/title/Fonts# … plications to point out that from now the encodings.dir files will be removed by running mkfontscale.
Last edited by Wildflower (2026-04-12 12:08:25)
Offline
If it wasn't some encodings.dir would be written after deleting the present one.
Also, package xorg-mkfontscale has a build date of 09 apr 2026 19:04:40 CEST, and package xorg-fonts-encodings has a build date of 09 apr 2026 19:01:44 CEST.
https://gitlab.archlinux.org/archlinux/ … mmits/main
upgpkg: 1.2.3-2: Rebuild packages older than two years
And the encodings.dir files were never removed before by running mkfontscale.
Not removed or regenerated?
Offline
Oh man. Another possibility gone.
Removed. Deleted. AWOL. MIA. ![]()
I never saw this before:
warning: could not get file information for usr/share/fonts/encodings/encodings.dir
warning: could not get file information for usr/share/fonts/encodings/large/encodings.dirI reproduced the removal of the two files in post #3 of this thread. At the very end.
And I haven't found out yet which process spits out those two lines. I did a quick search in the non-binaries, system wide, but without success with:
sudo grep -rnwI / --colour --devices=skip --exclude-dir=sys --exclude-dir=proc -iEe '*could not get file information for*'
[sudo] password for wildflower:
grep: warning: * at start of expression
grep: /run/user/1000/gvfs: Permission denied
grep: /run/user/1000/doc: Permission deniedLast edited by Wildflower (2026-04-12 17:01:25)
Offline
Removed. Deleted. AWOL. MIA
No, I meant whether you're sure that those files had not been recreated by mkfontscale (because either that happened or the directory wasn't touched at all)
And I haven't found out yet which process spits out those two lines.
https://wiki.archlinux.org/title/Audit_ … ies_access
Edit: it's not very likely but you could still try to downgrade the two packages (undoing the procedural rebuild)
It *could* be that the difference *could* be caused by some inherited inline function. Operative term is "could", though.
Last edited by seth (2026-04-12 20:04:11)
Offline
Running this command removes both encodings.dir files:
sudo mkfontscale -- "/usr/share/fonts/100dpi" "/usr/share/fonts/75dpi" "/usr/share/fonts/misc" "/usr/share/fonts/TTF" "/usr/share/fonts/OTF" "/usr/share/fonts/noto" "/usr/share/fonts/Type1" "/usr/share/fonts/cantarell" "/usr/share/fonts/cyrillic" "/usr/share/fonts/encodings" "/usr/share/fonts/encodings/large" "/usr/share/fonts/gsfonts" "/usr/share/fonts/oiio" "/usr/share/fonts/util" "/usr/share/fonts/awesome-terminal-fonts" "/usr/local/share/fonts"
Why do you run this command in the first place?
xorg-mkfontscale.hook has
Target = usr/share/fonts/*/
Target = !usr/share/fonts/encodings/*so it never pass directories from /usr/share/fonts/encodings/ to mkfontscale.
Offline
Wildflower wrote:Running this command removes both encodings.dir files:
sudo mkfontscale -- "/usr/share/fonts/100dpi" "/usr/share/fonts/75dpi" "/usr/share/fonts/misc" "/usr/share/fonts/TTF" "/usr/share/fonts/OTF" "/usr/share/fonts/noto" "/usr/share/fonts/Type1" "/usr/share/fonts/cantarell" "/usr/share/fonts/cyrillic" "/usr/share/fonts/encodings" "/usr/share/fonts/encodings/large" "/usr/share/fonts/gsfonts" "/usr/share/fonts/oiio" "/usr/share/fonts/util" "/usr/share/fonts/awesome-terminal-fonts" "/usr/local/share/fonts"Why do you run this command in the first place?
xorg-mkfontscale.hook has
Target = usr/share/fonts/*/ Target = !usr/share/fonts/encodings/*so it never pass directories from /usr/share/fonts/encodings/ to mkfontscale.
I don't care what the hook does.
Why don't you read and try to comprehend post #5?
Request to Admins and Mods to move this thread to /dev/null >> Topics Going Nowhere, because now we've entered that stage.
Offline
Why don't you read and try to comprehend post #5?
Sorry, missed that lines.
mkfontscale unconditionally removes encodings.dir and generates new one for font directory according to specified encodings directory. You (1) run it for wrong (non-font) directory, and (2) didn't specify encodings directory.
depending on the number of arguments (argc) that were passed to function main(). ...I did pass a shed load of font directories. So argc, therefore ll is never going to be zero.
argc doesn't matter for number of encodings. encodingsToDo is not a list of directories passed as positional parameters. It is a list of encodings read from a directory specified with '-e' option (line 218). If you don't specify encodings directory with '-e', number of encodings is 0.
Offline
The thread is basically around
Why did mkfontscale start to delete encodings.dir files?
but meantime that most likely just means
I never saw this before:
warning: could not get file information for usr/share/fonts/encodings/encodings.dir warning: could not get file information for usr/share/fonts/encodings/large/encodings.dir
which is either because there's a new warning somewhere or the OP previously simply didn't look.
Request to Admins and Mods to move this thread to /dev/null >> Topics Going Nowhere, because now we've entered that stage.
Not if you audit the access to those files to catch the process informing you that your "old learned habit" is completely wrong.
Offline
warning: could not get file information for usr/share/fonts/encodings/encodings.dir
warning: could not get file information for usr/share/fonts/encodings/large/encodings.dir
These lines are printed by pacman when it calculates disk space freed due to removal/upgrade of package owning that files. Obviously, TS couldn't see them for at least two years (until xorg-fonts-encodings package got updated), despite encodings.dir always being deleted by "old learned habit".
Last edited by dimich (2026-04-13 08:16:23)
Offline