About porting MEGASync

shuryanc

Member

Reaction score: 5
Messages: 20

Hi Community,

I want to try porting the latest version of MEGASync to FreeBSD (I know kqueue is needed).
So I start from compiling the source code but stucked in some steps.
My question is, may I know if anyone had successfully compiled the latest version of MEGASync?
1617782780956.png
 

eternal_noob

Well-Known Member

Reaction score: 180
Messages: 339

I want to try porting the latest version of MEGASync to FreeBSD
But the shell prompt suggests you are using GhostBSD.

 
OP
S

shuryanc

Member

Reaction score: 5
Messages: 20

But the shell prompt suggests you are using GhostBSD.

From what I know, their base is the same (e.g. GhostBSD is adopting the Kernel from FreeBSD). GhostBSD tries to make FreeBSD to be easy to use. Could you provide some advise based on FreeBSD?
 

Menelkir

Member

Reaction score: 58
Messages: 82

Maybe creating a port for that will be better? Since you can deal with patches, path and all the stuff directly into the port Makefile instead of modifying megasync source tree.
 

Zirias

Daemon

Reaction score: 1,051
Messages: 1,892

autoreconf will just attempt to re-generate the configure script from configure.ac, assuming this code indeed uses GNU autotools.

But I agree, it's probably easier to start with creating a port right away. There's a helpful USES=autoreconf to handle that kind of breakage automatically.
 

Menelkir

Member

Reaction score: 58
Messages: 82

Here´s a Makefile that I´ve started, but I had too many chimichangas that i´ve stopped worked on it. At last you have the deps and everything else. It´ll need more things to be done (in the case of megasync, you´ll need the Makefile.freebsd) Change it to suit your needs.

Makefile:
# $FreeBSD$

PORTNAME=    megasync
DISTVERSION=    v4.4.0.0
DISTVERSIONSUFFIX=    _Linux
CATEGORIES=    net

MAINTAINER=    menelkir@itroll.org
COMMENT=    MEGA Cloud Drive client

LICENSE=    MEGA
LICENSE_NAME=   MEGA
LICENSE_FILE=    ${WRKSRC}/LICENCE.md
LICENSE_PERMS=  no-dist-sell

LIB_DEPENDS=    libcares.so:dns/c-ares \
        libcryptopp.so:security/cryptopp \
        libsodium.so:security/libsodium \
        libuv.so:devel/libuv \
        libQt5Svg.so:graphics/qt5-svg \
        libQt5X11Extras.so:x11/qt5-x11extras \
        libmediainfo.so:multimedia/libmediainfo \
        libraw.so:graphics/libraw \
        libpcre.so:devel/pcre

USES=        libtool sqlite:3 readline shebangfix ssl qmake qt:5

NO_CDROM=       Commercial users must seek permission from copyright holders.

USE_GITHUB=    yes
GH_ACCOUNT=    meganz
GH_PROJECT=    MEGAsync sdk:sdk
GH_SUBDIR=    sdk:sdk
GH_TAGNAME=    v3.7.3c:sdk

USE_LDCONFIG=    yes

MAKEFILE=    Makefile.freebsd

INSTALL_TARGET=    install-strip

SHEBANG_FILES=    src/configure

CXXFLAGS+=    `pkgconf --cflags-only-other libcryptopp`

.include <bsd.port.mk>
 

Misirca

New Member

Reaction score: 4
Messages: 14

Unless you want some specific functionality with MEGAsync, remember rclone can mount and sync MEGA folders as well ;)
 

Menelkir

Member

Reaction score: 58
Messages: 82

Unless you want some specific functionality with MEGAsync, remember rclone can mount and sync MEGA folders as well ;)
Doesn´t work as expected for mega, it works at some point but there´s many other issues like timeout, lag, etc. Being there, done that.
Actually the best choices for sync with mega is:
net/megatools : Works fine, but have some issues like lag and you don´t have a proper daemon for that (you can use a cron and a script, of course).
net/megacmd : It´s the official mega solution, works exactly the same but without a fancy GUI like megasync. There´s a daemon that runs in background. Have is own issues like lag in different scenarios, etc.
 
Last edited:
Top