Results 1 to 3 of 3

Thread: Boost library link problem under kubuntu

  1. #1
    Join Date
    Dec 2005
    Beans
    193
    Distro
    Xubuntu 8.04 Hardy Heron

    Boost library link problem under kubuntu

    Dear all,

    I have installed the boost libraries by aptitude but there is sth wrong

    when i use

    g++ -g -o Read Driver.cc Mesh_Gen.cc -I/usr/include/boost -L/usr/lib -lboost_filesystem-1_33_1

    I get

    /usr/bin/ld: cannot find -lboost_regex-gcc-1_33_1
    collect2: ld returned 1 exit status
    make: *** [Read] Error 1

    this means that it can not find the library files, but they are there under /usr/lib. I could not figure this out. Can somebody help me?

    Regards,
    If everything seems to be going well, obviously you do not know what the hell is going on.

  2. #2
    Join Date
    Dec 2005
    Beans
    193
    Distro
    Xubuntu 8.04 Hardy Heron

    Re: Boost library link problem under kubuntu

    ldconfig solved the problem and updated the /etc/ld.so.cache
    If everything seems to be going well, obviously you do not know what the hell is going on.

  3. #3
    Join Date
    Aug 2010
    Beans
    24

    Re: Boost library link problem under kubuntu

    I had a very similar problem and found this post while searching. I managed to solved the problem after much more searching, so I post it here for other people.

    I had to link to the proper library this way:
    g++ boost_example.cpp -o run -lboost_filesystem-mt
    http://linux.overshoot.tv/ticket/127

    The real problem is that the boost documentation is lacking and does not say which library to link to. See:
    http://linux.overshoot.tv/ticket/129

    Anyway, to use boost/file_system, link to: -lboost_filesystem-mt .

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •