[cairo] [PATCH] Pull -lz for the script backend

Olivier Blin olivier.blin at softathome.com
Fri Aug 12 09:04:08 UTC 2016


Le 11/08/2016 à 18:49, Enrico Weigelt, metux IT consult a écrit :
> On 11.08.2016 14:30, Olivier Blin wrote:
>
> Hi,
>
> > Can this old patch be merged?
> > This is a simple build fix for the script backend on some platforms.
>
> Whats the actual problem behind that ?
> Which kind of break actually occours ?

Hi,

It fails to link:
   CCLD     cairo-test-suite
cairo/build/src/.libs/libcairo.so: error: undefined reference to 'deflate'
cairo/build/src/.libs/libcairo.so: error: undefined reference to 
'deflateEnd'
cairo/build/src/.libs/libcairo.so: error: undefined reference to 
'deflateInit_'

> >> diff --git a/configure.ac b/configure.ac
> >> index 2ce1959..d90cf10 100644
> >> --- a/configure.ac
> >> +++ b/configure.ac
> >> @@ -470,6 +470,9 @@ dnl
> >> ===========================================================================
> >>
> >>   any2ppm_cs=no
> >>   CAIRO_ENABLE_SURFACE_BACKEND(script, script, yes, [
> >>     any2ppm_cs=yes
> >> +  # The script backend requires zlib.
> >> +  use_script=$have_libz
>        ^^^^^^^
>
> Looks like this would silently disable the script backend if libz
> is missing. IMHO, a very bad idea - instead it should break with a
> proper error message.
This is actually copy/paste of what is already properly done for the 
PostScript and PDF backends.

CAIRO_ENABLE_SURFACE_BACKEND(pdf, PDF, yes, [
     # The pdf backend requires zlib.
     use_pdf=$have_libz
     pdf_NONPKGCONFIG_LIBS=-lz
])

Thanks

-- 
Olivier Blin - SoftAtHome



More information about the cairo mailing list