Skip Menu |

This queue is for tickets about the Cairo CPAN distribution.

Report information
The Basics
Id: 62603
Status: resolved
Priority: 0/
Queue: Cairo

Owner: Nobody in particular
Requestors: garu [...]

Bug Information
Severity: Important
Broken in: 1.061
Fixed in: (no value)

Subject: failing tests in t/CairoSurface.t
Download (untitled) / with headers
text/plain 11.2k
Hi there, Thanks for such a great module! I'm having some trouble installing it in kubuntu 10.10, though. My problem appears to be just like the one in: This is my perl version and architecture: garu@bebop:~$ perl -v This is perl, v5.10.1 (*) built for x86_64-linux-gnu-thread-multi (with 40 registered patches, see perl -V for more detail) I saw one of the resolved bugs also had the 'no-memory' problem, but even after running "fc-cache" I got the same results. I did, however, try the code you provided back then: garu@bebop:~$ cat cairo-test.c #include <cairo/cairo.h> /* gcc `pkg-config --cflags --libs cairo` cairo-test.c -o cairo-test */ int main (int argc, char **argv) { cairo_t *cr; cairo_surface_t *surface; surface = cairo_image_surface_create (CAIRO_FORMAT_ARGB32, 256, 256); cr = cairo_create (surface); cairo_set_source_rgb (cr, 1.0, 1.0, 1.0); cairo_move_to (cr, 0, 0); cairo_line_to (cr, 256, 256); cairo_stroke (cr); cairo_surface_write_to_png (surface, "cairo-test.png"); cairo_destroy (cr); cairo_surface_destroy (surface); } garu@bebop:~$ gcc `pkg-config --cflags --libs cairo` cairo-test.c -o cairo-test garu@bebop:~$ ldd cairo-test => (0x00007fff0c9f0000) => /usr/lib/ (0x00007f9548c0e000) => /lib/ (0x00007f95489f1000) => /lib/ (0x00007f954866d000) => /usr/lib/ (0x00007f954840e000) => /usr/lib/ (0x00007f95481d9000) => /usr/lib/ (0x00007f9547f51000) => /lib/ (0x00007f9547d2a000) => /usr/lib/ (0x00007f9547b27000) => /usr/lib/ (0x00007f954791d000) => /usr/lib/ (0x00007f9547700000) => /usr/lib/ (0x00007f95474f6000) => /usr/lib/ (0x00007f95471bf000) => /lib/ (0x00007f9546fa7000) => /lib/ (0x00007f9546d24000) /lib64/ (0x00007f9548eeb000) => /lib/ (0x00007f9546afa000) => /usr/lib/ (0x00007f95468f7000) => /usr/lib/ (0x00007f95466f1000) => /lib/ (0x00007f95464ec000) And yes, running the program gives me a transparent png file with a diagonal line. Below is the installation output with failing tests. Any advice on how to fix these would be *greatly* appreciated. Thanks! garu@bebop: cpanm Cairo cpanm (App::cpanminus) 1.0015 on perl 5.010001 built for x86_64-linux-gnu-thread-multi Work directory is /home/garu/.cpanm/work/1288583406.15489 You have make /usr/bin/make You have LWP 5.837 You have /bin/tar: tar (GNU tar) 1.23 Copyright (C) 2010 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <>. This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Written by John Gilmore and Jay Fenlason. You have /usr/bin/unzip Searching Cairo on cpanmetadb ... Checking if you have ExtUtils::MakeMaker 6.31 ... Yes (6.56) Checking if you have ExtUtils::Install 1.46 ... Yes (1.54) Checking if you have Module::Build 0.28 ... Yes (0.3607) --> Working on Cairo Fetching -> OK Unpacking Cairo-1.061.tar.gz Entering Cairo-1.061 Checking if you have ExtUtils::MakeMaker 0 ... Yes (6.56) Checking if you have ExtUtils::Depends 0.2 ... Yes (0.302) Checking if you have ExtUtils::PkgConfig 1 ... Yes (1.12) Configuring Cairo-1.061 Running Makefile.PL Compiling Cairo with FreeType support Checking if your kit is complete... Looks good Writing Makefile for Cairo -> OK Finding PREREQ from Makefile ... Checking if you have ExtUtils::Depends 0.2 ... Yes (0.302) Checking if you have ExtUtils::PkgConfig 1 ... Yes (1.12) Building and testing Cairo-1.061 cp lib/ blib/lib/ cp build/ blib/arch/Cairo/Install/ cp cairo-perl.typemap blib/arch/Cairo/Install/cairo-perl.typemap cp doctypes blib/arch/Cairo/Install/doctypes cp cairo-perl.h blib/arch/Cairo/Install/cairo-perl.h cp build/cairo-perl-auto.typemap blib/arch/Cairo/Install/cairo-perl-auto.typemap cp build/cairo-perl-auto.h blib/arch/Cairo/Install/cairo-perl-auto.h /usr/bin/perl /home/garu/perl5/lib/perl5/ExtUtils/xsubpp -noprototypes -typemap /usr/share/perl/5.10/ExtUtils/typemap -typemap build/cairo-perl-auto.typemap -typemap cairo-perl.typemap Cairo.xs > Cairo.xsc && mv Cairo.xsc Cairo.c cc -c -I. -Ibuild -pthread -I/usr/include/cairo -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -g -DVERSION=\"1.061\" -DXS_VERSION=\"1.061\" -fPIC "-I/usr/lib/perl/5.10/CORE" Cairo.c /usr/bin/perl /home/garu/perl5/lib/perl5/ExtUtils/xsubpp -noprototypes -typemap /usr/share/perl/5.10/ExtUtils/typemap -typemap build/cairo-perl-auto.typemap -typemap cairo-perl.typemap CairoFont.xs Show quoted text
> CairoFont.xsc && mv CairoFont.xsc CairoFont.c
cc -c -I. -Ibuild -pthread -I/usr/include/cairo -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -g -DVERSION=\"1.061\" -DXS_VERSION=\"1.061\" -fPIC "-I/usr/lib/perl/5.10/CORE" CairoFont.c /usr/bin/perl /home/garu/perl5/lib/perl5/ExtUtils/xsubpp -noprototypes -typemap /usr/share/perl/5.10/ExtUtils/typemap -typemap build/cairo-perl-auto.typemap -typemap cairo-perl.typemap CairoMatrix.xs > CairoMatrix.xsc && mv CairoMatrix.xsc CairoMatrix.c cc -c -I. -Ibuild -pthread -I/usr/include/cairo -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -g -DVERSION=\"1.061\" -DXS_VERSION=\"1.061\" -fPIC "-I/usr/lib/perl/5.10/CORE" CairoMatrix.c /usr/bin/perl /home/garu/perl5/lib/perl5/ExtUtils/xsubpp -noprototypes -typemap /usr/share/perl/5.10/ExtUtils/typemap -typemap build/cairo-perl-auto.typemap -typemap cairo-perl.typemap CairoPath.xs Show quoted text
> CairoPath.xsc && mv CairoPath.xsc CairoPath.c
cc -c -I. -Ibuild -pthread -I/usr/include/cairo -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -g -DVERSION=\"1.061\" -DXS_VERSION=\"1.061\" -fPIC "-I/usr/lib/perl/5.10/CORE" CairoPath.c /usr/bin/perl /home/garu/perl5/lib/perl5/ExtUtils/xsubpp -noprototypes -typemap /usr/share/perl/5.10/ExtUtils/typemap -typemap build/cairo-perl-auto.typemap -typemap cairo-perl.typemap CairoPattern.xs > CairoPattern.xsc && mv CairoPattern.xsc CairoPattern.c cc -c -I. -Ibuild -pthread -I/usr/include/cairo -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -g -DVERSION=\"1.061\" -DXS_VERSION=\"1.061\" -fPIC "-I/usr/lib/perl/5.10/CORE" CairoPattern.c /usr/bin/perl /home/garu/perl5/lib/perl5/ExtUtils/xsubpp -noprototypes -typemap /usr/share/perl/5.10/ExtUtils/typemap -typemap build/cairo-perl-auto.typemap -typemap cairo-perl.typemap CairoSurface.xs > CairoSurface.xsc && mv CairoSurface.xsc CairoSurface.c cc -c -I. -Ibuild -pthread -I/usr/include/cairo -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -g -DVERSION=\"1.061\" -DXS_VERSION=\"1.061\" -fPIC "-I/usr/lib/perl/5.10/CORE" CairoSurface.c /usr/bin/perl /home/garu/perl5/lib/perl5/ExtUtils/xsubpp -noprototypes -typemap /usr/share/perl/5.10/ExtUtils/typemap -typemap build/cairo-perl-auto.typemap -typemap cairo-perl.typemap CairoFt.xs > CairoFt.xsc && mv CairoFt.xsc CairoFt.c cc -c -I. -Ibuild -pthread -I/usr/include/cairo -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -g -DVERSION=\"1.061\" -DXS_VERSION=\"1.061\" -fPIC "-I/usr/lib/perl/5.10/CORE" CairoFt.c cc -c -I. -Ibuild -pthread -I/usr/include/cairo -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -g -DVERSION=\"1.061\" -DXS_VERSION=\"1.061\" -fPIC "-I/usr/lib/perl/5.10/CORE" cairo-perl-enums.c Running Mkbootstrap for Cairo () chmod 644 rm -f blib/arch/auto/Cairo/ LD_RUN_PATH="/usr/lib" cc -shared -O2 -g -L/usr/local/lib -fstack-protector Cairo.o CairoFont.o CairoMatrix.o CairoPath.o CairoPattern.o CairoSurface.o CairoFt.o cairo-perl-enums.o -o blib/arch/auto/Cairo/ \ -lcairo -lfreetype \ chmod 755 blib/arch/auto/Cairo/ cp blib/arch/auto/Cairo/ chmod 644 blib/arch/auto/Cairo/ Manifying blib/man3/Cairo.3pm PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t t/Cairo.t ......... ok t/CairoFont.t ..... ok t/CairoFt.t ....... skipped: need Cairo with FreeType support and Font::FreeType t/CairoMatrix.t ... ok t/CairoPath.t ..... ok t/CairoPattern.t .. ok # Failed test at t/CairoSurface.t line 82. # got: 'color' # expected: 'color-alpha' # Failed test at t/CairoSurface.t line 93. # Structures begin differing at: # $got->[0] = '0' # $expected->[0] = '23' # Failed test at t/CairoSurface.t line 100. # got: 'no-memory' # expected: 'success' unknown surface type 16 encountered at t/CairoSurface.t line 197. # Looks like you failed 3 tests of 72. t/CairoSurface.t .. Dubious, test returned 3 (wstat 768, 0x300) Failed 3/72 subtests Test Summary Report ------------------- t/CairoSurface.t (Wstat: 768 Tests: 72 Failed: 3) Failed tests: 15, 17, 19 Non-zero exit status: 3 Files=7, Tests=204, 1 wallclock secs ( 0.06 usr 0.02 sys + 0.22 cusr 0.03 csys = 0.33 CPU) Result: FAIL Failed 1/7 test programs. 3/204 subtests failed. make: *** [test_dynamic] Error 3
Download (untitled) / with headers
text/plain 789b
This might give some hints on the matter: I found it strange that the latest CPAN version is 1.061 and Ubuntu has libcairo-perl referring to version 1.070-1. Looking into it, I found the following record on ubuntu's package changelog: libcairo-perl (1.070-1ubuntu1) maverick; urgency=low * Temporarily deactivate failing tests in the testsuite: newer cairo causing test failures that will not be addressed by Maverick release (according to slomo the test suite needs to be updated). Thanks to Didier Roche for investigating the issue. (LP: #187823) -- Emmet Hikory <> Thu, 23 Sep 2010 18:37:35 +0900 The full changelog can be seen here:
Download (untitled) / with headers
text/plain 159b
I have the exact same test failures. I am using ArchLinux. I am packaging this module and for now I am skipping the tests... which I don't normally like to do.
Download (untitled) / with headers
text/plain 214b
I've produced this behavior on Arch Linux as well, with Cairo-1.061. The tests fail when building against cairo 1.10, but if I revert the package version to cairo 1.08, Cairo-1.061 passes all tests successfully.
Download (untitled) / with headers
text/plain 344b
On investigating this bug for Debian <> I discovered that upstream now appears to be <> and their bugtracker has another report of this issue at <>. This explains why 1.070 is in Debian/Ubuntu but not CPAN.
This issue has been fixed in Cairo 1.062. Sorry for the late response.
Download (untitled) / with headers
text/plain 263b
On Sat May 14 07:02:49 2011, TSCH wrote: Show quoted text
> This issue has been fixed in Cairo 1.062. Sorry for the late response.
I can confirm it installs perfectly now. Thank you very much for such a nice module and for taking the time to update it. I really appreciate it =)

This service is sponsored and maintained by Best Practical Solutions and runs on infrastructure.

Please report any issues with to