Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

This is probably a noob question, but so far never needed to deviate from the standard Fedora 16 core development components. I am needing to build clutter-mx project, but this library requires glib-2.0.32. Along with this, glib-2 needs libffi-3.0.11.

I can download the source and build these libraries, however, I am concerned that installing them will break the rest of the system.

The clutter-mx project uses autotools and looks for the glib-2 version.

The questions are:

  1. If I build and install the new components, and something goes wrong, can you get back using yum, or something similar?

  2. Is there a way of getting autotools to look in another directory for the installed headers?


share|improve this question
add comment

2 Answers

up vote 1 down vote accepted

Sources looking for dependencies via auto-tools have a configure.ac file (and/or Makefile.am, I'm not sure on this one) in which those dependencies are defined. Most of the time people/IDEs will just put their currently installed versions of the libraries as dependency but don't actually need them in a that recent version.

You can try to modify the required verions to your versions and try to build the package.

You cannot directly make the autotools look in some alternate path but IIRC the autotools use pkg-config to determine package-installation specifics (man pkg-config). You can tell pkg-config to look in other directories by the evironmental variable PKG_CONFIG_PATH. However, the pkg-config path only works if you have the more recent libraries actually installed somewhere. But then I believe you can edit the *.pc files to force clutter-mx statically link those libraries.

If you install two versions of a library and sometimes use the one and sometimes the other you may run into problems. If you actually replace files that were put there by rpm your about screwed.

My advice is to modify the builddependencies or if need be determine why the more recent version of library XY is required and modify clutter-mx sources to not require that recent version and work with your current version. My second best advice is to get/build packages for your distribution of the requried libraries and install those. You really really shouldn't break out of the world set up by your distro, i.e. package manager. There are evil forces out there. :-)

share|improve this answer
Hi, thanks for the advice. We need to build the latest glib-2 as there are dependancies, but the PKG_CONFIG_PATH works well. –  user626201 Jun 18 '12 at 13:44
add comment

Don't try to install newer Gtk/Gnome libraries in a system directory. They have poor backward compatibility, and you risk breaking existing programs.

Compile and install new libraries in a separate directory hierarchy. Run ./configure --help to see how to specify paths to libraries and include files when you compile a library. For example, if you see

            C compiler flags for PANGO, overriding pkg-config
PANGO_LIBS  linker flags for PANGO, overriding pkg-config

then set the following environment variables:

export PANGO_CFLAGS='-I /path/to/my/gnome/stuff/include'
export PANGO_LIBS='-L /path/to/my/gnome/stuff/libs'

Pass --prefix=/path/to/my/gnome/stuff to ./configure, to get everything installed to your own directory.

Or, and this will be easier if you need to install a lot of libraries, rebuild everything including with pkg-config. Install pkg-config under /path/to/my/gnome/stuff as well, then set

export PKG_CONFIG=/path/to/my/gnome/stuff/bin/pkg-config
share|improve this answer
Hi, thanks for the advice. The PKG_CONFIG_PATH works well. –  user626201 Jun 18 '12 at 13:44
add comment

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.