error while loading shared libtulip-3.6.so

Selven
2012-01-05
2013-04-20
  • Selven

    Selven - 2012-01-05

    Hello,
    i've installed tulip on Fedora 15 64 bits, and i tryied to run one of the tutorials included in the source folder.

    I launched the makefile and the project was compiled, but when i execute the tutorial bin (for example) :

    $ ./tutorial
    ./tutorial: error while loading shared libraries: libtulip-3.6.so: cannot open shared object file: No such file or directory
    $

    Thanks in advance for your help,

     
  • packadal

    packadal - 2012-01-05

    Hi,

    The executable cannot find the library because there is on information as to where it should look for it.

    You need to put the path where the library lives in your LD_LIBRARY_PATH environment variable.

    Best,
    Charles

     
  • Selven

    Selven - 2012-01-11

    hello,
    thanks, it works perfectly when i compile the program manually.
    But, i trying to do that with, for example, code::blocks :

    #include <iostream>
    #include <tulip/Graph.h>
    using namespace std;
    using namespace tlp;
    int main() {
      //create an empty graph
      Graph *graph = tlp::newGraph();
      //add three nodes
      node n1 = graph->addNode();
      node n2 = graph->addNode();
      node n3 = graph->addNode();
      //add three edges
      edge e1 = graph->addEdge(n2,n3);
      edge e2 = graph->addEdge(n1,n2);
      edge e3 = graph->addEdge(n3,n1);
      //remove an edge
      graph->delEdge(e1);
      //remove a node
      graph->delNode(n2);
      //print the result on the standard output
      cout << graph << flush ;
      //delete the graph
      delete graph;
      return EXIT_SUCCESS;
    }
    

    It's the tutorial N°1 from the source folder of tulip.
    When i compile that, i've an error :

    main.cpp|| undefined reference to `tlp::newGraph()'|
    main.cpp|| undefined reference to `operator<<(std::basic_ostream<char, std::char_traits<char> >&, tlp::Graph const*)'|

    Have you an idea ?

    Thanks in advance,

     
  • packadal

    packadal - 2012-01-11

    Hi,

    This means you do not link your executable against the Tulip library.

    Best,
    Charles.

     
  • Selven

    Selven - 2012-01-11

    H,
    Thanks, it works now, i link the library with he "linker" option and now it compile perfectly.
    Thanks,

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks