[cairo] Breaking the dependency on libX11
behdad at behdad.org
Mon Aug 11 08:57:42 PDT 2008
-----BEGIN PGP SIGNED MESSAGE-----
Bernie Innocenti wrote:
> OS distributors tend to compiler cairo with all backends enabled,
> which means that libcairo drags in libX11.
Yes, unfortunately this is the case we build cairo as a single .so.
> Some non-GUI tools such as rrdtool are starting to link with libcairo
> to render into PNGs and the like. This creates a nasty dependency
> chain for headless web servers that drags in a bunch of X11 client
> libraries, libxcb, and more.
> Would this be solvable by dlopen()ing libX11 at run time, only when an
> X11 surface is needed?
> Alternatively, would you recommend to ship a second copy of Cairo built
> with --disable-xlib and install it as libcairo-minimal or something
> like that?
That's one option. And distros can do that today. I know Debian has
installs a version of cairo only with the directfb backend enabled. In
the longer term, we may want to make cairo generate finergrained .so's.
That comes at a cost though, but I'll take a look into it.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org
-----END PGP SIGNATURE-----
More information about the cairo