blob: 620632d1c3a4c6cd634156b3bbf48d34d1253f74 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
|
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
LUA_COMPAT=( lua5-1 lua5-2 )
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 l10n lua-single xdg-utils toolchain-funcs
[[ ${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 gold 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 )
lua? ( ${LUA_REQUIRED_USE} )
spell? ( qt5 )
sqlite? ( qt5 )
"
if [[ ${PV} != *9999* ]]; then
SRC_URI="mirror://sourceforge/project/${PN}/Sources/${P}.tar.xz"
KEYWORDS="~amd64 ~x86"
else
EGIT_REPO_URI="https://github.com/${PN}/${PN}.git"
KEYWORDS=""
fi
RDEPEND="
app-arch/bzip2
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? (
json? ( dev-libs/jsoncpp:= )
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? ( ${LUA_DEPS} )
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 )
"
BDEPEND="
gold? ( sys-devel/binutils[gold] )
"
DEPEND="${RDEPEND}
sys-devel/gettext
virtual/pkgconfig
qt5? ( dev-qt/linguist-tools:5 )
"
DOCS=( AUTHORS ChangeLog.txt )
PATCHES=(
"${FILESDIR}/${PN}-2.2.10-cmake_lua_version.patch"
"${FILESDIR}/${P}-fix_upnp_compilation.patch"
)
CMAKE_REMOVE_MODULES_LIST="FindLua"
src_prepare() {
cmake_src_prepare
l10n_find_plocales_changes 'eiskaltdcpp-qt/translations' '' '.ts'
}
src_configure() {
local mycmakeargs=(
-DLIB_INSTALL_DIR="$(get_libdir)"
-Dlinguas="$(l10n_get_locales)"
-DCREATE_MO=ON
-DUSE_GTK=OFF
-DUSE_LIBGNOME2=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_GTK3=$(usex gtk)
-DUSE_IDNA=$(usex idn)
-DUSE_JS=$(usex javascript)
-DUSE_LIBCANBERRA=$(usex libcanberra)
-DUSE_LIBNOTIFY=$(usex libnotify)
-DWITH_DEV_FILES=$(usex !minimal)
-DPERL_REGEX=$(usex pcre)
-DUSE_QT5=$(usex qt5)
-DUSE_ASPELL=$(usex spell)
-DLOCAL_ASPELL_DATA=OFF
-DUSE_QT_SQLITE=$(usex sqlite)
-DUSE_MINIUPNP=$(usex upnp)
-DFORCE_XDG=ON
-DENABLE_STACKTRACE=OFF
-DUSE_GOLD=$(usex gold)
-DLOCAL_JSONCPP=OFF
-DBUILD_STATIC=OFF
-DINSTALL_QT_TRANSLATIONS=OFF
-DCOMPRESS_MANPAGES=OFF
)
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 lua; then
mycmakeargs+=(
-DLUA_SCRIPT=ON
-DWITH_LUASCRIPTS=$(usex examples)
-DLUA_VERSION=$(ver_cut 1-2 $(lua_get_version))
)
else
mycmakeargs+=(
-DLUA_SCRIPT=OFF
-DWITH_LUASCRIPTS=OFF
)
fi
if use qt5 || use gtk; then
mycmakeargs+=(
-DWITH_EMOTICONS=ON
-DWITH_SOUNDS=ON
)
else
mycmakeargs+=(
-DWITH_EMOTICONS=OFF
-DWITH_SOUNDS=OFF
)
fi
cmake_src_configure
}
pkg_postinst() {
xdg_desktop_database_update
xdg_icon_cache_update
}
pkg_postrm() {
xdg_desktop_database_update
xdg_icon_cache_update
}
|