[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: undefined reference to `ssh_new`

eeeek, wow such an easy fix. Thanks a lot, now why do I have to do that?? What is the reason behind it?? Sorry about the question, but I like to be able to understand whats going on and know why every time I use the libssh i have to use -lssh? Is there away to set up gcc to do it for me??

--- On Thu, 6/24/10, Aris Adamantiadis <aris@xxxxxxxxxxxx> wrote:

From: Aris Adamantiadis <aris@xxxxxxxxxxxx>
Subject: Re: undefined reference to `ssh_new`
To: libssh@xxxxxxxxxx
Date: Thursday, June 24, 2010, 7:09 AM


You probably forgot to link with libssh. If you're compiling by hand,
just add -lssh to the command line, or if you're using an IDE, configure
it to link with the "ssh" library.


Shawn Braune a écrit :
> Yes, I am new to this library and i guess on the intermediate level of
> programing, but when I was just trying to try out libssh by just
> declaring a session and using the ssh_new() I get this when I compile it
> /tmp/ccK5xvPt.o: In function `main':
> test.c:(.text+0xa): undefined reference to `ssh_new'
> collect2: ld returned 1 exit status
> I honestly I am stumped on this, and it is most likely a easy fix but I
> am stumped. Could anyone possible point me in the right direction??


Re: undefined reference to `ssh_new`Aris Adamantiadis <aris@xxxxxxxxxxxx>
Re: undefined reference to `ssh_new`Aris Adamantiadis <aris@xxxxxxxxxxxx>
Archive administrator: postmaster@lists.cynapses.org