Skip to content

Commit 47c8efb

Browse files
committed
build BUGFIX libssh search fixed
1 parent a3c7076 commit 47c8efb

2 files changed

Lines changed: 2 additions & 8 deletions

File tree

CMakeLists.txt

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,6 @@ endif()
3535
set(CMAKE_C_STANDARD 11)
3636
set(CMAKE_CXX_EXTENSIONS ON)
3737
add_compile_options(-Wall -Wextra -fvisibility=hidden)
38-
#TODO add_compile_options(-Wpedantic)
39-
40-
4138
set(CMAKE_C_FLAGS_PACKAGE "-g -O2 -DNDEBUG")
4239

4340
# Version of the project
@@ -231,8 +228,8 @@ endif()
231228

232229
# dependencies - libssh
233230
if(ENABLE_SSH)
234-
option(LIBSSH_FIND_VERSION "check version too" ON)
235-
find_package(LibSSH 0.7.0 REQUIRED)
231+
set(LIBSSH_FIND_VERSION 0.7.0)
232+
find_package(LibSSH REQUIRED)
236233
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DNC_ENABLED_SSH")
237234
message(STATUS "LibSSH version ${LIBSSH_VERSION} found")
238235

CMakeModules/FindLibSSH.cmake

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,11 +64,9 @@ else()
6464

6565
if(LIBSSH_INCLUDE_DIR AND LIBSSH_LIBRARY)
6666
set(LIBSSH_FOUND TRUE)
67-
message(STATUS "LIBSSH Found: ${LIBSSH_LIBRARY}")
6867
endif()
6968

7069
set(LIBSSH_INCLUDE_DIRS ${LIBSSH_INCLUDE_DIR})
71-
message(STATUS "LIBSSH_INCLUDE_DIR: ${LIBSSH_INCLUDE_DIR}")
7270

7371
if(LIBSSH_FOUND)
7472
string(REPLACE "libssh.so" ""
@@ -83,7 +81,6 @@ else()
8381
LIBSSH_LIBRARY_DIR
8482
${LIBSSH_LIBRARY_DIR}
8583
)
86-
message(STATUS "LIBSSH_LIBRARY_DIR: ${LIBSSH_LIBRARY_DIR}")
8784

8885
if(LIBSSH_FIND_VERSION)
8986
file(STRINGS ${LIBSSH_INCLUDE_DIR}/libssh/libssh.h LIBSSH_VERSION_MAJOR

0 commit comments

Comments
 (0)