FS#50156 - [openbabel] Missing dependency: cairo

Attached to Project: Arch Linux
Opened by Luchesar V. ILIEV (kerberizer) - Tuesday, 26 July 2016, 20:33 GMT
Last edited by Antonio Rojas (arojas) - Tuesday, 28 March 2023, 20:52 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To Felix Yan (felixonmars)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No



It seems cairo is a required dependency, which might not be readily detectable on systems where cairo is preinstalled (e.g. desktops). Example from a system without cairo follows:

$ obabel
*** Open Babel Error in openLib
/usr/lib/openbabel/2.3.2/png2format.so did not load properly.
Error: libcairo.so.2: cannot open shared object file: No such file or directory

$ ldd /usr/lib/openbabel/2.3.2/png2format.so
linux-vdso.so.1 (0x00007ffc3e9ce000)
libcairo.so.2 => not found

$ sudo pacman -Sy cairo

$ ldd /usr/lib/openbabel/2.3.2/png2format.so
linux-vdso.so.1 (0x00007ffdacca1000)
libcairo.so.2 => /usr/lib/libcairo.so.2 (0x00007f26b729c000)

$ obabel
No input file or format spec or possibly a misplaced option.
Most options must come after the input files. (-i -o -O -m can be anywhwere.)

Open Babel 2.3.2 -- Jul 8 2016 -- 06:00:16

Additional info:
* package version(s): openbabel 2.3.2-6
* config and/or log files etc.: see above

Steps to reproduce:
1. Install openbabel on a system __without__ cairo preinstalled.
2. Execute '/usr/bin/obabel'.
This task depends upon

Closed by  Antonio Rojas (arojas)
Tuesday, 28 March 2023, 20:52 GMT
Reason for closing:  Fixed
Additional comments about closing:  openbabel 3.1.1-6
Comment by Doug Newgard (Scimmia) - Wednesday, 27 July 2016, 01:42 GMT
Do NOT run pacman -Sy when installing things. Partial updates are not supported.
Comment by Luchesar V. ILIEV (kerberizer) - Wednesday, 27 July 2016, 02:51 GMT
My bad! I put it there only as an indication of the moment cairo was installed and didn't give it much thought, but it's indeed a bad example of pacman usage for anyone who sees this ticket. Thanks for pointing it out.
Comment by mattia (nTia89) - Sunday, 27 February 2022, 11:30 GMT
wxgtk3 is now an optional dep, which in its turn depends on cairo.

Is this still a valid issue?
Comment by Balló György (City-busz) - Tuesday, 28 March 2023, 20:27 GMT
cairo is still a missing dependency. It's linked by /usr/lib/openbabel/3.1.0/png2format.so to provide PNG output support.