Results 1 to 3 of 3

Thread: Unable to compile c++ programm, which uses cln library.

  1. #1
    Join Date
    Apr 2014
    Beans
    2

    Unable to compile c++ programm, which uses cln library.

    Hello to everybody!
    I wrote a simple programm for my school project, but when I'm trying to compile it on my PC with Ubuntu 14.04 :
    g++ -lcln -o ferma ferma.cpp
    I get errors:
    http://bpaste.net/show/218812/

    I suppose that there is no errors in my programm, because It succesfully compiles on my PC with gentoo.

    And here is my code:
    http://bpaste.net/show/218813/

    I have got gcc 4.8.2 and libcln6 installed. Also I tried installing that library from source code.
    Last edited by leftwin; April 20th, 2014 at 03:15 PM.

  2. #2
    Join Date
    Jun 2007
    Location
    Maryland, US
    Beans
    6,288
    Distro
    Kubuntu

    Re: Unable to compile c++ programm, which uses cln library.

    Specify the library that you wish to link against last, not first, in your g++ statement. For example:
    Code:
    g++ -o ferma ferma.cpp -lcln

  3. #3
    Join Date
    Apr 2014
    Beans
    2

    Re: Unable to compile c++ programm, which uses cln library.

    Thank you a lot! I'm wondering why does it compile on gentoo machine.

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
  •