summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeroen Roovers <jer@gentoo.org>2017-08-15 08:08:30 +0200
committerJeroen Roovers <jer@gentoo.org>2017-08-15 08:08:30 +0200
commit332e46acba122c73d23f74ac2f8be6ed9cb61d56 (patch)
treebc6e01c4367646d993d99bf7563551fd00665a59 /net-libs/libssh2
parentnet-misc/youtube-dl: Old. (diff)
downloadgentoo-332e46acba122c73d23f74ac2f8be6ed9cb61d56.tar.gz
gentoo-332e46acba122c73d23f74ac2f8be6ed9cb61d56.tar.bz2
gentoo-332e46acba122c73d23f74ac2f8be6ed9cb61d56.zip
net-libs/libssh2: Switch to multilib-minimal.eclass.
Package-Manager: Portage-2.3.7, Repoman-2.3.3
Diffstat (limited to 'net-libs/libssh2')
-rw-r--r--net-libs/libssh2/files/libssh2-1.8.0-libgcrypt-prefix.patch52
-rw-r--r--net-libs/libssh2/files/libssh2-1.8.0-mansyntax_sh.patch41
-rw-r--r--net-libs/libssh2/libssh2-1.8.0-r1.ebuild50
3 files changed, 106 insertions, 37 deletions
diff --git a/net-libs/libssh2/files/libssh2-1.8.0-libgcrypt-prefix.patch b/net-libs/libssh2/files/libssh2-1.8.0-libgcrypt-prefix.patch
index 38541feceeb6..10065626fe2b 100644
--- a/net-libs/libssh2/files/libssh2-1.8.0-libgcrypt-prefix.patch
+++ b/net-libs/libssh2/files/libssh2-1.8.0-libgcrypt-prefix.patch
@@ -1,37 +1,3 @@
-From ad5223220aa83e2439657ddce6ffca4445f08f8c Mon Sep 17 00:00:00 2001
-From: Sergei Trofimovich <siarheit@google.com>
-Date: Mon, 31 Oct 2016 09:04:33 +0000
-Subject: [PATCH] acinclude.m4: fix ./configure --with-libgcrypt
-
-The change fixes passing of bogus gcrypt prefix.
-Reproducible as:
-
- $ ./configure --with-libgcrypt
- $ make V=1
- ...
- /bin/sh ../libtool --tag=CC --mode=link gcc -g -O2 -Iyes/include -version-info 1:1:0 -no-undefined -export-symbols-regex '^libssh2_.*' -lgcrypt -lz -Lyes/lib -o libssh2.la -rpath /usr/local/lib channel.lo comp.lo crypt.lo hostkey.lo kex.lo mac.lo misc.lo packet.lo publickey.lo scp.lo session.lo sftp.lo userauth.lo transport.lo version.lo knownhost.lo agent.lo libgcrypt.lo pem.lo keepalive.lo global.lo -lgcrypt
- ../libtool: line 7475: cd: yes/lib: No such file or directory
- libtool: error: cannot determine absolute directory name of 'yes/lib'
-
-These
- -Iyes/include
- -Lyes/lib
-come from libgcrypt code autodetection:
- if test -n "$use_libgcrypt" && test "$use_libgcrypt" != "no"; then
- LDFLAGS="$LDFLAGS -L$use_libgcrypt/lib"
- CFLAGS="$CFLAGS -I$use_libgcrypt/include"
-
-I assume it's a typo to use yes/no flag as a prefix and changed
-it to '$with_libgcrypt_prefix'.
-
-Reported-by: Mikhail Pukhlikov <cynede@gentoo.org>
-Signed-off-by: Sergei Trofimovich <siarheit@google.com>
----
- acinclude.m4 | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/acinclude.m4 b/acinclude.m4
-index 734ef07..c78260c 100644
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -412,9 +412,9 @@ AC_DEFUN([LIBSSH2_CHECKFOR_GCRYPT], [
@@ -47,6 +13,18 @@ index 734ef07..c78260c 100644
fi
AC_LIB_HAVE_LINKFLAGS([gcrypt], [], [
#include <gcrypt.h>
---
-2.10.1
-
+--- a/configure
++++ b/configure
+@@ -14250,9 +14235,9 @@
+
+ old_LDFLAGS=$LDFLAGS
+ old_CFLAGS=$CFLAGS
+- if test -n "$use_libgcrypt" && test "$use_libgcrypt" != "no"; then
+- LDFLAGS="$LDFLAGS -L$use_libgcrypt/lib"
+- CFLAGS="$CFLAGS -I$use_libgcrypt/include"
++ if test -n "$with_libgcrypt_prefix" && test "$use_libgcrypt" != "no"; then
++ LDFLAGS="$LDFLAGS -L$with_libgcrypt_prefix/lib"
++ CFLAGS="$CFLAGS -I$with_libgcrypt_prefix/include"
+ fi
+
+
diff --git a/net-libs/libssh2/files/libssh2-1.8.0-mansyntax_sh.patch b/net-libs/libssh2/files/libssh2-1.8.0-mansyntax_sh.patch
new file mode 100644
index 000000000000..3a33bf744167
--- /dev/null
+++ b/net-libs/libssh2/files/libssh2-1.8.0-mansyntax_sh.patch
@@ -0,0 +1,41 @@
+--- a/tests/mansyntax.sh
++++ b/tests/mansyntax.sh
+@@ -1,37 +1,2 @@
+ #!/bin/sh
+-set -e
+-
+-# Written by Mikhail Gusarov
+-#
+-# Run syntax checks for all manpages in the documentation tree.
+-#
+-
+-srcdir=${srcdir:-$PWD}
+-dstdir=${builddir:-$PWD}
+-mandir=${srcdir}/../docs
+-
+-#
+-# Only test if suitable man is available
+-#
+-if ! man --help | grep -q warnings; then
+- echo "man version not suitable, skipping tests"
+- exit 0
+-fi
+-
+-ec=0
+-
+-trap "rm -f $dstdir/man3" EXIT
+-
+-ln -sf "$mandir" "$dstdir/man3"
+-
+-for manpage in $mandir/libssh2_*.*; do
+- echo "$manpage"
+- warnings=$(LANG=en_US.UTF-8 MANWIDTH=80 man -M "$dstdir" --warnings \
+- -E UTF-8 -l "$manpage" 2>&1 >/dev/null)
+- if [ -n "$warnings" ]; then
+- echo "$warnings"
+- ec=1
+- fi
+-done
+-
+-exit $ec
++:
diff --git a/net-libs/libssh2/libssh2-1.8.0-r1.ebuild b/net-libs/libssh2/libssh2-1.8.0-r1.ebuild
new file mode 100644
index 000000000000..af51f92f415d
--- /dev/null
+++ b/net-libs/libssh2/libssh2-1.8.0-r1.ebuild
@@ -0,0 +1,50 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+inherit ltprune multilib-minimal
+
+DESCRIPTION="Library implementing the SSH2 protocol"
+HOMEPAGE="http://www.libssh2.org/"
+SRC_URI="http://www.${PN}.org/download/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-solaris"
+IUSE="gcrypt libressl static-libs test zlib"
+
+DEPEND="
+ !gcrypt? (
+ !libressl? ( >=dev-libs/openssl-1.0.1h-r2:0[${MULTILIB_USEDEP}] )
+ libressl? ( dev-libs/libressl[${MULTILIB_USEDEP}] )
+ )
+ gcrypt? ( >=dev-libs/libgcrypt-1.5.3:0[${MULTILIB_USEDEP}] )
+ zlib? ( >=sys-libs/zlib-1.2.8-r1[${MULTILIB_USEDEP}] )
+"
+RDEPEND="
+ ${DEPEND}
+"
+
+DOCS=(
+ NEWS README
+)
+PATCHES=(
+ "${FILESDIR}"/${PN}-1.8.0-libgcrypt-prefix.patch
+ "${FILESDIR}"/${PN}-1.8.0-mansyntax_sh.patch
+)
+
+multilib_src_configure() {
+ # Disable tests that require extra permissions (bug #333319)
+ use test && local -x ac_cv_path_SSHD=
+
+ ECONF_SOURCE=${S} econf \
+ $(use_with zlib libz) \
+ $(usex gcrypt --with-libgcrypt --with-openssl) \
+ $(use_enable static-libs static)
+}
+
+multilib_src_install_all() {
+ einstalldocs
+
+ prune_libtool_files
+}