Hi Sajjadul,
apparentlly to me the problem is that you were trying to build the plugin
osgdb_svg. And osgdb_svg depends on librsvg, which should have been found
(otherwise CMake wouldn't have added the target osgdb_svg). But librsvg
depends on Cairo, which was somehow not correctly found.

Do you really need the svg plugin? If not, an easy way is not to build
osgdb_svg... Otherwise you probably have to take a look on your Cairo
library.

Best,
Tianlan Shao


On Sat, Apr 19, 2014 at 10:37 PM, Sajjadul Islam <[email protected]>wrote:

> Hi forum,
>
> I am trying to compile the recent stable version from source on ubuntu
> 12.04 and i am having the following compilation error:
>
>
> Code:
>
> [ 85%] Built target osgdb_qfont
> [ 86%] Built target osgdb_zip
> [ 86%] Building CXX object
> src/osgPlugins/svg/CMakeFiles/osgdb_svg.dir/ReaderWriterSVG.o
> /home/sajjad/Downloads/OpenSceneGraph/OpenSceneGraphStable/OpenSceneGraph-3.2.1-rc2/src/osgPlugins/svg/ReaderWriterSVG.cpp:
> In member function ‘osg::Image* ReaderWriterSVG::createImage(RsvgHandle*,
> unsigned int, unsigned int) const’:
> /home/sajjad/Downloads/OpenSceneGraph/OpenSceneGraphStable/OpenSceneGraph-3.2.1-rc2/src/osgPlugins/svg/ReaderWriterSVG.cpp:96:17:
> error: ‘cairo_surface_t’ was not declared in this scope
> /home/sajjad/Downloads/OpenSceneGraph/OpenSceneGraphStable/OpenSceneGraph-3.2.1-rc2/src/osgPlugins/svg/ReaderWriterSVG.cpp:96:34:
> error: ‘cairo_surface’ was not declared in this scope
> /home/sajjad/Downloads/OpenSceneGraph/OpenSceneGraphStable/OpenSceneGraph-3.2.1-rc2/src/osgPlugins/svg/ReaderWriterSVG.cpp:97:41:
> error: ‘CAIRO_FORMAT_ARGB32’ was not declared in this scope
> /home/sajjad/Downloads/OpenSceneGraph/OpenSceneGraphStable/OpenSceneGraph-3.2.1-rc2/src/osgPlugins/svg/ReaderWriterSVG.cpp:97:103:
> error: ‘cairo_image_surface_create_for_data’ was not declared in this scope
> /home/sajjad/Downloads/OpenSceneGraph/OpenSceneGraphStable/OpenSceneGraph-3.2.1-rc2/src/osgPlugins/svg/ReaderWriterSVG.cpp:98:17:
> error: ‘cairo_t’ was not declared in this scope
> /home/sajjad/Downloads/OpenSceneGraph/OpenSceneGraphStable/OpenSceneGraph-3.2.1-rc2/src/osgPlugins/svg/ReaderWriterSVG.cpp:98:26:
> error: ‘cr’ was not declared in this scope
> /home/sajjad/Downloads/OpenSceneGraph/OpenSceneGraphStable/OpenSceneGraph-3.2.1-rc2/src/osgPlugins/svg/ReaderWriterSVG.cpp:98:57:
> error: ‘cairo_create’ was not declared in this scope
> /home/sajjad/Downloads/OpenSceneGraph/OpenSceneGraphStable/OpenSceneGraph-3.2.1-rc2/src/osgPlugins/svg/ReaderWriterSVG.cpp:99:104:
> error: ‘cairo_scale’ was not declared in this scope
> /home/sajjad/Downloads/OpenSceneGraph/OpenSceneGraphStable/OpenSceneGraph-3.2.1-rc2/src/osgPlugins/svg/ReaderWriterSVG.cpp:100:52:
> error: ‘rsvg_handle_render_cairo’ was not declared in this scope
> /home/sajjad/Downloads/OpenSceneGraph/OpenSceneGraphStable/OpenSceneGraph-3.2.1-rc2/src/osgPlugins/svg/ReaderWriterSVG.cpp:102:33:
> error: ‘cairo_destroy’ was not declared in this scope
> /home/sajjad/Downloads/OpenSceneGraph/OpenSceneGraphStable/OpenSceneGraph-3.2.1-rc2/src/osgPlugins/svg/ReaderWriterSVG.cpp:103:52:
> error: ‘cairo_surface_destroy’ was not declared in this scope
> make[2]: ***
> [src/osgPlugins/svg/CMakeFiles/osgdb_svg.dir/ReaderWriterSVG.o] Error 1
> make[1]: *** [src/osgPlugins/svg/CMakeFiles/osgdb_svg.dir/all] Error 2
> make: *** [all] Error 2
>
>
>
>
>
> Any hint to get rid of this?
>
>
> Thank you!
>
> Cheers,
> Sajjadul
>
> ------------------
> Read this topic online here:
> http://forum.openscenegraph.org/viewtopic.php?p=59072#59072
>
>
>
>
>
> _______________________________________________
> osg-users mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to