Merge pull request #12118 from micmac1/ssh2-bdep
libssh2: add mbedtls to PKG_BUILD_DEPENDS
This commit is contained in:
commit
a942ca6293
2 changed files with 17 additions and 24 deletions
|
@ -1,15 +0,0 @@
|
||||||
if PACKAGE_libssh2
|
|
||||||
|
|
||||||
choice
|
|
||||||
prompt "Choose crypto backend"
|
|
||||||
default LIBSSH2_MBEDTLS
|
|
||||||
|
|
||||||
config LIBSSH2_MBEDTLS
|
|
||||||
bool "mbedtls"
|
|
||||||
|
|
||||||
config LIBSSH2_OPENSSL
|
|
||||||
bool "openssl"
|
|
||||||
|
|
||||||
endchoice
|
|
||||||
|
|
||||||
endif
|
|
|
@ -35,7 +35,7 @@ define Package/libssh2
|
||||||
CATEGORY:=Libraries
|
CATEGORY:=Libraries
|
||||||
TITLE:=SSH2 library
|
TITLE:=SSH2 library
|
||||||
URL:=https://www.libssh2.org/
|
URL:=https://www.libssh2.org/
|
||||||
DEPENDS:=+LIBSSH2_MBEDTLS:libmbedtls +LIBSSH2_OPENSSL:libopenssl +zlib
|
DEPENDS:=+LIBSSH2_MBEDTLS:libmbedtls +!LIBSSH2_MBEDTLS:libopenssl +zlib
|
||||||
ABI_VERSION:=1
|
ABI_VERSION:=1
|
||||||
endef
|
endef
|
||||||
|
|
||||||
|
@ -44,20 +44,28 @@ define Package/libssh2/description
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/libssh2/config
|
define Package/libssh2/config
|
||||||
source "$(SOURCE)/Config.in"
|
if PACKAGE_libssh2
|
||||||
|
|
||||||
|
choice
|
||||||
|
prompt "Choose crypto backend"
|
||||||
|
default LIBSSH2_OPENSSL
|
||||||
|
|
||||||
|
config LIBSSH2_OPENSSL
|
||||||
|
bool "openssl"
|
||||||
|
|
||||||
|
config LIBSSH2_MBEDTLS
|
||||||
|
bool "mbedtls"
|
||||||
|
endchoice
|
||||||
|
|
||||||
|
endif
|
||||||
endef
|
endef
|
||||||
|
|
||||||
CMAKE_OPTIONS += \
|
CMAKE_OPTIONS += \
|
||||||
-DBUILD_SHARED_LIBS=ON \
|
-DBUILD_SHARED_LIBS=ON \
|
||||||
-DBUILD_TESTING=OFF \
|
-DBUILD_TESTING=OFF \
|
||||||
-DENABLE_ZLIB_COMPRESSION=ON \
|
-DENABLE_ZLIB_COMPRESSION=ON \
|
||||||
-DCLEAR_MEMORY=ON
|
-DCLEAR_MEMORY=ON \
|
||||||
|
-DCRYPTO_BACKEND=$(if $(CONFIG_LIBSSH2_MBEDTLS),mbedTLS,OpenSSL)
|
||||||
ifeq ($(CONFIG_LIBSSH2_OPENSSL),y)
|
|
||||||
CMAKE_OPTIONS += -DCRYPTO_BACKEND=OpenSSL
|
|
||||||
else
|
|
||||||
CMAKE_OPTIONS += -DCRYPTO_BACKEND=mbedTLS
|
|
||||||
endif
|
|
||||||
|
|
||||||
define Package/libssh2/install
|
define Package/libssh2/install
|
||||||
$(INSTALL_DIR) $(1)/usr/lib
|
$(INSTALL_DIR) $(1)/usr/lib
|
||||||
|
|
Loading…
Reference in a new issue