Unable to link libssh in Cmake

Advertisements I am trying to compile C++ Qt app that needs a connection to a ssh server, but I am unable to do it, as every time I try to compile it, I am getting the following error code: [1/1] Linking CXX executable SSH-Manager FAILED: SSH-Manager : && /usr/bin/c++ -g CMakeFiles/SSH-Manager.dir/SSH-Manager_autogen/mocs_compilation.cpp.o CMakeFiles/SSH-Manager.dir/src/main.cpp.o CMakeFiles/SSH-Manager.dir/src/mainwindow.cpp.o CMakeFiles/SSH-Manager.dir/src/ssh_connection.cpp.o -o… Read More Unable to link libssh in Cmake

ssh_connect: Library not initialized (LibSSH)

Advertisements I have the following piece of code which I am trying to build statically, so I end up with a single executable. #define LIBSSH_STATIC 1 #include <libssh/libssh.h> #include <stdlib.h> #include <stdio.h> #include <iostream> #include <errno.h> #include <string.h> #pragma comment(lib, "mbedcrypto.lib") #pragma comment(lib, "pthreadVSE3.lib") #pragma comment(lib, "ssh.lib") #pragma comment(lib, "Ws2_32.lib") int main() { ssh_session my_ssh_session;… Read More ssh_connect: Library not initialized (LibSSH)