[cairo] python-cario text on X86_64

Jody Winston josephwinston at mac.com
Sat Dec 4 14:48:07 PST 2004


Steve Chaplin writes:
 > On Sat, 2004-12-04 at 00:02 -0600, Jody Winston wrote:
 > > Using Python 2.3.3, gcc 3.3.3, and today's CVS versions on an opteron
 > > system, I'm seeing core dumps anytime text is used in any of the
 > > python examples.  This problem does not appear to happen with the
 > > demos found in cairo-demo.  The traceback shows where the problem
 > > occurs.  
 > > 
 > > What appears in gdb is that when face is set to
 > > font->val->face the value of ucs4 changes from 0 to some non zero
 > > value and the stack becomes corrupted throughout the traceback.  It is
 > > acting like a prototype is wrong someplace in the traceback.
 > > 
 > > I'd like to get text working on the opterons and I'm willing to debug
 > > this problem.  Any suggestions before I start?
 > > 
 > > Thanks,
 > > 
 > > Jody
 > Could you generate a minimal test case that works in C but fails in
 > Python, does not use GTK+ and Glib, and saves a png file. 
 > Maybe something like this
 > 1) verify that cairo_snippets/text.cairo works on your system
 > 2) Edit hering.py, strip out all the graphics commands and insert the
 > python equivalent to cairo_snippets/text.cairo, run it and see if it
 > gives you the same error. Then strip out as many lines as possible while
 > preserving the error.
 > 
 > Steve
 > 

While looking at your suggestions, I thought that I might try building
everything again since it appeared to be a problem with prototypes.  I
grabbed new snapshots, reread the wiki instructions, and built cairo
in the following order:

fontconfig
Xproto
XExtensions
xtrans
Xau
X11
Render  
Xrender
glitz
libpixman
xcb-proto
Xau
check
xcb
cairo
libsvg
libsvg-cairo
gtkcairo
python-cairo
cairo-demo

The python text examples are now working.  What has changed since the
first build is the following:
   o The first time I built cairo, I did not build fontconfig
     before the xlibs;
   o I noticed that my system did not have x11.pc, so I added the
     necessary libraries
   o I added CFLAGS="-g" to the configuration line.

However, I am still seeing problems with text rendered to png.  Here's
a sample of the problem from cario-demo/cairo_snippets/text.  Does
this also look like a problem with building cairo?

-------------- next part --------------
A non-text attachment was scrubbed...
Name: text.png
Type: image/png
Size: 10675 bytes
Desc: X86_64 text problem
Url : http://lists.freedesktop.org/archives/cairo/attachments/20041204/5a2dec37/text.png
-------------- next part --------------

Thanks,

Jody


More information about the cairo mailing list