[Fontconfig] Gtk+/Fontconfig/Pango.....Config error?

byakimovich at sympatico.ca byakimovich at sympatico.ca
Sat Mar 12 02:57:46 EST 2005

Hi (somebody? anybody?),

I've been working on a gtk+/glade/python based app for some time, and I seem to 
have run into a bit of a quagmire with regards to running a source-built 
gtk+2.4.0. My goal is to package gtk+/pango/glade/Python and all dependent 
libraries with my app, so that it can run on any machine, regardless of whether 
the proper dependencies are available on that machine.  The key player in all 
these libraries is gtk+2.4.0, so all my dependencies are based on that 

Here's the situation:

When I run my app ( which includes the gtk+ and dependent libs ), I get this 

No fonts found; this probably means that the fontconfig
library is not correctly configured. You may need to
edit the fonts.conf configuration file. More information
about fontconfig can be found in the fontconfig(3) manual
page and on http://fontconfig.org

I look throughout the web, and found that many people experienced this error, 
but found no definitive answer on how to fix it.  After some fiddling around, I 
added the following to my startup script:

export FONTCONFIG_PATH=/usr/lib/my_app/etc/fonts

and the error did not occur anymore.  However, I ran into this wall next.

**: Cannot open font file for font Bitstream Vera Sans 10 ( and then there's a 
Segmentation fault ).

If I move the Bitstream line in fonts.conf ( around ln 318 ), I get the error 
on the next font in the list ( in this case, Verdana ).
                        <family>Bitstream Vera Sans</family>

A good deal of my fonts are in here:

...so I copied them into my app here -> "myapp/share/fonts/truetype".  This is 
directories at the top of my "myapp/etc/fonts/(local.conf/fonts.conf) ( I've 
tried both...)

I've even tried adding /usr/lib/myapp/share/fonts/truetype to FONTCONFIG_PATH 
with no help there.

I've tweaked things around for a few days with no progress.  There have been 
numerous other postings for this on the web, but again, I didn't come across 
any fixes.  From what I read, it looks like a Pango issue, having to do with 
Xft and Fontconfig.  I tried the USE_XFT=0 fix and there was no change.

Any ideas?  Would a later version of Pango have fixed this?  I tried using 
Fontconfig 2.3.0, and I get the same error.

Any help would be greatly appreciated.
- Blair

Here's what I'm building ( in approx order of building ):

I built all these using --prefix=/home/me/my_app on a debian based machine 
using XFree86 4.2.1 with some 4.3 upgrades.


Ok, so this all builds fine.  I took extra care to ensure that the 
freetype/fontconfig/xft2 versions were the packaged versions, and not the ones 
used in XFree86 ( my XFree86 had fontconfig headers, but no libraries, etc. ) 
Any ideas?

More information about the Fontconfig mailing list