Opened 16 years ago
Closed 16 years ago
#419 closed defect (fixed)
cairo compilation error
Reported by: | neteler | Owned by: | martinl |
---|---|---|---|
Priority: | major | Milestone: | 7.0.0 |
Component: | Default | Version: | svn-trunk |
Keywords: | Cc: | grass-dev@… | |
CPU: | x86-32 | Platform: | Linux |
Description
Trying to compile GRASS trunk on grass.osgeo.org (FC4 with cairo 1.4.4), I get
make[1]: Leaving directory `/home/neteler/grass7_svn_head_bin_snapshot/trunk/lib/cairodriver' gcc -I/home/neteler/grass7_svn_head_bin_snapshot/trunk/dist.i686-pc-linux-gnu/include -I/home/neteler/binaries/include -g -Wall -Werror-implicit-function-declaration -fno-common -I/home/neteler/binaries/include -fPIC -I../driver -I/usr/include/cairo -DUSE_X11=1 -DPACKAGE=\""grasslibs"\" -I/home/neteler/grass7_svn_head_bin_snapshot/trunk/dist.i686-pc-linux-gnu/include -o OBJ.i686-pc-linux-gnu/Draw_bitmap.o -c Draw_bitmap.c Draw_bitmap.c: In function 'Cairo_Bitmap': Draw_bitmap.c:36: error: implicit declaration of function 'cairo_format_stride_for_width'
What's the minimum version of cairo needed here?
Please update REQUIREMENTS.html:
grep -i cairo REQUIREMENTS.html <li><B>Cairo</B> (Cairo graphics library, Version >= XX)<BR>
Markus
Change History (10)
follow-ups: 2 3 comment:1 by , 16 years ago
comment:2 by , 16 years ago
follow-up: 4 comment:3 by , 16 years ago
Replying to glynn:
Replying to neteler:
Trying to compile GRASS trunk on grass.osgeo.org (FC4 with cairo 1.4.4), I get
Draw_bitmap.c:36: error: implicit declaration of function 'cairo_format_stride_for_width'
What's the minimum version of cairo needed here?
That function needs 1.6.
Looks like 1.5.8 would be enough: http://cairographics.org/news/cairo-1.5.8/
I have the same problem with
cairo_xlib_surface_get_xrender_format
Moritz
Please update REQUIREMENTS.html:
I'd rather work around the requirement.
follow-ups: 5 9 comment:4 by , 16 years ago
Replying to mlennert:
What's the minimum version of cairo needed here?
Looks like 1.5.8 would be enough:
I'll update the test accordingly.
I have the same problem with
cairo_xlib_surface_get_xrender_format
That should be conditionalised upon CAIRO_HAS_XLIB_XRENDER_SURFACE. The function should be defined in cairo-xlib-xrender.h.
Can you provide more details?
follow-up: 6 comment:5 by , 16 years ago
Replying to glynn:
Replying to mlennert:
What's the minimum version of cairo needed here?
Looks like 1.5.8 would be enough:
I'll update the test accordingly.
I have the same problem with
cairo_xlib_surface_get_xrender_format
That should be conditionalised upon CAIRO_HAS_XLIB_XRENDER_SURFACE. The function should be defined in cairo-xlib-xrender.h.
Can you provide more details?
svn update and recompile now gives only one error:
mlennert@geog-pc40:~/SRC/GRASS/grass_trunk/general/g.cairocomp$ export LANG=C; make gcc -L/home/mlennert/SRC/GRASS/grass_trunk/dist.i486-pc-linux-gnu/lib -Wl,--export-dynamic -Wl,-rpath-link,/home/mlennert/SRC/GRASS/grass_trunk/dist.i486-pc-linux-gnu/lib -o /home/mlennert/SRC/GRASS/grass_trunk/dist.i486-pc-linux-gnu/bin/g.cairocomp OBJ.i486-pc-linux-gnu/main.o -lgrass_gis -lgrass_datetime -lz -lXrender -lcairo -lX11 -lm -lz OBJ.i486-pc-linux-gnu/main.o: In function `init_xlib': /home/mlennert/SRC/GRASS/grass_trunk/general/g.cairocomp/main.c:118: undefined reference to `cairo_xlib_surface_get_xrender_format' collect2: ld returned 1 exit status make: *** [/home/mlennert/SRC/GRASS/grass_trunk/dist.i486-pc-linux-gnu/bin/g.cairocomp] Error 1
Using cairo 1.4.14 on Debian stable.
Moritz
follow-up: 7 comment:6 by , 16 years ago
Replying to mlennert:
svn update and recompile now gives only one error:
/home/mlennert/SRC/GRASS/grass_trunk/general/g.cairocomp/main.c:118: undefined reference to `cairo_xlib_surface_get_xrender_format' make: *** [/home/mlennert/SRC/GRASS/grass_trunk/dist.i486-pc-linux-gnu/bin/g.cairocomp] Error 1
Using cairo 1.4.14 on Debian stable.
Right; I can only fix this in the sense of adding a configure check for cairo_xlib_surface_get_xrender_format() and not building g.cairocomp if it's missing. g.cairocomp can't work without that function, but the cairo driver can.
follow-up: 8 comment:7 by , 16 years ago
Replying to glynn:
Replying to mlennert:
svn update and recompile now gives only one error:
/home/mlennert/SRC/GRASS/grass_trunk/general/g.cairocomp/main.c:118: undefined reference to `cairo_xlib_surface_get_xrender_format' make: *** [/home/mlennert/SRC/GRASS/grass_trunk/dist.i486-pc-linux-gnu/bin/g.cairocomp] Error 1Using cairo 1.4.14 on Debian stable.
Right; I can only fix this in the sense of adding a configure check for cairo_xlib_surface_get_xrender_format() and not building g.cairocomp if it's missing. g.cairocomp can't work without that function, but the cairo driver can.
And do I understand correctly that g.cairocomp is need to use the GUI, at least when using the default cairo driver ?
I guess it's time to compile a more recent version of cairo, then...
Moritz
comment:8 by , 16 years ago
Replying to mlennert:
And do I understand correctly that g.cairocomp is need to use the GUI, at least when using the default cairo driver ?
No. At present, g.cairocomp isn't used.
Using the cairo driver to generate X pixmaps which can be composited by g.cairocomp offers a faster alternative to using PNM files, but it requires X, the XRender extension, and a recent version of cairo built with X and XRender support. Even if/when the GUI does use g.cairocomp, the use of PNM files will still need to be retained as a fallback.
comment:9 by , 16 years ago
Cc: | added |
---|---|
Owner: | changed from | to
Status: | new → assigned |
comment:10 by , 16 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Great, finally it causes no more errors on FC4 with cairo 1.4.4. Hence I can activate a GRASS 7 Linux binaries weekly cronjob.
Markus
Replying to neteler:
That function needs 1.6.
I'd rather work around the requirement.