Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 266429 - x11-base/xorg-server doesn't modify xorgs default fontpath, although those directories don't exist
Summary: x11-base/xorg-server doesn't modify xorgs default fontpath, although those di...
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: x86 Linux
: Low enhancement (vote)
Assignee: Gentoo X packagers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-04-16 20:51 UTC by Rüpel
Modified: 2010-12-01 10:08 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Rüpel 2009-04-16 20:51:24 UTC
This is in my Xorg.0.log

(WW) The directory "/usr/share/fonts/OTF" does not exist.
        Entry deleted from font path.

The directory really doesn't exist, but it's even not in my xorg.conf. It's one of the built-in fontpaths. Those are built-in because the ebuild doesn't set the --with-default-font-path switch when configuring the xorg-server. 

To get things consistent again, there are two possibilities:
1.) clean the xorg-server default fontpath (maybe that breaks things for some users?)
2.) create the directories, that are in the built-in fontpath?

I'm not really a fan of the remaining to choices:
3.) creating those unused, empty directories by hand, just to make the warning go away
4.) man, it's just a warning, stop being a nitpicker!

Any idea how this could be resolved? I like 1.

Reproducible: Always

Steps to Reproduce:
1. fresh install -> /usr/share/fonts does not contain all directories of xorgs default fontpath
2. build and run xorg-server


Actual Results:  
look at Xorg.0.log an see the annoying warning message(s)

Expected Results:  
no warning, because only directories, that really exist are in the built-in fontpath

This bug report originated from a topic on the gentoo forum:
http://forums.gentoo.org/viewtopic-t-754532.html

I'm talking about the current stable xorg-server-1.5.3-r5 here.

# emerge --info
Portage 2.1.6.7 (default/linux/x86/2008.0/desktop, gcc-4.3.2, glibc-2.8_p20080602-r1, 2.6.27-gentoo-r10 i686)
=================================================================
System uname: Linux-2.6.27-gentoo-r10-i686-AMD_Athlon-TM-_XP_2600+-with-glibc2.0
Timestamp of tree: Tue, 14 Apr 2009 20:30:01 +0000
app-shells/bash:     3.2_p39
dev-java/java-config: 1.3.7-r1, 2.1.7
dev-lang/python:     2.5.2-r7
dev-util/cmake:      2.6.2-r1
sys-apps/baselayout: 1.12.11.1
sys-apps/sandbox:    1.2.18.1-r2
sys-devel/autoconf:  2.13, 2.63
sys-devel/automake:  1.5, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.2
sys-devel/binutils:  2.18-r3
sys-devel/gcc-config: 1.4.0-r4
sys-devel/libtool:   1.5.26
virtual/os-headers:  2.6.27-r2
ACCEPT_KEYWORDS="x86"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O3 -march=athlon-xp -funroll-loops -fprefetch-loop-arrays -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/config /var/qmail/alias /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/splash /etc/terminfo /etc/texmf/web2c /etc/udev/rules.d"
CXXFLAGS="-O3 -march=athlon-xp -funroll-loops -fprefetch-loop-arrays -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="distlocks fixpackages parallel-fetch protect-owned sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="ftp://ftp.tu-clausthal.de/pub/linux/gentoo/ http://linux.rz.ruhr-uni-bochum.de/download/gentoo-mirror/"
LC_ALL="de_DE@euro"
LDFLAGS="-Wl,-O1"
LINGUAS="de"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="3dnow X aac acl acpi alsa apache2 arts audiofile avahi bash-completion berkdb bindist bluetooth bootsplash branding bzip2 cairo cddb cdparanoia cdr cli cpdflib cracklib crypt cups dba dbus dri dv dvd dvdread eds emboss encode esd ethereal evo exif fam fbcon festival ffmpeg firefox flac foomaticdb fortran gd gdbm gif gkrellm glitz gnokii gphoto2 gpm gtk hal hardenedphp iconv icq imagemagick imap ipv6 isdnlog java jbig jpeg jpeg2k kde kdeenablefinal libnotify lm_sensors mad maildir mbrola mhash midi mikmod mime mmx mng mozdevelop mozilla mp3 mpeg mpi mplayer mudflap mysql ncurses nls nptl nptlonly nvidia ogg opengl openmp openssh pam pcre pdf pear-db perl php plotutils png ppds pppd python qt3 qt3support qt4 quicktime readline reflection scanner sdl session sms sndfile snmp speex spell spl sse ssl startup-notification svg svga sysfs tcpd theora tidy tiff truetype unicode usb vhosts vim-with-x vorbis webdav win32codecs wmf wxwindows x86 xcb xcomposite xine xml xorg xpm xscreensaver xulrunner xv xvid zlib" ALSA_CARDS="via82xx" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic auth_digest authn_anon authn_dbd authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock dbd deflate dir disk_cache env expires ext_filter file_cache filter headers ident imagemap include info log_config logio mem_cache mime mime_magic negotiation proxy proxy_ajp proxy_balancer proxy_connect proxy_http rewrite setenvif so speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="keyboard kbd mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="de" USERLAND="GNU" VIDEO_CARDS="nv nvidia vesa fbdev"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LANG, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Rémi Cardona (RETIRED) gentoo-dev 2009-04-19 08:51:58 UTC
Sorry, but I'll go with option #4 : it's just a warning. I've kept the default unchanged because the core fonts we provide are installed in those directories. A user with a simple xorg.conf will have working core fonts without changing anything.

If time allows, I'll try to cook up a patch that doesn't display the warning at all if the FontPath option was not set in xorg.conf

Thanks
Comment 2 Rüpel 2009-04-19 19:24:24 UTC
(In reply to comment #1)
> I've kept the default
> unchanged because the core fonts we provide are installed in those directories.

Uh? What core fonts? I (for example) don't have the OTF directory. What am I missing?

> A user with a simple xorg.conf will have working core fonts without changing
> anything.

Yeah, I was thinking about that. There's a reason for the defaults to be there. Maybe I have a proposal #5: A local use flag for the xorg-server ebuild. "cleanfontpath" or something like that? it's disabled by default. Jon Doe doesn't have to fear to get his fonts broken. Nitpickers like me enable the flag and have a sexy clean Xorg.0.log to print out and hang on the wall. ;)

Isn't Gentoo about choice?
 
> If time allows, I'll try to cook up a patch that doesn't display the warning at
> all if the FontPath option was not set in xorg.conf

Hmm. That's a weird "solution". I wouldn't go ahead and hide warnings. I'm pretty sure that this would break some stuff seriously. (like users complaining about missing fonts, having a clean Xorg.0.log and no possibility to debug anymore). Don't mess with upstream code if you don't have to. You're opening Pandora's box.
Comment 3 Rémi Cardona (RETIRED) gentoo-dev 2009-04-19 20:08:50 UTC
I think you're confused about how fonts work in X.

Back in the good old days, only the X server would know how to read and display fonts. Applications would send requests to the server with strings of text to render, and the server would happily render them. This is what I call "core X fonts". This method, while still available, is clearly _deprecated_.

Nowadays, applications and toolkits use media-libs/fontconfig to know about font options and to get lists of available fonts. Then the toolkit uses libXft, pango, Qt or other font renders to directly send pixels for the server to render. The server barely knows it's rendering fonts.

Fonts are much much more complicated than you seem to think.

(In reply to comment #2)
> Uh? What core fonts? I (for example) don't have the OTF directory. What am I
> missing?

Basically, if you don't use old apps (xterm, ...) or old toolkits (motif, tk, xaw, ...) you will never use core fonts.

> Maybe I have a proposal #5: A local use flag for the xorg-server ebuild.
> "cleanfontpath" or something like that? it's disabled by default. Jon Doe
> doesn't have to fear to get his fonts broken. Nitpickers like me enable the
> flag and have a sexy clean Xorg.0.log to print out and hang on the wall. ;)

xorg-server already has 30+ USE flags, and having to rebuild the server just to get a different default FontPath is just a pure waste of time. I won't do it.

> Isn't Gentoo about choice?

Not for old and deprecated stuff. The goal here is to allow old apps to work by default without any additional work.

> Hmm. That's a weird "solution". I wouldn't go ahead and hide warnings. I'm
> pretty sure that this would break some stuff seriously. (like users complaining
> about missing fonts, having a clean Xorg.0.log and no possibility to debug
> anymore). Don't mess with upstream code if you don't have to. You're opening
> Pandora's box.

I think I can figure out on my own what is dangerous and what isn't.

In the end, it's just a warning, just ignore it. If I ever get bothered enough, I'll come up with a proper fix but I doubt I ever will.

In the meantime, closing.

Thanks
Comment 4 Rémi Cardona (RETIRED) gentoo-dev 2009-08-20 11:52:47 UTC
bugzie
Comment 5 Rémi Cardona (RETIRED) gentoo-dev 2009-08-20 11:53:34 UTC
And closing with the proper resolution. Really, the log file is clear enough and it's just a warning.

Thanks
Comment 6 Erik 2010-12-01 10:08:00 UTC
While testing xorg-server-1.8* i found that xorg complains that some paths, that are none of its business, are missing and adds duplicate fontpaths.

From manual of xorg.conf:

FontPath "path"
 sets the search path for fonts. This path is a comma separated list of font path elements which the Xorg server searches for font databases. Multiple FontPath entries may be specified, and they will be concatenated to build up the fontpath used by the server. Font path elements can be absolute directory paths, catalogue directories or a font server identifier. The formats of the later two are explained below:
[...]
When this entry is not specified in the config file, the server falls back to the compiled-in default font path, which contains the following font path elements (which can be set inside a catalogue directory):

 
/usr/share/fonts/X11/misc/
/usr/share/fonts/X11/TTF/
/usr/share/fonts/X11/OTF/
/usr/share/fonts/X11/Type1/
/usr/share/fonts/X11/100dpi/
/usr/share/fonts/X11/75dpi/


And here is the whole /etc/X11/xorg.conf:
Section "Files"
        FontPath        "/usr/share/fonts/misc/"
        FontPath        "/usr/share/fonts/Type1/"
        FontPath        "/usr/share/fonts/100dpi/"
        FontPath        "/usr/share/fonts/75dpi/"
EndSection

Section "Device"
        Identifier  "nouveau"
        Driver      "nouveau"
EndSection

Section "Monitor"
        Identifier  "Monitor"
        DisplaySize 368 230
EndSection

Section "Screen"
        Identifier  "Screen"
        Monitor     "Monitor"
EndSection

Section "InputClass"
        Identifier      "Keyboard"
        MatchIsKeyboard "yes"
        Driver          "evdev"
        Option          "XkbLayout" se"
EndSection


_And here is the result in /var/log/Xorg.0.log:_
[  2523.276] (WW) The directory "/usr/share/fonts/TTF/" does not exist.
[  2523.276]    Entry deleted from font path.
[  2523.276] (WW) The directory "/usr/share/fonts/OTF/" does not exist.
[  2523.276]    Entry deleted from font path.
[  2523.276] (**) FontPath set to:
        /usr/share/fonts/misc/,
        /usr/share/fonts/Type1/,
        /usr/share/fonts/100dpi/,
        /usr/share/fonts/75dpi/,
        /usr/share/fonts/misc/,
        /usr/share/fonts/Type1/,
        /usr/share/fonts/100dpi/,
        /usr/share/fonts/75dpi/



It certainly looks like xorg tries to use the compiled-in default even though the paths were explicitly specified, which it should not do. Not only does it complain about the paths that it should not even look for, it even adds duplicate entries to FontPath.