1
0
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:
Aris Adamantiadis
2009-10-09 21:44:05 +02:00
parent 2e9c13dad0
commit 58294442d3
5 changed files with 22 additions and 14 deletions

View File

@ -69,13 +69,4 @@ include_directories(${CMAKE_SOURCE_DIR}/include)
if (UNIX AND NOT WIN32)
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)

View File

@ -8,6 +8,7 @@ set(examples_SRCS
include_directories(
${LIBSSH_PUBLIC_INCLUDE_DIRS}
${LIBSSH_PRIVATE_INCLUDE_DIRS}
)
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(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)

View File

@ -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.
*
* @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.
*/
LIBSSH_API int ssh_bind_accept(SSH_BIND *ssh_bind, ssh_session session);