Summary: | cairo-xlib.h from cairo-0.3.0 lacks C++ handling | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Ewgenij Starostin <estar> |
Component: | [OLD] Library | Assignee: | Peter Johanson (RETIRED) <latexer> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | castan.o |
Priority: | High | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: |
Test programme.
Patch for cairo-xlib.h. cairo-xlib.h patch Diff to the current 0.3.0-r1 cairo ebuild |
Description
Ewgenij Starostin
2005-03-31 07:18:58 UTC
Created attachment 54931 [details]
Test programme.
Compile with -lcairo -I/usr/include/cairo.
Created attachment 54932 [details, diff]
Patch for cairo-xlib.h.
The problem has already been addressed in a similar way in cairo's CVS.
Although I agree that this header definitely doesn't have the necessary foo to handle C++ stuff, Checking out the latest cairo CVS (http://cvs.cairographics.org/cairo/src/cairo-xlib.h) doesn't seem to have the fix you refer to. As to mozilla-firefox, can you please post details of the failures you're having with it? (I'm not the orginal submitter but I had the problem on various archs both x86 and ppc) Please look at http://cvs.cairographics.org/cairo/src/cairo-xlib.h?r1=1.6&r2=1.7 CAIRO_BEGIN_DECLS CAIRO_END_DECLS have been added and are defined in cairo.h as : #ifdef __cplusplus # define CAIRO_BEGIN_DECLS extern "C" { # define CAIRO_END_DECLS } #else # define CAIRO_BEGIN_DECLS # define CAIRO_END_DECLS #endif To highlight the problem : $ ldd -r /usr/lib/MozillaFirefox/components/libgklayout.so [...] undefined symbol: _Z25cairo_set_target_drawableP6_cairoP9_XDisplaym (/usr/lib/MozillaFirefox/components/libgklayout.so) $ readelf -s /usr/lib/libcairo.so.1.0.0 | grep drawable 194: 000224e4 200 FUNC GLOBAL DEFAULT 9 cairo_set_target_drawable libcairo.so.1.0.0 functions names are standard C, but are C++ mangled in /usr/lib/MozillaFirefox/components/libgklayout.so Because firefox was segfaulting in some configurations and if though it was related to hardened toolchain, I've put some more details in bug #83511 I was referring to the code posted by Olivier. The Firefox problem is identical with his; for a description, see bug #86785 (in particular http://bugs.gentoo.org/show_bug.cgi?id=86785#c8). Created attachment 55723 [details, diff]
cairo-xlib.h patch
Same patch to the header, just reformated slightly to be nicer to apply in the
ebuild.
Created attachment 55724 [details, diff]
Diff to the current 0.3.0-r1 cairo ebuild
Here's a diff to the current 0.3.0-r1 ebuild to make it apply the cairo-xlib.h
patch. Apply this diff, and drop the cairo-xlib.h patch into the files/ dir,
and install it. Please report back if this fixes your mozilla-firefox problems.
If so, i'll get this commited as 0.3.0-r2 for people. Thanks.
Applied, dropped, installed, fixed. Thank you. Ok, i've just commited this as 0.3.0-r2. Thanks for the bug report. Marking FIXED. |