summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSven Eden <sven.eden@gmx.de>2018-10-01 13:45:55 +0200
committerSven Eden <sven.eden@gmx.de>2018-10-01 13:45:55 +0200
commit801806a2afd7b82ca5dd23a3a0849f0584919091 (patch)
treef5dd363410b01058aab059cd48f84e3377238d62
parentgames-strategy/widelands: Fix building against >=dev-libs/icu-61.1 (diff)
downloadseden-801806a2afd7b82ca5dd23a3a0849f0584919091.tar.gz
seden-801806a2afd7b82ca5dd23a3a0849f0584919091.tar.bz2
seden-801806a2afd7b82ca5dd23a3a0849f0584919091.zip
net-misc/megasync: Version bump to 3.7.1
Apart from having extended the USE flag possibilities, the ebuild now also handles gnome2_icon_cache and xdg_{desktop,mimeinfo}_database correctly. Package-Manager: Portage-2.3.50, Repoman-2.3.11
-rw-r--r--net-misc/megasync/Manifest3
-rw-r--r--net-misc/megasync/files/megasync-3.7.1-adapt_distro_version.patch (renamed from net-misc/megasync/files/megasync-3.5.3-adapt_distro_version.patch)0
-rw-r--r--net-misc/megasync/files/megasync-3.7.1-enable_install_target.patch (renamed from net-misc/megasync/files/megasync-3.5.3-enable_install_target.patch)0
-rw-r--r--net-misc/megasync/files/megasync-3.7.1-fix_strict_aliasing.patch12
-rw-r--r--net-misc/megasync/megasync-3.5.3.ebuild162
-rw-r--r--net-misc/megasync/megasync-3.7.1.ebuild225
-rw-r--r--net-misc/megasync/metadata.xml15
7 files changed, 250 insertions, 167 deletions
diff --git a/net-misc/megasync/Manifest b/net-misc/megasync/Manifest
index 5860adc..2da2d4e 100644
--- a/net-misc/megasync/Manifest
+++ b/net-misc/megasync/Manifest
@@ -1,2 +1 @@
-DIST megasync-3.5.3-2.1.src.rpm 33464304 SHA256 00f3d7fe3d5cb1670593bb8dff0855d9e863d9cc4b5c987922679c73a642a539 SHA512 622f19095260fd4c281a426d8203369daf5a7ae302b23e30a1b3329efd18a622c5d9f21d1647f2898202fb1d75315b089068fc92d990324a3cc774bb80a75c59 WHIRLPOOL 255f8a7d7f23c17beeadf83a60bfb4394b0899fd97dfc61f941c878c3ea473c32c3942721884ae56ff7f968a6830f9af380bea1faf4da4e44aff77f1e532ff48
-DIST megasync-3.6.6-5.1.src.rpm 34613178 SHA256 7c6ec6282000642d93f2972526cd9856c8c99c232261145d6512a57431547c58 SHA512 48a5300cf466c87ef29443e33077f842f03326f155b2963bda771a43dcd3caa97df13dfdf266ed002271aa5ac2aed9a2f130a6e9b9be31368bd44adbcd6c0fb8 WHIRLPOOL 7ec7b7ba857db0d8f039c92637fc43cccd24e3910544e043157b01c3842b9b3490bc4934131db6b902118d93d4d809ed863021eddd7fad24fab0b2325a963c2b
+DIST megasync-3.7.1-1.src.rpm 36047281 SHA256 649e372236365a886340335688cbf6b8f8ea2aa8687240c47c2a7ab131414e39 SHA512 97aff221869912de3576fd18a88d2558f893a39b5ab9f0a36d1fcc98b9c9692796aaa99d52f990dc3b74fb68e07b4a04438c3f6b09947ebb5795002379bfaf29 WHIRLPOOL 92e9514767ceaf7bdcc2d11eaa4cf759f66306b0cfa861053430de44600da77f7e2d0aa01004a08e83953042aa44a6b724619a912df582a790ba0c6116070c82
diff --git a/net-misc/megasync/files/megasync-3.5.3-adapt_distro_version.patch b/net-misc/megasync/files/megasync-3.7.1-adapt_distro_version.patch
index 1e0c3e7..1e0c3e7 100644
--- a/net-misc/megasync/files/megasync-3.5.3-adapt_distro_version.patch
+++ b/net-misc/megasync/files/megasync-3.7.1-adapt_distro_version.patch
diff --git a/net-misc/megasync/files/megasync-3.5.3-enable_install_target.patch b/net-misc/megasync/files/megasync-3.7.1-enable_install_target.patch
index d3ff194..d3ff194 100644
--- a/net-misc/megasync/files/megasync-3.5.3-enable_install_target.patch
+++ b/net-misc/megasync/files/megasync-3.7.1-enable_install_target.patch
diff --git a/net-misc/megasync/files/megasync-3.7.1-fix_strict_aliasing.patch b/net-misc/megasync/files/megasync-3.7.1-fix_strict_aliasing.patch
new file mode 100644
index 0000000..5887eff
--- /dev/null
+++ b/net-misc/megasync/files/megasync-3.7.1-fix_strict_aliasing.patch
@@ -0,0 +1,12 @@
+--- a/MEGASync/mega/src/posix/fs.cpp 2018-10-01 12:57:20.853946247 +0200
++++ b/MEGASync/mega/src/posix/fs.cpp 2018-10-01 13:16:34.393906698 +0200
+@@ -1739,7 +1739,8 @@
+ // FIXME: statfs() does not really do what we want.
+ if (statfs(localbasepath.c_str(), &statfsbuf)) return 0;
+
+- return *(fsfp_t*)&statfsbuf.f_fsid + 1;
++ return (fsfp_t)( (uint64_t)statfsbuf.f_fsid.__val[0]
++ | (uint64_t)statfsbuf.f_fsid.__val[1] << 32) + 1;
+ }
+
+ FileAccess* PosixFileSystemAccess::newfileaccess()
diff --git a/net-misc/megasync/megasync-3.5.3.ebuild b/net-misc/megasync/megasync-3.5.3.ebuild
deleted file mode 100644
index b14567b..0000000
--- a/net-misc/megasync/megasync-3.5.3.ebuild
+++ /dev/null
@@ -1,162 +0,0 @@
-# Copyright 1999-2018 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-inherit autotools eutils gnome2-utils qmake-utils rpm
-
-DESCRIPTION="Easy automated syncing between your computers and your MEGA cloud drive"
-HOMEPAGE="http://mega.co.nz"
-
-RELEASE="2.1"
-
-BASE_URL=""
-
-SRC_URI="https://mega.nz/linux/MEGAsync/Fedora_27/src/megasync-${PV}-${RELEASE}.src.rpm"
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="~amd64 ~x86"
-
-RESTRICT="mirror"
-
-IUSE="+api chat +curl debug doc dot examples +inotify java libressl +libuv pcre
-php python static-libs +sync tests +tools +threads"
-
-REQUIRED_USE="
- sync? ( !java !php !python )
- dot? ( doc )
-"
-
-RDEPEND="
- dev-db/sqlite:3
- dev-libs/crypto++
- dev-libs/libsodium
- dev-qt/qtsvg:5
- dev-qt/qtwidgets:5
- dev-qt/qtgui:5
- dev-qt/qtnetwork:5
- dev-qt/qtdbus:5
- dev-qt/qtcore:5
- media-libs/freeimage
- media-libs/libpng:0
- net-dns/c-ares
- x11-themes/hicolor-icon-theme
- sys-libs/readline:0
- curl? ( net-misc/curl )
- libressl? ( dev-libs/libressl )
- !libressl? ( dev-libs/openssl:0 )
- libuv? ( dev-libs/libuv )
- pcre? ( dev-libs/libpcre )
- php? ( dev-lang/php:* )
- tests? ( dev-cpp/gtest )
-"
-
-DEPEND="
- ${RDEPEND}
- sys-devel/binutils
- doc? ( app-doc/doxygen[dot=] )
-"
-
-PATCHES=(
- "${FILESDIR}"/${P}-enable_install_target.patch
- "${FILESDIR}"/${P}-adapt_distro_version.patch
-)
-
-DOCS=(
- MEGASync/mega/CREDITS.md
- MEGASync/mega/LICENSE
- MEGASync/mega/README.md
-)
-
-src_prepare() {
- default
-
- # We then have to prepare the SDK
- pushd "MEGASync/mega" > /dev/null || die
- eautoreconf
- popd > /dev/null || die
-
- # Now build the translations
- $(qt5_get_bindir)/lrelease MEGASync/MEGASync.pro || die "lrelease failed"
-}
-
-src_configure() {
- # We have to prepare the SDK first
- pushd "MEGASync/mega" > /dev/null || die
- econf \
- $(use_enable static-libs) \
- $(use_enable debug) \
- $(use_enable inotify) \
- $(usex !threads --disable-posix-threads "") \
- $(use_enable sync) \
- $(usex !api --disable-megaapi "") \
- $(use_enable java) \
- $(use_enable chat) \
- $(use_enable curl curl-checks) \
- $(use_enable examples) \
- $(use_enable tools megacmd) \
- $(use_enable tests) \
- $(use_enable python) \
- $(use_enable php) \
- $(use_enable doc doxygen-doc) \
- $(use_enable dot doxygen-dot) \
- --disable-doxygen-ps \
- $(use_with java java-include-dir "$(java-config -g JAVA_HOME)/include") \
- $(use_with libuv libuv "${EPREFIX}/usr/$(get_libdir)") \
- $(use_with pcre pcre "${EPREFIX}/usr/$(get_libdir)") \
- $(use_with python python3)
-
- popd > /dev/null || die
-
- # Now the global configuration can take place
- eqmake5 \
- CONFIG+=$(usex debug debug release) \
- $(usex tools CONFIG+=with_tools "") \
- $(usex pcre QMAKE_LFLAGS+="$(pkg-config --libs libpcre)" "") \
- DEFINES+=no_desktop \
- -recursive MEGA.pro
-}
-
-src_compile() {
- # We have to build the SDK first
- pushd "MEGASync/mega" > /dev/null || die
- emake
- popd > /dev/null || die
-
- default
-}
-
-src_install() {
- # We have to install the SDK first
- pushd "MEGASync/mega" > /dev/null || die
- emake DESTDIR="${D}" install
- popd > /dev/null || die
-
- emake INSTALL_ROOT="${D}" install
-
- # Install desktop file
- insinto /usr/share/applications
- doins "${S}"/MEGASync/platform/linux/data/megasync.desktop
-
- # Install icons
- local s SIZES=(16 32 48 128 256)
- local p="${S}"/MEGASync/platform/linux/data/icons/hicolor
- for s in "${SIZES[@]}"; do
- doicon -s $s ${p}/${s}x${s}/apps/mega.png
- done
- local v STATUS=(synching warning paused logging uptodate)
- p="${S}"/MEGASync/gui/images
- for v in "${STATUS[@]}"; do
- newicon -s scalable -c status ${p}/${v}.svg mega${v}.svg
- done
-
- einstalldocs
-}
-
-pkg_postinst() {
- gnome2_icon_cache_update
-}
-
-pkg_postrm() {
- gnome2_icon_cache_update
-}
diff --git a/net-misc/megasync/megasync-3.7.1.ebuild b/net-misc/megasync/megasync-3.7.1.ebuild
new file mode 100644
index 0000000..84a2c7e
--- /dev/null
+++ b/net-misc/megasync/megasync-3.7.1.ebuild
@@ -0,0 +1,225 @@
+# Copyright 1999-2018 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+inherit autotools eutils gnome2-utils qmake-utils rpm xdg-utils
+
+DESCRIPTION="Easy automated syncing between your computers and your MEGA cloud drive"
+HOMEPAGE="http://mega.co.nz"
+
+RELEASE="1"
+
+BASE_URL=""
+
+SRC_URI="https://mega.nz/linux/MEGAsync/Fedora_29/src/megasync-${PV}-${RELEASE}.src.rpm"
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+RESTRICT="mirror"
+
+IUSE="+api chat +curl debug doc dot examples +ffmpeg +inotify java +libmediainfo
+ libressl +libuv +libraw +libsodium pcre php python +sync tests +tools +threads"
+
+REQUIRED_USE="
+ dot? ( doc )
+ libmediainfo? ( threads )
+ sync? ( !java !php !python )
+"
+
+RDEPEND="
+ dev-db/sqlite:3
+ dev-libs/crypto++
+ dev-qt/qtsvg:5
+ dev-qt/qtwidgets:5
+ dev-qt/qtgui:5
+ dev-qt/qtnetwork:5
+ dev-qt/qtdbus:5
+ dev-qt/qtcore:5
+ media-libs/freeimage
+ media-libs/libpng:0
+ net-dns/c-ares
+ x11-themes/hicolor-icon-theme
+ sys-libs/readline:=
+ curl? ( net-misc/curl )
+ ffmpeg? ( virtual/ffmpeg )
+ libmediainfo? (
+ media-libs/libmediainfo
+ media-libs/libzen
+ )
+ libressl? ( dev-libs/libressl:0 )
+ !libressl? ( dev-libs/openssl:0 )
+ libraw? ( media-libs/libraw:0 )
+ libsodium? ( dev-libs/libsodium:0 )
+ libuv? ( dev-libs/libuv:0 )
+ pcre? ( dev-libs/libpcre )
+ php? ( dev-lang/php:* )
+ tests? ( dev-cpp/gtest )
+"
+
+DEPEND="
+ ${RDEPEND}
+ sys-devel/binutils
+ doc? ( app-doc/doxygen[dot=] )
+"
+
+PATCHES=(
+ "${FILESDIR}"/${P}-enable_install_target.patch
+ "${FILESDIR}"/${P}-adapt_distro_version.patch
+ "${FILESDIR}"/${P}-fix_strict_aliasing.patch
+)
+
+DOCS=(
+ MEGASync/mega/CREDITS.md
+ MEGASync/mega/LICENSE
+ MEGASync/mega/README.md
+)
+
+src_prepare() {
+ default
+
+ # Some options, although configurable in the configure script, are hard-
+ # coded in the MEGASync.pro file. Stupid thing to do, really...
+ if ! use ffmpeg; then
+ sed -i \
+ -e '/CONFIG.*USE_FFMPEG/ s/^/#/' \
+ -e '/DEFINES.*REQUIRE_HAVE_FFMPEG/ s/^/#/' \
+ MEGASync/MEGASync.pro || die "FFMPEG disabling failed"
+ fi
+ if ! use libmediainfo; then
+ sed -i \
+ -e '/CONFIG.*USE_MEDIAINFO/ s/^/#/' \
+ -e '/DEFINES.*REQUIRE_USE_MEDIAINFO/ s/^/#/' \
+ MEGASync/MEGASync.pro || die "MEDIAINFO disabling failed"
+ fi
+ if ! use libraw; then
+ sed -i \
+ -e '/CONFIG.*USE_LIBRAW/ s/^/#/' \
+ -e '/DEFINES.*REQUIRE_HAVE_LIBRAW/ s/^/#/' \
+ MEGASync/MEGASync.pro || die "LIBRAW disabling failed"
+ fi
+ if ! use libuv; then
+ sed -i \
+ -e '/CONFIG.*USE_LIBUV/ s/^/#/' \
+ -e '/DEFINES.*REQUIRE_HAVE_LIBUV/ s/^/#/' \
+ MEGASync/MEGASync.pro || die "LIBUV disabling failed"
+ fi
+
+ # We then have to prepare the SDK
+ pushd "MEGASync/mega" > /dev/null || die
+ eautoreconf
+ popd > /dev/null || die
+
+ # Now build the translations
+ $(qt5_get_bindir)/lrelease MEGASync/MEGASync.pro || die "lrelease failed"
+}
+
+src_configure() {
+ # First configure the SDK
+ pushd "MEGASync/mega" > /dev/null || die
+ econf \
+ $(use_enable debug) \
+ $(use_enable inotify) \
+ $(usex !threads --disable-posix-threads "") \
+ $(use_enable sync) \
+ $(usex !api --disable-megaapi "") \
+ $(use_enable java) \
+ $(use_enable chat) \
+ $(use_enable curl curl-checks) \
+ $(use_enable examples) \
+ $(use_enable tests) \
+ $(use_enable python) \
+ $(use_enable php) \
+ $(use_enable doc doxygen-doc) \
+ $(use_enable dot doxygen-dot) \
+ --disable-doxygen-ps \
+ $(use_with ffmpeg ffmpeg "${EPREFIX}/usr/$(get_libdir)") \
+ $(use_with java java-include-dir "$(java-config -g JAVA_HOME)/include") \
+ $(use_with libuv libuv "${EPREFIX}/usr/$(get_libdir)") \
+ $(use_with libmediainfo libmediainfo "${EPREFIX}/usr/$(get_libdir)") \
+ $(use_with libmediainfo libzen "${EPREFIX}/usr/$(get_libdir)") \
+ $(use_with libraw libraw "${EPREFIX}/usr/$(get_libdir)") \
+ $(use_with libsodium sodium "${EPREFIX}/usr/$(get_libdir)") \
+ $(use_with pcre pcre "${EPREFIX}/usr/$(get_libdir)") \
+ $(use_with python python3) \
+ || die "SDK configure failed"
+ popd > /dev/null || die
+
+ # Now the global configuration can take place
+ eqmake5 \
+ CONFIG+=$(usex debug debug release) \
+ $(usex tools CONFIG+=with_tools "") \
+ $(usex pcre QMAKE_LFLAGS+="$(pkg-config --libs libpcre)" "") \
+ $(usex ffmpeg CONFIG+=USE_FFMPEG "") \
+ $(usex libmediainfo CONFIG+=USE_MEDIAINFO "") \
+ $(usex libraw CONFIG+=USE_LIBRAW "") \
+ $(usex libuv CONFIG+=USE_LIBUV "") \
+ DEFINES+=no_desktop \
+ -recursive MEGA.pro || die "qmake failed"
+}
+
+src_compile() {
+ # We have to build the SDK first
+ pushd "MEGASync/mega" > /dev/null || die
+ emake
+ popd > /dev/null || die
+
+ default
+}
+
+pkg_preinst() {
+ gnome2_icon_savelist
+}
+
+src_install() {
+ # We have to install the SDK first
+ pushd "MEGASync/mega" > /dev/null || die
+ emake DESTDIR="${D}" install
+ popd > /dev/null || die
+
+ emake INSTALL_ROOT="${D}" install
+
+ # The tools must be installed manually, as the build system isn't meant
+ # to do that automatically.
+ if use tools; then
+ dobin MEGASync/mega/contrib/QtCreator/MEGACli/MEGAcli
+ dobin MEGASync/mega/contrib/QtCreator/MEGASimplesync/MEGAsimplesync
+ fi
+
+ # Install desktop file
+ insinto /usr/share/applications
+ doins "${S}"/MEGASync/platform/linux/data/megasync.desktop
+
+ # Install icons
+ local s SIZES=(16 32 48 128 256)
+ local p="${S}"/MEGASync/platform/linux/data/icons/hicolor
+ for s in "${SIZES[@]}"; do
+ doicon -s $s ${p}/${s}x${s}/apps/mega.png
+ done
+ local v STATUS=(synching warning paused logging uptodate)
+ p="${S}"/MEGASync/gui/images
+ for v in "${STATUS[@]}"; do
+ newicon -s scalable -c status ${p}/${v}.svg mega${v}.svg
+ done
+
+ einstalldocs
+
+ # Remove unwanted .la files
+ find "${ED}"/ -name '*.la' -delete || die
+
+ # The build system adds some unneeded files (distro, version)
+ # in an unwanted directory.
+ rm -rf "${ED}"/usr/share/doc/${PN}
+}
+
+pkg_postinst() {
+ gnome2_icon_cache_update
+ xdg_desktop_database_update
+ xdg_mimeinfo_database_update
+}
+
+pkg_postrm() {
+ gnome2_icon_cache_update
+ xdg_desktop_database_update
+ xdg_mimeinfo_database_update
+}
diff --git a/net-misc/megasync/metadata.xml b/net-misc/megasync/metadata.xml
index 39b0bc2..8b0faee 100644
--- a/net-misc/megasync/metadata.xml
+++ b/net-misc/megasync/metadata.xml
@@ -22,18 +22,27 @@ you hold the keys, and you decide who you grant or deny access to your files.
<flag name="curl">Enable cURL checks</flag>
<flag name="doc">Generate doxygen documentation</flag>
<flag name="dot">Generate graphics for doxygen documentation</flag>
- <flag name="examples">Build example applications</flag>
+ <flag name="examples">Build example applications like 'megacmd'.</flag>
<flag name="inotify">Enable inotify support</flag>
<flag name="java">Build Java language bindings</flag>
+ <flag name="libmediainfo">
+ Use media-libs/libmediainfo via media-libs/libzen to analyse media files
+ (video, audio) and set file attributes on them to assist the web interface
+ in playing them.
+ </flag>
+ <flag name="libraw">Use media-libs/libraw for reading RAW files</flag>
<flag name="libressl">Use libressl instead of openssl</flag>
+ <flag name="libsodium">Use dev-libs/libsodium for cryptography</flag>
<flag name="libuv">Enable asynchronous I/O using libuv</flag>
<flag name="pcre">Enable support for libpcre</flag>
<flag name="php">Build PHP language bindings</flag>
<flag name="python">Build Python language bindings</flag>
- <flag name="static-libs"></flag>
<flag name="sync">Include sync subsystem</flag>
<flag name="tests">Build test applications</flag>
- <flag name="tools">Build tools like megacmd</flag>
+ <flag name="tools">
+ Build the optional tools MEGACli and MEGASimplesync.
+ Note: megacmd is now an 'example' application!
+ </flag>
<flag name="threads">Enable multi-threading</flag>
</use>
</pkgmetadata>