Blame doc/linking.dox

Packit 6c0a39
/**
Packit 6c0a39
Packit 6c0a39
@page libssh_linking The Linking HowTo
Packit 6c0a39
Packit 6c0a39
@section dynamic Dynamic Linking
Packit 6c0a39
Packit 6c0a39
On UNIX and Windows systems its the same, you need at least the libssh.h
Packit 6c0a39
header file and the libssh shared library.
Packit 6c0a39
Packit 6c0a39
@section static Static Linking
Packit 6c0a39
Packit 6c0a39
@warning The libssh library is licensed under the LGPL! Make sure you
Packit 6c0a39
understand what this means to your codebase if you want to distribute
Packit 6c0a39
binaries and link statically against LGPL code!
Packit 6c0a39
Packit 6c0a39
On UNIX systems linking against the static version of the library is the
Packit 6c0a39
same as linking against the shared library. Both have the same name. Some
Packit 6c0a39
build system require to use the full path to the static library.
Packit 6c0a39
Packit 6c0a39
To be able to compile the application you're developing you need to either pass
Packit 6c0a39
LIBSSH_STATIC as a define in the compiler command line or define it before you
Packit 6c0a39
include libssh.h.  This is required cause the dynamic library needs to specify
Packit 6c0a39
the dllimport attribute.
Packit 6c0a39
Packit 6c0a39
@code
Packit 6c0a39
#define LIBSSH_STATIC 1
Packit 6c0a39
#include <libssh/libssh.h>
Packit 6c0a39
@endcode
Packit 6c0a39
Packit 6c0a39
If you're are statically linking with OpenSSL, read the "Linking your
Packit Service fcc0d2
application" section in the NOTES.[OS] in the OpenSSL source tree!
Packit 6c0a39
Packit 6c0a39
*/