Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Building Pango with Cairo support

I'm attempting to build a new version of wireshark 1.10 on a RHEL5 box with the intent of making an RPM so that customers that I support can install it. Possibly others if I can find a place to host it.

WS1.10 depends on GTK+ as well as several other libraries that aren't supported by the available rpm packages. Therefore, I have to build them by hand. GTK+ needs pango(1.24.5) with cairo(1.8.8) support.

After having built and installed a newer version of cairo from source, a ./configure of pango gives the following error

checking for CAIRO... yes
checking which cairo font backends could be used... none
configure: Disabling cairo support

and then at the end ./configure displays

configuration:
        backends: X

I can verify that Cairo is installed by looking at the pkg_config in my /usr/local/lib.
I've even taken a look at the pango config.log. But I don't see anything that is any different then the messages I copypasta'ed above.

What are some places I should be looking to figure out a less terse error message? I'm kind of at a loss troubleshooting this.

like image 762
Thomas Lann Avatar asked Feb 14 '14 22:02

Thomas Lann


2 Answers

I encountered this issue today and solved it by installing HARFBUZZ, which is mentioned in the README file of Pango. After installation of Harfbuzz we have access to FreeType. So follow this procedure:

  1. Build and install FreeType
  2. Build and install fontconfig
  3. Build and install Cairo (after ./configure please make sure freetype and fontconfig are found)
  4. Build and install Harfbuzz
  5. Build and install Pango
like image 175
Xiao Jia Avatar answered Oct 20 '22 06:10

Xiao Jia


In case of you still have problems even though you are following the guideline of Xiao Jia, take care to look into config.log. It will help you to find out why the package does not find particular components on your system. In my case the fontconfig-devel and freetype-devel package from default repository of my distro was too old.

I could manage it by installing the whole stack into a location outside of /usr (not that difficult as it sounds) by adding configuration file to /etc/ld.so.conf.d and a environment expanding script to /etc/profile.d.

like image 2
Maik Greubel Avatar answered Oct 20 '22 06:10

Maik Greubel