mirror of
https://github.com/openwrt/packages.git
synced 2026-10-12 10:17:17 +04:00
On big-endian hosts the server parsed every tcpip-forward bind port as zero and bound an ephemeral port, so -R remote forwarding never carried a connection. With no usable entropy source the library crashed inside mbedtls instead of failing cleanly. Patches 2-4 were sent upstream to the libssh mailing list: https://archive.libssh.org/libssh/2026-08/0000000.html https://archive.libssh.org/libssh/2026-08/0000001.html Patch 1 backports the seed-failure error path they depend on from upstream master commit ac4b723c. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
76 lines
1.9 KiB
Makefile
76 lines
1.9 KiB
Makefile
#
|
|
# Copyright (C) 2017 OpenWrt.org
|
|
#
|
|
# This is free software, licensed under the GNU General Public License v2.
|
|
# See /LICENSE for more information.
|
|
#
|
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
PKG_NAME:=libssh
|
|
PKG_VERSION:=0.12.2
|
|
PKG_RELEASE:=2
|
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
|
|
PKG_SOURCE_URL:=https://www.libssh.org/files/0.12/
|
|
PKG_HASH:=49560f677d96e3706a904ac2de1116e25f3680937d51e5c92198fcba4a1c1e9f
|
|
|
|
PKG_MAINTAINER:=Alexandru Ardelean <ardeleanalex@gmail.com>
|
|
PKG_LICENSE:=LGPL-2.1-or-later BSD-2-Clause
|
|
PKG_LICENSE_FILES:=COPYING
|
|
PKG_CPE_ID:=cpe:/a:libssh:libssh
|
|
|
|
CMAKE_INSTALL:=1
|
|
CMAKE_BINARY_SUBDIR:=build
|
|
PKG_BUILD_FLAGS:=no-mips16
|
|
|
|
include $(INCLUDE_DIR)/package.mk
|
|
include $(INCLUDE_DIR)/cmake.mk
|
|
|
|
define Package/libssh
|
|
SECTION:=libs
|
|
CATEGORY:=Libraries
|
|
URL:=$(PKG_SOURCE_URL)
|
|
TITLE:=SSH library
|
|
DEPENDS:=+libpthread +librt +zlib +libmbedtls
|
|
endef
|
|
|
|
define Package/libssh/description
|
|
libssh is a mulitplatform C library implementing the SSHv2 and SSHv1 protocol
|
|
for client and server implementations.
|
|
endef
|
|
|
|
CMAKE_OPTIONS += \
|
|
-DHAVE_STRTOULL=1 \
|
|
-DHAVE_GETADDRINFO=1 \
|
|
-DHAVE_TERMIOS_H=1 \
|
|
-DWITH_EXAMPLES:BOOL=OFF \
|
|
-DWITH_GCRYPT:BOOL=OFF \
|
|
-DWITH_MBEDTLS:BOOL=ON \
|
|
-DWITH_GSSAPI:BOOL=OFF \
|
|
-DWITH_LIBZ:BOOL=ON \
|
|
-DWITH_NACL:BOOL=OFF \
|
|
-DWITH_PCAP:BOOL=OFF \
|
|
-DWITH_SERVER:BOOL=ON \
|
|
-DWITH_SFTP:BOOL=ON \
|
|
-UWITH_STACK_CLASH_PROTECTION \
|
|
-DWITH_STACK_CLASH_PROTECTION=0 \
|
|
-UWITH_STACK_PROTECTOR \
|
|
-DWITH_STACK_PROTECTOR=0 \
|
|
-UWITH_STACK_PROTECTOR_STRONG \
|
|
-DWITH_STACK_PROTECTOR_STRONG=0 \
|
|
-DHAVE_WORDS_BIGENDIAN=$(if $(CONFIG_BIG_ENDIAN),1,0)
|
|
|
|
define Build/InstallDev
|
|
$(call Build/InstallDev/cmake,$(1))
|
|
$(SED) 's,/usr/include,$$$${prefix}/include,g' $(1)/usr/lib/pkgconfig/libssh.pc
|
|
$(SED) 's,/usr/lib,$$$${exec_prefix}/lib,g' $(1)/usr/lib/pkgconfig/libssh.pc
|
|
endef
|
|
|
|
define Package/libssh/install
|
|
$(INSTALL_DIR) $(1)/usr/lib
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libssh* $(1)/usr/lib/
|
|
endef
|
|
|
|
$(eval $(call BuildPackage,libssh))
|