8

In my ubuntu 12.04, the graphviz is not the latest version(2.29). I need some features available in the latest version of graphviz. I tried to install the graphviz version 2.29, which requires libgraphviz4(>=2.18). I anyhow installed libgraphviz4 and installed graphviz 2.29. For that I have to remove packages libcdt4 and libpathplan4.

Now whenever I try to generate graph, I get some problems: For e.g.:

dot -Kfdp -n -Tpng -o samplePOS.png forcePOS.dot

It says:

dot: error while loading shared libraries: libgvc.so.6: cannot open
shared object file: No such file or directory

neato -Tps -o sample_1.ps sourcedot.gv

It says:

neato: error while loading shared libraries: libgvc.so.6: cannot open
shared object file: No such file or directory

So, I am looking for some ways so that I can run graphviz 2.29 in my ubuntu 12.04.

Tim
  • 32,861
  • 27
  • 118
  • 178
bidur
  • 83

3 Answers3

14

First a warning for using PPA (mainly unstable)

The below PPA: ppa:dperry/ppa-graphviz-test is an unstable PPA. So, you are given warning.

Use this commands in a terminal to install the unstable 2.29 version of graphviz.

sudo apt-add-repository ppa:dperry/ppa-graphviz-test
sudo apt-get update
sudo apt-get autoremove graphviz
sudo apt-get install graphviz

If you get this error "graphviz : Depends: libgraphviz4 (>= 2.18) but it is not going to be installed", run the following

sudo apt-get remove libcdt4
sudo apt-get remove libpathplan4
sudo apt-get install graphviz
Anwar
  • 76,649
  • I followed these steps But it is not able to install the latest graphviz version. I encountered the same problem which I have stated in the beginning, i.e. requires libgraphviz4(>=2.18) http://imageshack.us/f/17/screenshotfrom201210041.png/ – bidur Oct 04 '12 at 07:20
  • If you have previous installation of graphviz, remove it completely – Anwar Oct 04 '12 at 07:25
  • Thank You very much. I could install graphviz 2.29 after removing packages libcdt4 and libpathplan4. – bidur Oct 04 '12 at 07:33
  • This installs 2.26.3 again for me. Any idea why? – KomodoDave Oct 07 '12 at 18:32
  • I think it's because the latest build in PPA author's repo failed on Precise Pangolin x64, so if you're using 64 bit Ubuntu 12.04 like me, watch out. – KomodoDave Oct 07 '12 at 18:43
  • This method works for ubuntu 12.04 but I could not get it done for ubuntu 10.04 – bidur Oct 09 '12 at 07:04
  • @bidur You asked question for 12.04. – Anwar Oct 09 '12 at 07:05
  • @Olive my problem was solved for 12.04 . Just to let others know that this method may not work for 10.04 – bidur Oct 09 '12 at 07:46
  • @bidur Are you on 32-bit 12.04, or 64-bit? – KomodoDave Oct 09 '12 at 17:40
  • @KomodoDave My system is 12.04 (precise) 32-bit – bidur Oct 10 '12 at 03:29
  • The mentioned PPA doesn't seem to work anymore, but the one found at https://launchpad.net/~gviz-adm/+archive/ubuntu/graphviz-dev does. Gives the same error mentioned above, the suggested fix (remove libcdt4 libpathplan4) still fixes the issue. – Joanis Nov 07 '14 at 16:44
3

Ubuntu 12.04 here.

What worked for me is:

  1. Remove the following packages

    sudo apt-get remove libcdt4
    
    sudo apt-get remove libpathplan4
    
  2. Install libgraphviz4

    http://www.graphviz.org/Download_linux_ubuntu.php

  3. Install graphviz

    sudo apt-get install graphviz
    
Anwar
  • 76,649
anh_ng8
  • 131
  • 4
0

Since you mess with some libraries i advice you to remove graphviz and install again

sudo apt-get remove graphviz
sudo apt-get remove graphviz-dev
sudo apt-get remove graphviz-doc
sudo apt-get install graphviz

This is a same situation for other user

  • I tried this but this will install graphviz (2.26.3-10ubuntu1) NOT the latest version 2.29 – bidur Oct 04 '12 at 06:34
  • But 2.29 still not stable. I advice you to stay at 2.26.3 as Ubuntu propose to avoid such conflicts –  Oct 04 '12 at 06:37
  • even I wish to stay with the stable version but I need some features provided by the version 2.29 – bidur Oct 04 '12 at 07:21