summaryrefslogtreecommitdiff
path: root/net-p2p/eiskaltdcpp
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
commit4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch)
treeba5f07bf3f9d22d82e54a462313f5d244036c768 /net-p2p/eiskaltdcpp
reinit the tree, so we can have metadata
Diffstat (limited to 'net-p2p/eiskaltdcpp')
-rw-r--r--net-p2p/eiskaltdcpp/Manifest11
-rw-r--r--net-p2p/eiskaltdcpp/eiskaltdcpp-2.2.10.ebuild149
-rw-r--r--net-p2p/eiskaltdcpp/eiskaltdcpp-9999.ebuild161
-rw-r--r--net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-ipv6_upnp.patch123
-rw-r--r--net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-miniupnpc1.patch31
-rw-r--r--net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-miniupnpc2.patch29
-rw-r--r--net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-openssl-1.1.patch138
-rw-r--r--net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-tray-close.patch23
-rw-r--r--net-p2p/eiskaltdcpp/metadata.xml22
9 files changed, 687 insertions, 0 deletions
diff --git a/net-p2p/eiskaltdcpp/Manifest b/net-p2p/eiskaltdcpp/Manifest
new file mode 100644
index 000000000000..7c878a1edaa8
--- /dev/null
+++ b/net-p2p/eiskaltdcpp/Manifest
@@ -0,0 +1,11 @@
+AUX eiskaltdcpp-2.2.10-ipv6_upnp.patch 4793 SHA256 1dd9ba73c3f64e2a683bcb75cd06df430f30982b95cdacaf1065d231579fcdfa SHA512 d1be465da6cc13584f074bf9b96a0355127b4e2e0b3d571473116fa55a2bca617786988f0dae58ddf50a4f31531658cdc6258eb92ab2eb7599165b5ca6d11cf5 WHIRLPOOL 32c713f39cab7592f9f8674b11f3e70b3d8574e644cced52d300cf6b1bd4ece911381cc9f235d4c5c1a2bf6c57e55b3b83e791da136da0b07920aa54336fc146
+AUX eiskaltdcpp-2.2.10-miniupnpc1.patch 1511 SHA256 e41d973803825566a9914e7a07ea46bb1faa91a6bc0c9663e5c82a93c60c7f69 SHA512 fb97a5b2a43433ec3b3bb557b1b6c488e6f3b38bf507eade67468636a1cc7721de2ef005664e248945e5d68bc82e479849c88628598d53aaecdef438fffa3e09 WHIRLPOOL 3b1fa78a4c3b05947f4f3e4961708b0de524dfb005fc64f6f8e5f390a18dc82079f421117993cf3d30b601a729b845d72eb11c3efcf8111ea4df34b5e0a43dc5
+AUX eiskaltdcpp-2.2.10-miniupnpc2.patch 1123 SHA256 d1d02648f488c22c58b2090bdba5babc828a8479a03cf310a8ed4be55ba6a470 SHA512 14cd68087aeaa755eeae58fd1265af35fb4f4e1651e7f083f09fd9e660a1b8df5bb8d6e31add6ba30796c99058030386432a69ef4338d969c692a80931361e36 WHIRLPOOL ff70505649873e022df1255c02c7ca3395d016ab2a42e12c8c71c904aa13cfab8157527f4d5210347e26eba10c9ba4c2559801419c819f32619036a3f5fa6e53
+AUX eiskaltdcpp-2.2.10-openssl-1.1.patch 5482 SHA256 d8ace9b52618f0a48a018aa070130dcb0f39c584d75d55cdea499c98006b0f61 SHA512 52433c16a95aefa9e5fd36c812b6f4cc5729cd870885fada69fe5529da11ab1edf4701879c62db0befab17e60da1168bf724ae8c39ee5f22d24eafda4f808485 WHIRLPOOL 71953184f84ad8d527a1afe237d46d2f2e56ee3dee3c71048e49d2dfa170adc86ba7131bb8e05aca9f425ee83d570e30fb113a46c0c46a4e9fa75b67a64ffd04
+AUX eiskaltdcpp-2.2.10-tray-close.patch 788 SHA256 57d4278e9670cff5c01231bcc727d6fe12018f80d74750aaa34e636f77a7c04f SHA512 f1f59590b7ded55bc6351450cbe1efcf15ca8db2c532d2871512c8866809f06572076a586c968fade8d0f2fe8d33eb06d1b0359fb810748b6ad9d812c188155d WHIRLPOOL 0c886e588d213703f9782565d2f786528072dcfb215aa7288b585813b8ad8c0910a47990944aacf8f0b0bf8dc4e23d43a6024322c1d54eb6b6759919b92c1a57
+DIST eiskaltdcpp-2.2.10.tar.gz 3843143 SHA256 e461c8c499e459651d6382a6ded6788e5ac9a9c4ff26386c3cf073d94d606127 SHA512 97c39287b9568aebc5ab21aeabefb63ea32bde8744242bb8647b742c933de9cf74a7fbb2e6df7be6046319bbc660e8abdec0fa332ee91ec5048492af0d763818 WHIRLPOOL 463abac15ccabdbe002d6b5e30cf1baa7486055e304ec963a4d50449ff8b451d093beba273d2e11a9002e642d6dcb06e05970898b893a86c7917dfbfa02611ae
+EBUILD eiskaltdcpp-2.2.10.ebuild 3260 SHA256 ff639ab1fcebb17b01aac1aa30355b74158c198940b76f48be87e4d7915e3a6d SHA512 e8c0310563413d235ed03b814e672dc09e0a35f882cc9124ed80e3ed47e129fffee553e82ff09341bc0e5a6a0bb1b01a5a2f486dbdeb63a316b234fc6ebef606 WHIRLPOOL 6592cc5360e03257bac6dad7165a28f68166f126ac8d431525019157ecefff6d0fa6982d4b3583cdf649e31700674b8b384aecc68a90c0d302151cf32a704eb9
+EBUILD eiskaltdcpp-9999.ebuild 3489 SHA256 64b7c3e68a13905cd48d9c393140ff0659928559eacb7e67b6c3bb63db708bd6 SHA512 1e42ac5f1ff745f48299088953bedcddeadb4cfd74a11ddb5ac52748861d97f3811c127d721b6d687cb544fc26fb423e1e0101d8e5581ebaf844f6a53e93576c WHIRLPOOL 09b946def9c77c389fb7076fad30a29558de70506e480f70c1102f0ac070c0824ea6ddd10127ff4e7ae3fac9c699fa5d04208d9f4c767b5e6961174f035e6b60
+MISC ChangeLog 2678 SHA256 42386e773dddf40be5a406447bcb703f81409067318b3f66b46c35f703cebee9 SHA512 9cf43206c6637a69beab4d1e9861734c9e6a5a355f455656a1c0a773d4e0207e46c48f734293844218b5f0cea73ef1c69ea7005fd39082a5b6bafb1cc0708806 WHIRLPOOL 8ad8bb2979b1c425b5bb7f290382240afe329ccd63f6907f9d3a734833196ac1763868183292ce5a1c32d90a19872ee7a0cb98c29746b27e8f8da9a89e44d51f
+MISC ChangeLog-2015 11096 SHA256 30693b260225184806fdeab40aae91f6b37f44159418fff66470c3815c762122 SHA512 3b2d73d41b2b97d78f4f687b9bad032fdbfbbb32c9c0c69ff26ba788f9cdf4a8bde1430580a8e7ea695e6e884710a2b27bf2d33254a4435163b450ad275f425b WHIRLPOOL 94ba3a09d704c6e414197c1b26eec9fdc04995d98165f4257b1b7768e035b1ee4a59d14dae56ba8709e0ea8af531357fda03a6ee6b0055497bb4e67b697bd4b0
+MISC metadata.xml 996 SHA256 c86ad162b468b17f839d378a71215fcf7afc8def096b388f8ea3b9838c8af9fd SHA512 c36a94f827751c9a4ad080470d52576ea7a679a709605dec744f6bd55b0c4bb7566cc4e17aa499e09087cda45f839e0aa6a9e0d29ce5ce089fa25bf07a3e7325 WHIRLPOOL ce5cadd55bb66a53cb4877cc673f9e092d6426cc0c684981b15800cabd17ee7532fb162c79aac4d10c866f07f7ff44cd515065ad49be8ff16c229a9a6fbdce83
diff --git a/net-p2p/eiskaltdcpp/eiskaltdcpp-2.2.10.ebuild b/net-p2p/eiskaltdcpp/eiskaltdcpp-2.2.10.ebuild
new file mode 100644
index 000000000000..69ba4dfd9af6
--- /dev/null
+++ b/net-p2p/eiskaltdcpp/eiskaltdcpp-2.2.10.ebuild
@@ -0,0 +1,149 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+PLOCALES="be bg cs de el en es eu fr hu it pl pt_BR ru sk sr@latin sr sv_SE uk vi zh_CN"
+
+inherit cmake-utils gnome2-utils l10n xdg-utils
+[[ ${PV} = *9999* ]] && inherit git-r3
+
+DESCRIPTION="Qt/DC++ based client for DirectConnect and ADC protocols"
+HOMEPAGE="https://github.com/eiskaltdcpp/eiskaltdcpp"
+
+LICENSE="GPL-2 GPL-3"
+SLOT="0"
+IUSE="cli daemon dbus +dht examples idn -javascript json lua +minimal pcre +qt5 spell sqlite upnp -xmlrpc"
+
+REQUIRED_USE="
+ ?? ( json xmlrpc )
+ cli? ( ^^ ( json xmlrpc ) )
+ dbus? ( qt5 )
+ javascript? ( qt5 )
+ spell? ( qt5 )
+ sqlite? ( qt5 )
+"
+
+if [[ ${PV} != *9999* ]]; then
+ SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+ KEYWORDS="~amd64 ~x86"
+else
+ EGIT_REPO_URI="https://github.com/${PN}/${PN}.git"
+ KEYWORDS=""
+fi
+
+RDEPEND="
+ app-arch/bzip2
+ dev-libs/boost:=
+ dev-libs/openssl:0=
+ sys-apps/attr
+ sys-libs/zlib
+ virtual/libiconv
+ virtual/libintl
+ cli? (
+ dev-lang/perl
+ dev-perl/Data-Dump
+ dev-perl/Term-ShellUI
+ virtual/perl-Getopt-Long
+ json? ( dev-perl/JSON-RPC )
+ xmlrpc? ( dev-perl/RPC-XML )
+ )
+ daemon? ( xmlrpc? ( dev-libs/xmlrpc-c[abyss,cxx] ) )
+ idn? ( net-dns/libidn )
+ lua? ( dev-lang/lua:= )
+ pcre? ( dev-libs/libpcre )
+ qt5? (
+ dev-qt/qtconcurrent:5
+ dev-qt/qtcore:5
+ dev-qt/qtgui:5
+ dev-qt/qtmultimedia:5
+ dev-qt/qtnetwork:5
+ dev-qt/qtwidgets:5
+ dev-qt/qtxml:5
+ dbus? ( dev-qt/qtdbus:5 )
+ javascript? (
+ dev-qt/qtdeclarative:5
+ dev-qt/qtscript:5
+ )
+ spell? ( app-text/aspell )
+ sqlite? ( dev-qt/qtsql:5[sqlite] )
+ )
+ upnp? ( net-libs/miniupnpc )
+"
+DEPEND="${RDEPEND}
+ sys-devel/gettext
+ virtual/pkgconfig
+ qt5? ( dev-qt/linguist-tools:5 )
+"
+
+DOCS=( AUTHORS ChangeLog.txt )
+
+PATCHES=(
+ "${FILESDIR}"/${P}-ipv6_upnp.patch
+ "${FILESDIR}"/${P}-miniupnpc{1,2}.patch
+ "${FILESDIR}"/${P}-openssl-1.1.patch
+ "${FILESDIR}"/${P}-tray-close.patch
+)
+
+src_prepare() {
+ cmake-utils_src_prepare
+ l10n_find_plocales_changes 'eiskaltdcpp-qt/translations' '' '.ts'
+}
+
+src_configure() {
+ local mycmakeargs=(
+ -DLIB_INSTALL_DIR="$(get_libdir)"
+ -Dlinguas="$(l10n_get_locales)"
+ -DLOCAL_MINIUPNP=OFF
+ -DUSE_GTK=OFF
+ -DUSE_GTK3=OFF
+ -DUSE_LIBGNOME2=OFF
+ -DUSE_LIBCANBERRA=OFF
+ -DUSE_LIBNOTIFY=OFF
+ -DUSE_QT=OFF
+ -DUSE_QT_QML=OFF
+ -DNO_UI_DAEMON=$(usex daemon)
+ -DDBUS_NOTIFY=$(usex dbus)
+ -DWITH_DHT=$(usex dht)
+ -DWITH_EXAMPLES=$(usex examples)
+ -DUSE_IDNA=$(usex idn)
+ -DUSE_JS=$(usex javascript)
+ -DLUA_SCRIPT=$(usex lua)
+ -DWITH_LUASCRIPTS=$(usex lua)
+ -DWITH_DEV_FILES=$(usex !minimal)
+ -DPERL_REGEX=$(usex pcre)
+ -DUSE_QT5=$(usex qt5)
+ -DWITH_EMOTICONS=$(usex qt5)
+ -DWITH_SOUNDS=$(usex qt5)
+ -DUSE_ASPELL=$(usex spell)
+ -DUSE_QT_SQLITE=$(usex sqlite)
+ -DUSE_MINIUPNP=$(usex upnp)
+ )
+ if use cli; then
+ mycmakeargs+=(
+ -DUSE_CLI_JSONRPC=$(usex json)
+ -DUSE_CLI_XMLRPC=$(usex xmlrpc)
+ )
+ fi
+ if use daemon; then
+ mycmakeargs+=(
+ -DJSONRPC_DAEMON=$(usex json)
+ -DXMLRPC_DAEMON=$(usex xmlrpc)
+ )
+ fi
+ cmake-utils_src_configure
+}
+
+pkg_preinst() {
+ gnome2_icon_savelist
+}
+
+pkg_postinst() {
+ xdg_desktop_database_update
+ gnome2_icon_cache_update
+}
+
+pkg_postrm() {
+ xdg_desktop_database_update
+ gnome2_icon_cache_update
+}
diff --git a/net-p2p/eiskaltdcpp/eiskaltdcpp-9999.ebuild b/net-p2p/eiskaltdcpp/eiskaltdcpp-9999.ebuild
new file mode 100644
index 000000000000..8a00e9cfb49d
--- /dev/null
+++ b/net-p2p/eiskaltdcpp/eiskaltdcpp-9999.ebuild
@@ -0,0 +1,161 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+PLOCALES="be bg cs de el en es eu fr hu it pl pt_BR ru sk sr sr@latin sv_SE tr uk vi zh_CN"
+
+inherit cmake-utils gnome2-utils l10n xdg-utils
+[[ ${PV} = *9999* ]] && inherit git-r3
+
+DESCRIPTION="Qt/DC++ based client for DirectConnect and ADC protocols"
+HOMEPAGE="https://github.com/eiskaltdcpp/eiskaltdcpp"
+
+LICENSE="GPL-2 GPL-3"
+SLOT="0"
+IUSE="cli daemon dbus +dht examples -gtk idn -javascript json libcanberra libnotify lua +minimal pcre +qt5 spell sqlite upnp -xmlrpc"
+
+REQUIRED_USE="
+ ?? ( json xmlrpc )
+ cli? ( ^^ ( json xmlrpc ) )
+ dbus? ( qt5 )
+ javascript? ( qt5 )
+ libcanberra? ( gtk )
+ libnotify? ( gtk )
+ spell? ( qt5 )
+ sqlite? ( qt5 )
+"
+
+if [[ ${PV} != *9999* ]]; then
+ SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+ KEYWORDS="~amd64 ~x86"
+else
+ EGIT_REPO_URI="https://github.com/${PN}/${PN}.git"
+ KEYWORDS=""
+fi
+
+RDEPEND="
+ app-arch/bzip2
+ dev-libs/boost:=
+ dev-libs/openssl:0=
+ sys-apps/attr
+ sys-libs/zlib
+ virtual/libiconv
+ virtual/libintl
+ cli? (
+ dev-lang/perl
+ dev-perl/Data-Dump
+ dev-perl/Term-ShellUI
+ virtual/perl-Getopt-Long
+ json? ( dev-perl/JSON-RPC )
+ xmlrpc? ( dev-perl/RPC-XML )
+ )
+ daemon? ( xmlrpc? ( dev-libs/xmlrpc-c[abyss,cxx] ) )
+ gtk? (
+ dev-libs/glib:2
+ x11-libs/gtk+:3
+ x11-libs/pango
+ x11-themes/hicolor-icon-theme
+ libcanberra? ( media-libs/libcanberra )
+ libnotify? ( x11-libs/libnotify )
+ )
+ idn? ( net-dns/libidn )
+ lua? ( dev-lang/lua:= )
+ pcre? ( dev-libs/libpcre )
+ qt5? (
+ dev-qt/qtconcurrent:5
+ dev-qt/qtcore:5
+ dev-qt/qtgui:5
+ dev-qt/qtmultimedia:5
+ dev-qt/qtnetwork:5
+ dev-qt/qtwidgets:5
+ dev-qt/qtxml:5
+ dbus? ( dev-qt/qtdbus:5 )
+ javascript? (
+ dev-qt/qtdeclarative:5
+ dev-qt/qtscript:5
+ )
+ spell? ( app-text/aspell )
+ sqlite? ( dev-qt/qtsql:5[sqlite] )
+ )
+ upnp? ( net-libs/miniupnpc )
+"
+DEPEND="${RDEPEND}
+ sys-devel/gettext
+ virtual/pkgconfig
+ qt5? ( dev-qt/linguist-tools:5 )
+"
+
+DOCS=( AUTHORS ChangeLog.txt )
+
+src_prepare() {
+ cmake-utils_src_prepare
+ l10n_find_plocales_changes 'eiskaltdcpp-qt/translations' '' '.ts'
+}
+
+src_configure() {
+ local mycmakeargs=(
+ -DLIB_INSTALL_DIR="$(get_libdir)"
+ -Dlinguas="$(l10n_get_locales)"
+ -DLOCAL_MINIUPNP=OFF
+ -DUSE_GTK=OFF
+ -DUSE_QT=OFF
+ -DUSE_QT_QML=OFF
+ -DUSE_LIBGNOME2=OFF
+ -DNO_UI_DAEMON=$(usex daemon)
+ -DDBUS_NOTIFY=$(usex dbus)
+ -DWITH_DHT=$(usex dht)
+ -DWITH_EXAMPLES=$(usex examples)
+ -DUSE_GTK3=$(usex gtk)
+ -DUSE_IDNA=$(usex idn)
+ -DUSE_JS=$(usex javascript)
+ -DUSE_LIBCANBERRA=$(usex libcanberra)
+ -DUSE_LIBNOTIFY=$(usex libnotify)
+ -DLUA_SCRIPT=$(usex lua)
+ -DWITH_LUASCRIPTS=$(usex lua)
+ -DWITH_DEV_FILES=$(usex !minimal)
+ -DPERL_REGEX=$(usex pcre)
+ -DUSE_QT5=$(usex qt5)
+ -DUSE_ASPELL=$(usex spell)
+ -DUSE_QT_SQLITE=$(usex sqlite)
+ -DUSE_MINIUPNP=$(usex upnp)
+ )
+ if use cli; then
+ mycmakeargs+=(
+ -DUSE_CLI_JSONRPC=$(usex json)
+ -DUSE_CLI_XMLRPC=$(usex xmlrpc)
+ )
+ fi
+ if use daemon; then
+ mycmakeargs+=(
+ -DJSONRPC_DAEMON=$(usex json)
+ -DXMLRPC_DAEMON=$(usex xmlrpc)
+ )
+ fi
+ if use qt5 || use gtk; then
+ mycmakeargs+=(
+ -DWITH_EMOTICONS=ON
+ -DWITH_SOUNDS=ON
+ )
+ else
+ mycmakeargs+=(
+ -DWITH_EMOTICONS=OFF
+ -DWITH_SOUNDS=OFF
+ )
+ fi
+ cmake-utils_src_configure
+}
+
+pkg_preinst() {
+ gnome2_icon_savelist
+}
+
+pkg_postinst() {
+ xdg_desktop_database_update
+ gnome2_icon_cache_update
+}
+
+pkg_postrm() {
+ xdg_desktop_database_update
+ gnome2_icon_cache_update
+}
diff --git a/net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-ipv6_upnp.patch b/net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-ipv6_upnp.patch
new file mode 100644
index 000000000000..9b1f7638b6aa
--- /dev/null
+++ b/net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-ipv6_upnp.patch
@@ -0,0 +1,123 @@
+From 639b9f9aa286f10ce11f9fb28f0c83985f069a0d Mon Sep 17 00:00:00 2001
+From: Sergey Farbotka <z8sergey8z@gmail.com>
+Date: Mon, 31 Aug 2015 23:55:44 +0300
+Subject: [PATCH] Core: send IPv4-only address in UPNP request
+
+The app sends first available local IP address in UPNP request.
+If first available address is IPv6, miniupnpd sends the following error:
+"Failed to convert hostname '<my-ipv6-address>' to ip address"
+
+As eiskaltdc++ does not support IPv6 yet, we can use IPv4 address only
+in UPNP requests.
+---
+ dcpp/ConnectivityManager.cpp | 2 +-
+ dcpp/Util.cpp | 17 ++++++++++++-----
+ dcpp/Util.h | 5 +++--
+ extra/upnpc.cpp | 2 +-
+ 4 files changed, 17 insertions(+), 9 deletions(-)
+
+diff --git a/dcpp/ConnectivityManager.cpp b/dcpp/ConnectivityManager.cpp
+index 3495a9a..acc0d68 100644
+--- a/dcpp/ConnectivityManager.cpp
++++ b/dcpp/ConnectivityManager.cpp
+@@ -90,7 +90,7 @@ void ConnectivityManager::detectConnection() {
+
+ autoDetected = true;
+
+- if (!Util::isPrivateIp(Util::getLocalIp())) {
++ if (!Util::isPrivateIp(Util::getLocalIp(AF_INET))) {
+ SettingsManager::getInstance()->set(SettingsManager::INCOMING_CONNECTIONS, SettingsManager::INCOMING_DIRECT);
+ log(_("Public IP address detected, selecting active mode with direct connection"));
+ fire(ConnectivityManagerListener::Finished());
+diff --git a/dcpp/Util.cpp b/dcpp/Util.cpp
+index dc7e08e..9b5a2ca 100644
+--- a/dcpp/Util.cpp
++++ b/dcpp/Util.cpp
+@@ -704,7 +704,7 @@ string Util::formatExactSize(int64_t aBytes) {
+ #endif
+ }
+
+-vector<string> Util::getLocalIPs() {
++vector<string> Util::getLocalIPs(unsigned short sa_family) {
+ vector<string> addresses;
+
+ #ifdef HAVE_IFADDRS_H
+@@ -712,6 +712,9 @@ vector<string> Util::getLocalIPs() {
+
+ if (getifaddrs(&ifap) == 0)
+ {
++ bool ipv4 = (sa_family == AF_UNSPEC) || (sa_family == AF_INET);
++ bool ipv6 = (sa_family == AF_UNSPEC) || (sa_family == AF_INET6);
++
+ for (struct ifaddrs *i = ifap; i != NULL; i = i->ifa_next)
+ {
+ struct sockaddr *sa = i->ifa_addr;
+@@ -723,14 +726,14 @@ vector<string> Util::getLocalIPs() {
+ socklen_t len;
+
+ // IPv4 address
+- if (sa->sa_family == AF_INET)
++ if (ipv4 && (sa->sa_family == AF_INET))
+ {
+ struct sockaddr_in* sai = (struct sockaddr_in*)sa;
+ src = (void*) &(sai->sin_addr);
+ len = INET_ADDRSTRLEN;
+ }
+ // IPv6 address
+- else if (sa->sa_family == AF_INET6)
++ else if (ipv6 && (sa->sa_family == AF_INET6))
+ {
+ struct sockaddr_in6* sai6 = (struct sockaddr_in6*)sa;
+ src = (void*) &(sai6->sin6_addr);
+@@ -752,9 +755,13 @@ vector<string> Util::getLocalIPs() {
+
+ return addresses;
+ }
+-string Util::getLocalIp() {
++string Util::getLocalIp(unsigned short as_family) {
+ #ifdef HAVE_IFADDRS_H
+- return getLocalIPs().empty() ? "0.0.0.0" : getLocalIPs()[0];
++ vector<string> addresses = getLocalIPs(as_family);
++ if (addresses.empty())
++ return (((as_family == AF_UNSPEC) || (as_family == AF_INET)) ? "0.0.0.0" : "::");
++
++ return addresses[0];
+ #else
+ string tmp;
+
+diff --git a/dcpp/Util.h b/dcpp/Util.h
+index a489f70..f2842d3 100644
+--- a/dcpp/Util.h
++++ b/dcpp/Util.h
+@@ -28,6 +28,7 @@
+
+ #include <sys/stat.h>
+ #include <sys/types.h>
++#include <sys/socket.h>
+ #include <unistd.h>
+ #include <cstdlib>
+ #include <vector>
+@@ -403,8 +404,8 @@ class Util
+ }
+
+ static string encodeURI(const string& /*aString*/, bool reverse = false);
+- static string getLocalIp();
+- static std::vector<string> getLocalIPs();
++ static string getLocalIp(unsigned short sa_family = AF_UNSPEC);
++ static std::vector<string> getLocalIPs(unsigned short sa_family = AF_UNSPEC);
+ static bool isPrivateIp(string const& ip);
+ static string formatAdditionalInfo(const std::string& aIp, bool sIp, bool sCC);
+ /**
+diff --git a/extra/upnpc.cpp b/extra/upnpc.cpp
+index fb61f14..63f6d34 100644
+--- a/extra/upnpc.cpp
++++ b/extra/upnpc.cpp
+@@ -63,7 +63,7 @@ bool UPnPc::add(const unsigned short port, const UPnP::Protocol protocol, const
+ const string port_ = Util::toString(port);
+
+ return UPNP_AddPortMapping(urls.controlURL, data.first.servicetype, port_.c_str(), port_.c_str(),
+- Util::getLocalIp().c_str(), description.c_str(), protocols[protocol], NULL
++ Util::getLocalIp(AF_INET).c_str(), description.c_str(), protocols[protocol], NULL
+ #if (MINIUPNPC_API_VERSION == 8 || defined(MINIUPNPC16))
+ , 0) == UPNPCOMMAND_SUCCESS;
+ #else
diff --git a/net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-miniupnpc1.patch b/net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-miniupnpc1.patch
new file mode 100644
index 000000000000..7cca21840c7f
--- /dev/null
+++ b/net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-miniupnpc1.patch
@@ -0,0 +1,31 @@
+From 33bf1489e75d1b1cc834d6eb9629598cd77d6c58 Mon Sep 17 00:00:00 2001
+From: Pavel Vatagin <pavelvat@gmail.com>
+Date: Sun, 17 Jan 2016 03:00:36 +0300
+Subject: [PATCH] extra: fix static build for windows with -DLOCAL_MINIUPNP=OFF
+
+---
+ extra/upnpc.cpp | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/extra/upnpc.cpp b/extra/upnpc.cpp
+index 63f6d34..40a011a 100644
+--- a/extra/upnpc.cpp
++++ b/extra/upnpc.cpp
+@@ -42,7 +42,7 @@ using namespace dcpp;
+ bool UPnPc::init()
+ {
+ UPNPDev *devices = upnpDiscover(5000, SettingsManager::getInstance()->isDefault(SettingsManager::BIND_ADDRESS) ? 0 : SETTING(BIND_ADDRESS).c_str(), 0, 0
+-#if (MINIUPNPC_API_VERSION == 8 || defined(MINIUPNPC16))
++#if (MINIUPNPC_API_VERSION >= 8 || defined(MINIUPNPC16))
+ , 0, 0);
+ #else
+ );
+@@ -64,7 +64,7 @@ bool UPnPc::add(const unsigned short port, const UPnP::Protocol protocol, const
+
+ return UPNP_AddPortMapping(urls.controlURL, data.first.servicetype, port_.c_str(), port_.c_str(),
+ Util::getLocalIp(AF_INET).c_str(), description.c_str(), protocols[protocol], NULL
+-#if (MINIUPNPC_API_VERSION == 8 || defined(MINIUPNPC16))
++#if (MINIUPNPC_API_VERSION >= 8 || defined(MINIUPNPC16))
+ , 0) == UPNPCOMMAND_SUCCESS;
+ #else
+ ) == UPNPCOMMAND_SUCCESS;
diff --git a/net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-miniupnpc2.patch b/net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-miniupnpc2.patch
new file mode 100644
index 000000000000..bbe113b9cf47
--- /dev/null
+++ b/net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-miniupnpc2.patch
@@ -0,0 +1,29 @@
+From b88120830e974d843cbfec552b639fa72c64dcbd Mon Sep 17 00:00:00 2001
+From: Pavel Vatagin <pavelvat@gmail.com>
+Date: Fri, 5 Feb 2016 04:15:33 +0300
+Subject: [PATCH] extra: fix #332
+
+---
+ extra/upnpc.cpp | 8 ++++++--
+ 1 file changed, 6 insertions(+), 2 deletions(-)
+
+diff --git a/extra/upnpc.cpp b/extra/upnpc.cpp
+index 40a011a..bbd7bbf 100644
+--- a/extra/upnpc.cpp
++++ b/extra/upnpc.cpp
+@@ -41,9 +41,13 @@ using namespace dcpp;
+
+ bool UPnPc::init()
+ {
+- UPNPDev *devices = upnpDiscover(5000, SettingsManager::getInstance()->isDefault(SettingsManager::BIND_ADDRESS) ? 0 : SETTING(BIND_ADDRESS).c_str(), 0, 0
++ UPNPDev *devices = upnpDiscover(5000, SettingsManager::getInstance()->isDefault(SettingsManager::BIND_ADDRESS) ? 0 : SETTING(BIND_ADDRESS).c_str(), NULL, 0
+ #if (MINIUPNPC_API_VERSION >= 8 || defined(MINIUPNPC16))
+- , 0, 0);
++ , 0
++#if (MINIUPNPC_API_VERSION >= 14)
++ , 2
++#endif
++ , NULL);
+ #else
+ );
+ #endif
diff --git a/net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-openssl-1.1.patch b/net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-openssl-1.1.patch
new file mode 100644
index 000000000000..bf6f387ec26e
--- /dev/null
+++ b/net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-openssl-1.1.patch
@@ -0,0 +1,138 @@
+From 3b9c502ff5c98856d4f8fdb7ed3c6ef34448bfb7 Mon Sep 17 00:00:00 2001
+From: Igor Gnatenko <ignatenkobrain@fedoraproject.org>
+Date: Tue, 7 Feb 2017 09:19:18 +0100
+Subject: [PATCH] crypto: add support for OpenSSL 1.1
+
+In OpenSSL 1.1 BN and SSL are opaque structures.
+
+* BN_set0_pqg() has been implemented in 1.1
+* SSL_is_server() has been implemented in 1.0.2 and 1.1
+
+Reported-by: Vasiliy Glazov <vascom2@gmail.com>
+Closes: https://github.com/eiskaltdcpp/eiskaltdcpp/issues/356
+Signed-off-by: Igor Gnatenko <ignatenkobrain@fedoraproject.org>
+---
+ dcpp/CryptoManager.cpp | 15 +++++++++++----
+ dcpp/SSLSocket.cpp | 11 +++++++++--
+ 2 files changed, 20 insertions(+), 6 deletions(-)
+
+diff --git a/dcpp/CryptoManager.cpp b/dcpp/CryptoManager.cpp
+index 08893a75c..b672d92f4 100644
+--- a/dcpp/CryptoManager.cpp
++++ b/dcpp/CryptoManager.cpp
+@@ -27,12 +27,20 @@
+ #include "version.h"
+
+ #include <openssl/bn.h>
+-
++#include <openssl/rand.h>
+ #include <bzlib.h>
+
+ namespace dcpp {
+
+-
++static const char ciphersuites[] =
++ "ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES128-GCM-SHA256:"
++ "ECDHE-ECDSA-AES256-SHA384:ECDHE-ECDSA-AES128-SHA256:"
++ "ECDHE-RSA-AES256-GCM-SHA384:ECDHE-RSA-AES128-GCM-SHA256:"
++ "ECDHE-RSA-AES256-SHA384:ECDHE-RSA-AES128-SHA256:"
++ "ECDHE-ECDSA-AES256-SHA:ECDHE-RSA-AES256-SHA:ECDHE-RSA-AES128-SHA:"
++ "DHE-RSA-AES256-SHA:DHE-RSA-AES128-SHA:"
++ "AES256-GCM-SHA384:AES256-SHA256:AES256-SHA:AES128-SHA"
++ "!aNULL:!eNULL:!EXPORT:!DES:!RC4:!3DES:!MD5:!PSK";
+
+ CryptoManager::CryptoManager()
+ :
+@@ -42,10 +50,10 @@
+ {
+ SSL_library_init();
+
+- clientContext.reset(SSL_CTX_new(TLSv1_client_method()));
+- clientVerContext.reset(SSL_CTX_new(TLSv1_client_method()));
+- serverContext.reset(SSL_CTX_new(TLSv1_server_method()));
+- serverVerContext.reset(SSL_CTX_new(TLSv1_server_method()));
++ clientContext.reset(SSL_CTX_new(SSLv23_client_method()));
++ clientVerContext.reset(SSL_CTX_new(SSLv23_client_method()));
++ serverContext.reset(SSL_CTX_new(SSLv23_server_method()));
++ serverVerContext.reset(SSL_CTX_new(SSLv23_server_method()));
+
+ if(clientContext && clientVerContext && serverContext && serverVerContext) {
+ dh.reset(DH_new());
+@@ -101,10 +109,15 @@
+ };
+
+ if(dh) {
+- dh->p = BN_bin2bn(dh4096_p, sizeof(dh4096_p), 0);
+- dh->g = BN_bin2bn(dh4096_g, sizeof(dh4096_g), 0);
+-
++ BIGNUM *p = BN_bin2bn(dh4096_p, sizeof(dh4096_p), 0);
++ BIGNUM *g = BN_bin2bn(dh4096_g, sizeof(dh4096_g), 0);
++#if OPENSSL_VERSION_NUMBER < 0x10100000L
++ dh->p = p;
++ dh->g = g;
+ if (!dh->p || !dh->g) {
++#else
++ if (!DH_set0_pqg(dh, p, NULL, g)) {
++#endif
+ dh.reset();
+ } else {
+ SSL_CTX_set_options(serverContext, SSL_OP_SINGLE_DH_USE);
+@@ -112,6 +125,28 @@
+ SSL_CTX_set_tmp_dh(serverContext, (DH*)dh);
+ SSL_CTX_set_tmp_dh(serverVerContext, (DH*)dh);
+ }
++ BN_free(p);
++ BN_free(g);
++ }
++
++ SSL_CTX_set_options(clientContext, SSL_OP_NO_SSLv2 | SSL_OP_NO_SSLv3 | SSL_OP_NO_COMPRESSION);
++ SSL_CTX_set_cipher_list(clientContext, ciphersuites);
++ SSL_CTX_set_options(serverContext, SSL_OP_SINGLE_DH_USE | SSL_OP_NO_SSLv2 | SSL_OP_NO_SSLv3 | SSL_OP_NO_COMPRESSION);
++ SSL_CTX_set_cipher_list(serverContext, ciphersuites);
++ SSL_CTX_set_options(clientVerContext, SSL_OP_NO_SSLv2 | SSL_OP_NO_SSLv3 | SSL_OP_NO_COMPRESSION);
++ SSL_CTX_set_cipher_list(clientVerContext, ciphersuites);
++ SSL_CTX_set_options(serverVerContext, SSL_OP_SINGLE_DH_USE | SSL_OP_NO_SSLv2 | SSL_OP_NO_SSLv3 | SSL_OP_NO_COMPRESSION);
++ SSL_CTX_set_cipher_list(serverVerContext, ciphersuites);
++
++ EC_KEY* tmp_ecdh;
++ /* NID_X9_62_prime256v1 is not secure, more secure is NID_secp384r1 or NID_secp521r1*/
++ if((tmp_ecdh = EC_KEY_new_by_curve_name(NID_X9_62_prime256v1)) != NULL) {
++ SSL_CTX_set_options(serverContext, SSL_OP_SINGLE_ECDH_USE);
++ SSL_CTX_set_tmp_ecdh(serverContext, tmp_ecdh);
++ SSL_CTX_set_options(serverVerContext, SSL_OP_SINGLE_ECDH_USE);
++ SSL_CTX_set_tmp_ecdh(serverVerContext, tmp_ecdh);
++
++ EC_KEY_free(tmp_ecdh);
+ }
+
+ SSL_CTX_set_verify(serverContext, SSL_VERIFY_NONE, 0);
+diff --git a/dcpp/SSLSocket.cpp b/dcpp/SSLSocket.cpp
+index 1e283eec8..d4dc12388 100644
+--- a/dcpp/SSLSocket.cpp
++++ b/dcpp/SSLSocket.cpp
+@@ -37,6 +37,13 @@ void SSLSocket::connect(const string& aIp, uint16_t aPort) {
+ waitConnected(0);
+ }
+
++#if OPENSSL_VERSION_NUMBER < 0x10002000L
++static inline int SSL_is_server(SSL *s)
++{
++ return s->server;
++}
++#endif
++
+ bool SSLSocket::waitConnected(uint32_t millis) {
+ if(!ssl) {
+ if(!Socket::waitConnected(millis)) {
+@@ -54,9 +61,9 @@ bool SSLSocket::waitConnected(uint32_t millis) {
+ }
+
+ while(true) {
+- int ret = ssl->server?SSL_accept(ssl):SSL_connect(ssl);
++ int ret = SSL_is_server(ssl)?SSL_accept(ssl):SSL_connect(ssl);
+ if(ret == 1) {
+- dcdebug("Connected to SSL server using %s as %s\n", SSL_get_cipher(ssl), ssl->server?"server":"client");
++ dcdebug("Connected to SSL server using %s as %s\n", SSL_get_cipher(ssl), SSL_is_server(ssl)?"server":"client");
+ return true;
+ }
+ if(!waitWant(ret, millis)) {
diff --git a/net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-tray-close.patch b/net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-tray-close.patch
new file mode 100644
index 000000000000..0749fe80802e
--- /dev/null
+++ b/net-p2p/eiskaltdcpp/files/eiskaltdcpp-2.2.10-tray-close.patch
@@ -0,0 +1,23 @@
+From 35edb67258747a4704bad0288d9d02d3486493d8 Mon Sep 17 00:00:00 2001
+From: aneo78 <aneo78@yandex.ru>
+Date: Fri, 11 Aug 2017 23:29:33 +0700
+Subject: [PATCH] fix issue 363: eiskaltdcpp-qt don't close in Qt5
+
+---
+ eiskaltdcpp-qt/src/MainWindow.cpp | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/eiskaltdcpp-qt/src/MainWindow.cpp b/eiskaltdcpp-qt/src/MainWindow.cpp
+index a80c5e9c0..e8b49e4b6 100644
+--- a/eiskaltdcpp-qt/src/MainWindow.cpp
++++ b/eiskaltdcpp-qt/src/MainWindow.cpp
+@@ -390,6 +390,9 @@ void MainWindow::closeEvent(QCloseEvent *c_e){
+ if (ConnectionManager::getInstance())
+ ConnectionManager::getInstance()->disconnect();
+
++ if (Notification::getInstance())
++ Notify->enableTray(false);
++
+ d->arena->hide();
+ d->arena->setWidget(NULL);
+
diff --git a/net-p2p/eiskaltdcpp/metadata.xml b/net-p2p/eiskaltdcpp/metadata.xml
new file mode 100644
index 000000000000..b65eafebb426
--- /dev/null
+++ b/net-p2p/eiskaltdcpp/metadata.xml
@@ -0,0 +1,22 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <!-- maintainer-needed -->
+ <longdescription lang="en">
+ EiskaltDC++ is a multi-platform program that uses the Direct Connect and
+ ADC protocol. It is compatible with other DC clients, such as the original DC
+ from Neomodus, DC++ and derivatives. EiskaltDC++ also interoperates with all
+ common DC hub software.
+ </longdescription>
+ <use>
+ <flag name="cli">Enable sample cli based on readline</flag>
+ <flag name="daemon">Enable eiskaltdcpp-daemon</flag>
+ <flag name="dht">Enable DHT (distributed hash table) support for libeiskaltdcpp</flag>
+ <flag name="json">Enable JSON for cli and daemon</flag>
+ <flag name="libcanberra">Enable sound notifications support over libcanberra in EiskaltDC++ Gtk</flag>
+ <flag name="minimal">Don't install headers</flag>
+ </use>
+ <upstream>
+ <remote-id type="github">eiskaltdcpp/eiskaltdcpp</remote-id>
+ </upstream>
+</pkgmetadata>