mirror of
https://git.libssh.org/projects/libssh.git
synced 2025-07-29 13:01:13 +03:00
Moved samples into examples directory
This commit is contained in:
@ -69,13 +69,4 @@ include_directories(${CMAKE_SOURCE_DIR}/include)
|
|||||||
if (UNIX AND NOT WIN32)
|
if (UNIX AND NOT WIN32)
|
||||||
add_subdirectory(examples)
|
add_subdirectory(examples)
|
||||||
|
|
||||||
if (WITH_SFTP)
|
|
||||||
add_executable(samplessh sample.c)
|
|
||||||
target_link_libraries(samplessh ${LIBSSH_SHARED_LIBRARY})
|
|
||||||
endif (WITH_SFTP)
|
|
||||||
|
|
||||||
if (WITH_SERVER)
|
|
||||||
add_executable(samplesshd samplesshd.c)
|
|
||||||
target_link_libraries(samplesshd ${LIBSSH_SHARED_LIBRARY})
|
|
||||||
endif (WITH_SERVER)
|
|
||||||
endif (UNIX AND NOT WIN32)
|
endif (UNIX AND NOT WIN32)
|
||||||
|
@ -8,6 +8,7 @@ set(examples_SRCS
|
|||||||
|
|
||||||
include_directories(
|
include_directories(
|
||||||
${LIBSSH_PUBLIC_INCLUDE_DIRS}
|
${LIBSSH_PUBLIC_INCLUDE_DIRS}
|
||||||
|
${LIBSSH_PRIVATE_INCLUDE_DIRS}
|
||||||
)
|
)
|
||||||
|
|
||||||
add_executable(libssh_scp libssh_scp.c ${examples_SRCS})
|
add_executable(libssh_scp libssh_scp.c ${examples_SRCS})
|
||||||
@ -16,3 +17,18 @@ add_executable(scp_download scp_download.c ${examples_SRCS})
|
|||||||
target_link_libraries(libssh_scp ${LIBSSH_SHARED_LIBRARY})
|
target_link_libraries(libssh_scp ${LIBSSH_SHARED_LIBRARY})
|
||||||
target_link_libraries(scp_download ${LIBSSH_SHARED_LIBRARY})
|
target_link_libraries(scp_download ${LIBSSH_SHARED_LIBRARY})
|
||||||
|
|
||||||
|
include_directories(
|
||||||
|
${LIBSSH_PUBLIC_INCLUDE_DIRS}
|
||||||
|
${LIBSSH_PRIVATE_INCLUDE_DIRS}
|
||||||
|
)
|
||||||
|
|
||||||
|
if (WITH_SFTP)
|
||||||
|
add_executable(samplessh sample.c)
|
||||||
|
target_link_libraries(samplessh ${LIBSSH_SHARED_LIBRARY})
|
||||||
|
endif (WITH_SFTP)
|
||||||
|
|
||||||
|
if (WITH_SERVER)
|
||||||
|
add_executable(samplesshd samplesshd.c)
|
||||||
|
target_link_libraries(samplesshd ${LIBSSH_SHARED_LIBRARY})
|
||||||
|
endif (WITH_SERVER)
|
||||||
|
|
||||||
|
@ -111,7 +111,8 @@ LIBSSH_API void ssh_bind_fd_toaccept(SSH_BIND *ssh_bind);
|
|||||||
* @brief Accept an incoming ssh connection and initialize the session.
|
* @brief Accept an incoming ssh connection and initialize the session.
|
||||||
*
|
*
|
||||||
* @param ssh_bind The ssh server bind to accept a connection.
|
* @param ssh_bind The ssh server bind to accept a connection.
|
||||||
*
|
* @param session A preallocated ssh session
|
||||||
|
* @see ssh_new
|
||||||
* @return A newly allocated ssh session, NULL on error.
|
* @return A newly allocated ssh session, NULL on error.
|
||||||
*/
|
*/
|
||||||
LIBSSH_API int ssh_bind_accept(SSH_BIND *ssh_bind, ssh_session session);
|
LIBSSH_API int ssh_bind_accept(SSH_BIND *ssh_bind, ssh_session session);
|
||||||
|
Reference in New Issue
Block a user