blob: 3db8f5cae7fa22aded4a992c9a0de12a889d1dd6 (
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
|
# Copyright 1999-2016 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
EAPI=6
inherit qmake-utils git-r3 autotools eutils
DESCRIPTION="Automated syncing between your computers and your MEGA cloud drive"
HOMEPAGE="https://mega.nz/ https://github.com/meganz/MEGAsync https://github.com/meganz/sdk"
EGIT_REPO_URI="https://github.com/meganz/MEGAsync.git"
EGIT_COMMIT="2e03defad7e732afe5ffd6977eeb10558f25457b"
LICENSE="MEGA-Code-Review BSD-2"
SLOT="0"
KEYWORDS="amd64 x86"
IUSE="qt5 libressl"
RESTRICT="bindist"
RDEPEND="dev-libs/crypto++
sys-libs/zlib
dev-db/sqlite:3
dev-libs/libsodium
net-dns/c-ares
!libressl? (
net-misc/curl[ssl,curl_ssl_openssl]
)
libressl? (
net-misc/curl[ssl,curl_ssl_libressl]
)
!qt5? (
dev-qt/qtcore:4
dev-qt/qtgui:4
dev-qt/qtdbus:4
)
qt5? (
dev-qt/qtcore:5
dev-qt/qtgui:5
dev-qt/qtdbus:5
dev-qt/qtwidgets:5
dev-qt/qtnetwork:5
)"
DEPEND="${RDEPEND}
app-arch/unzip"
src_prepare() {
default
eapply "${FILESDIR}/megasync-libressl.patch"
cd src/MEGASync/mega || die
eautoreconf
}
src_configure() {
cd src/MEGASync/mega || die
econf \
--disable-curl-checks \
--disable-megaapi \
--with-cryptopp \
--with-zlib \
--with-cares \
--with-curl \
--without-sodium \
--without-freeimage \
--without-readline \
--without-termcap \
--disable-posix-threads \
--disable-examples
cd ../.. || die
$(usex qt5 eqmake5 eqmake4) MEGA.pro
}
src_compile() {
cd src || die
# bypass qtchooser, some may only have qt4, some qt5
if use qt5 ; then
${ROOT}usr/$(get_libdir)/qt5/bin/lrelease MEGASync/MEGASync.pro || die
elif ! use qt5 ; then
${ROOT}usr/$(get_libdir)/qt4/bin/lrelease MEGASync/MEGASync.pro || die
fi
emake
}
src_install() {
dodoc README.md CREDITS.md
cd src/MEGASync || die
dobin megasync
cd platform/linux/data || die
insinto /usr/share/applications
doins megasync.desktop
cd icons/hicolor || die
for size in 16 32 48 128 256; do
doicon -s ${size} ${size}x${size}/apps/mega.png
done
}
|