Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I tried to compile Firefox 24 on RHEL 5.9 and ran into dependency hell.

I have no root privileges and I compiled several of the dependencies (glib, cairo and whatnot) in one of my directories. I failed on compiling pango (1.20.5) with this error I could not manage to resolve: /work/usr/lib/libcairo.so: undefined reference to `XRenderFindVisualFormat'.

Now my question is: is it possible to compile FF24 on RHEL 5.9 and if so, can you recommend a procedure how to go about systematically?


I tried the gentoo prefix solution: After installing prefix with bootstrap-prefix.sh to /work/gentoo:

  • Added a line USE="-*" to $EPREFIX/etc/portage/make.conf
  • Added a line PYTHON_TARGETS="python2_7" to $EPREFIX/etc/portage/make.conf
  • nasm on host was too old (NASM version 0.98.39 compiled on Jul 12 2006), so building media-libs/libjpeg-turbo-1.3.1 failed. emerge nasm fixed it.
  • emerge --autounmask-write '<media-libs/mesa-10.2'
  • emerge --autounmask-write firefox

To start firefox, I use a script:

COMMAND="${PREFIX}/usr/lib/firefox/firefox $1"
env -i HOME=$HOME TERM=$TERM USER=$USER $PREFIX/bin/bash -l -c "export DISPLAY=:0.0 ; ${COMMAND}"

Unfortunately, I can't pass a file to that script so firefox opens the file automatically. Plus - and that's a more serious problem - scrolling with the mouse wheel is buggy and switching tabs by clicking on them does not work. So all the effort was in vain )o:

share|improve this question
What happens when you pass a file to Firefox? Also, I don't think resetting the environment is necessary -- in a normal shell (i.e. not prefix) just call the direct path to the firefox binary. –  Wilfred Hughes Jul 14 at 8:58

3 Answers 3

up vote 0 down vote accepted

It is possible to compile Firefox on RHEL 5 (I'm currently running Firefox 30 on RHEL 5) using Gentoo Prefix. It's a little work (Prefix's IRC channel is helpful) but using a proper package manager means all the dependencies are handled for you.

Bootstrap Prefix, then just install Firefox with:

$ ~/gentoo/startprefix # wherever your prefix shell script is
$ emerge -a firefox
$ export DISPLAY=:0.0 # Use the existing Xorg installed
$ firefox
share|improve this answer
I tried that but it fails with: emerge: there are no ebuilds to satisfy ">=sys-apps/dbus-1.6.18-r1[abi_x86_32(-)?,abi_x86_64(-)?,abi_x86_x32(-)?,abi_mip‌​s_n32(-)?,abi_mips_n64(-)?,abi_mips_o32(-)?,abi_ppc_32(-)?,abi_ppc_64(-)?,abi_s39‌​0_32(-)?,abi_s390_64(-)?]". –  Thomas M Jul 11 at 10:58
Try emerging an older version of dbus and building firefox against that. eix sys-apps/dbus shows the versions, then emerge -av =dbus-1.6.8-r1 (the version I have installed currently). Failing that, ask on IRC. –  Wilfred Hughes Jul 11 at 12:43
I tried USE="-dbus", then emerge -a firefox, then I got: emerge: there are no ebuilds to satisfy ">=sys-apps/util-linux-2.24.1-r3[abi_x86_32(-)?,abi_x86_64(-)?,abi_x86_x32(-)?,a‌​bi_mips_n32(-)?,abi_mips_n64(-)?,abi_mips_o32(-)?,abi_ppc_32(-)?,abi_ppc_64(-)?,a‌​bi_s390_32(-)?,abi_s390_64(-)?]". –  Thomas M Jul 11 at 13:00
did you also get this message during installing util-linux: "Your host glibc is too old; enabling -fgnu89-inline compiler flag. bug 473524"? –  Thomas M Jul 11 at 13:06
I'm using util-linux 2.17, I haven't been able to upgrade because of that error. The glibc warning is just a warning. –  Wilfred Hughes Jul 11 at 13:10
emerge --autounmask-write firefox

should be replaced by

emerge -p --autounmask-write firefox

Just after that step, in $EPREFIX/etc/portage/make.conf you should replace



USE="-keyword1 -keyword2 -keyword3 ... -keywordN"

where keyword1 keyword2 keyword3, ... keywordN should be replaced by the various USE flags showed by emerge -p --autounmask-write firefox. If emerge -p --autounmask-write firefox showed

[ebuild   R    ] app-text/recode-3.6_p17-r2  USE="nls (prefix%*) -static-libs" 2,021 kB

Then you could use

USE="-nls -static-libs"

This will give to you something with an effect exactly equivalent to USE="-*".

At next step, you should try to guess which of the elements in USE are the one preventing "scrolling with the mouse wheel is buggy and switching tabs by clicking on them". For example, if it is -nls, then you should replace -nls by +nls (or by nothing) in the USE variable.

You may lookup http://www.gentoo.org/dyn/use-index.xml to track mouse-related USE keywords.

After that, apply the steps below to compile a mouse-compatible firefox:

emerge --autounmask-write firefox
mv $EPREFIX/etc/portage/.*package.use $EPREFIX/etc/portage/package.use
emerge firefox

Note: I think that a USE variable shortened to only a handful of keywords is enough to build firefox. Please report that here and on IRC if you succeed to find it.

share|improve this answer

This assumes you have root access to install various RPMS, so I'm not sure how you get round that, but it is possible to build FF24 on EL5.

Have a look at this article.

share|improve this answer
This is a quote from the question: "...can you recommend a procedure how to go about systematically?" Simply saying "it's possible" isn't really helpful. –  Moses Oct 10 '13 at 19:27
The link posted by @james-p contains valuable information. I will definitely try what's suggested there. –  Thomas M Oct 14 '13 at 15:53

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.