mike632t/x11-calc

Missing font on Arch Linux

Overscore opened this issue · 14 comments

Hello, I get the following error message on an Arch Linux:

make clean
make all
x11-calc-25
./x11-calc-25
x11-rpncalc: Version 0.2 [Commit ID: $Format:%h$] 10 Oct 21 10:35:07 (Build: 0058)
x11-rpncalc : Cannot load font '6x12'.

What can I do?
TIA

The error message indicates that "Cannot load font 6x12", which means that it is not on your Arch Linux. Arch Linux is a minimal install, so if it isn't used, it isn't installed.
What Desktop do you have installed, the calculator has been written for an X11 based desktop, so assuming you are running that, you will need to install the font. This specifically uses helvetica-medium font.
I found this reference to a similar issue with missing fonts in Alpine:
missing helvetica font

I'm using xfce-4.16
After installing the following packages, I still get the same error message.

xorg-fonts-75dpi
xorg-fonts-100dpi
xorg-fonts-type1
xorg-fonts-misc-otb
xorg-fonts-misc
adobe-base-14-fonts

Hello, I get the following error message on an Arch Linux:

make clean make all x11-calc-25 ./x11-calc-25 x11-rpncalc: Version 0.2 [Commit ID: $Format:%h$] 10 Oct 21 10:35:07 (Build: 0058) x11-rpncalc : Cannot load font '6x12'.

What can I do? TIA

Hello, I get the following error message on an Arch Linux:

make clean make all x11-calc-25 ./x11-calc-25 x11-rpncalc: Version 0.2 [Commit ID: $Format:%h$] 10 Oct 21 10:35:07 (Build: 0058) x11-rpncalc : Cannot load font '6x12'.

What can I do? TIA

I suspect you need to install xfonts-base ...

I have no package named xfonts-base. Too bad, I give up.

Just compiled and ran on alpine linux
use :
apk search font
to list package with fonts in
I added and was able to compile and run x-calc-25
apk add ghostscript-fonts

You give up too easily :-)

One of the joys of Linux is that just about every distribution seems to use slightly different package naming conventions. In this case since you know the missing font is 6x12 and that you are using the xorg implementation of the X Window system try the following search in google site:archlinux.org/packages/ "6x12" "xorg"

The result suggests you need xorg-fonts-misc but I'm not an Arch user so I can't test it.

https://archlinux.org/packages/extra/any/xorg-fonts-misc/files/

The result suggests you need xorg-fonts-misc but I'm not an Arch user so I can't test it.

I did that. Installing xorg-fonts-misc pulls also in xorg-fonts-alias-misc. The result is the same as above:
x11-rpncalc : Cannot load font '6x12'

Have you tried with ghostscript-fonts?

The result suggests you need xorg-fonts-misc but I'm not an Arch user so I can't test it.

I did that. Installing xorg-fonts-misc pulls also in xorg-fonts-alias-misc. The result is the same as above: x11-rpncalc : Cannot load font '6x12'

That is very odd usr/share/fonts/misc/6x12.pcf.gz is in the list of files in that package. Something else is missing...

I assume you have seen the Font Configuration guide.

If it is possible to post a list of the packages you have installed I might have a go at reproducing the problem, it seems like the sort of minimal environment I like.

The result suggests you need xorg-fonts-misc but I'm not an Arch user so I can't test it.

I did that. Installing xorg-fonts-misc pulls also in xorg-fonts-alias-misc. The result is the same as above: x11-rpncalc : Cannot load font '6x12'

This looks like the same sort of problem..

How to make x11-calc on latest alpine linux:
boot alpine-linux 3.14.2 (virt image on virtualbox)
login : root
setup-alpine
(setup to run from hdd)
poweroff
(remove iso)
boot from hdd
login : root
edit /etc/apk/repositories and uncomment community repository
apk update
apk upgrade
reboot
setup-xorg-base
apk add xfce4 lightdm-gtk-greeter xfce4-terminal xfce4-screensaver
rc-service dbus start
rc-update add dbus
rc-service lightdm start
apk add make gcc gccmakedep libc-dev libstdc++ libcsys libx11 libx11-dev
apk add git

Clone latest x11-calc
git clone https://github.com/mike632t/x11-calc.git
cd x11-calc/src
make MODEL=25
../bin/x11-calc-25

Can you provide a list of all your installed packages?

Now that I know a bit more about how fonts work I've implemented a falback mechanism which will switch to the an adobe courier font if the x11 base fonts are not available (#16 ).

Note that if the fallback font isn't available you will still get the original error message (as that is the desired font)