meganz / MEGAcmd

Command Line Interactive and Scriptable Application to access MEGA
Other
1.94k stars 407 forks source link

Cannot build binary for Synology NAS #777

Open BlackRose01 opened 1 year ago

BlackRose01 commented 1 year ago

Hello,

since there are no ready-made binaries for NAS systems available for this project, I wanted to build it by myself. I followed the given instructions, but I get the same error all the time. The log files are attached.

This is the error message in short:

I got the following error:
======  Find pattern [Error] ======
1126: src/megaclient.cpp: In member function 'void mega::MegaClient::importSyncConfigs(const char*, std::function<void(mega::ErrorCodes)>)':
1128: [completion = std::move(completion), configs, this](Error result)
1240: [Error] Build project fail!

Could anybody help me, please?

Thanks in advance!

KR


System (virtualized): Ubuntu 16.04 LTS 64-bit/Ubuntu 18.04 LTS 64-bit CPU: AMD Ryzen 7 Pro 5850U 1,9 GHz RAM: 8 GB

How I set up the system

sudo su
apt update
apt dist-upgrade
apt autoremove

cd /root

Start ONLY IN 16.04

apt install build-essential zlib1g-dev libncurses5-dev libgdbm-dev libnss3-dev libssl-dev libreadline-dev libffi-dev libsqlite3-dev wget libbz2-dev
wget https://www.python.org/ftp/python/3.8.0/Python-3.8.0.tgz
tar -xf Python-3.8.0.tgz
cd Python-3.8.0
./configure --enable-optimizations
make -j 8
sudo make altinstall

apt install autoconf libtool g++ libcrypto++-dev libz-dev libsqlite3-dev libssl-dev libcurl4-openssl-dev libreadline-dev libpcre++-dev libsodium-dev libc-ares-dev libfreeimage-dev libavcodec-dev libavutil-dev libavformat-dev libswscale-dev libmediainfo-dev libzen-dev

End ONLY IN 16.04 Start ONLY IN 18.04

apt install autoconf libtool g++ libcrypto++-dev libz-dev libsqlite3-dev libssl-dev libcurl4-gnutls-dev libreadline-dev libpcre++-dev libsodium-dev libc-ares-dev libfreeimage-dev libavcodec-dev libavutil-dev libavformat-dev libswscale-dev libmediainfo-dev libzen-dev libuv1-dev

End ONLY IN 18.04

git clone https://github.com/meganz/MEGAcmd.git
cd MEGAcmd && git submodule update --init --recursive

cp -r MEGAcmd/build/SynologyNAS/toolkit /
cd /toolkit
cp -r /root/MEGAcmd /toolkit/source/MEGAcmd/
git clone --branch DSM7.1 --single-branch https://github.com/SynologyOpenSource/pkgscripts-ng
./pkgscripts-ng/EnvDeploy -v 7.1 -p apollolake
nano ./source/MEGAcmd/SynoBuildConf/depends (changed to 7.1)
./pkgscripts-ng/PkgCreate.py MEGAcmd

Log Files

logs.build.txt MEGAcmd.build.txt mybuildlogs-sdkbuild.out.txt

polmr commented 1 year ago

Newer releases of MEGAcmd for NAS (Synology/QNAP) featuring several improvements and fixes, can now be downloaded from here: https://mega.io/nas. Note: Non English version website may still show old links to QNAP/Synology stores. If that is your case, please, temporarily switch to English (upper world icon with your locale initials).