arso-project / sonar

A p2p content database and search engine
https://sonar.arso.xyz/
GNU General Public License v3.0
121 stars 6 forks source link

Document requirements for installing sonar (for native modules) #63

Open nemi-notrace opened 3 years ago

nemi-notrace commented 3 years ago

Running a fresh installed Linux Mint 20 or an Ubuntu 20.04 needs additional packages to get sonar to run.

After installing nvm, node and dat, I tried sonar. On both Mint and Ubuntu you have first to install git. sudo apt install git then I tried to run npm install -g @arso-project/sonar-server again. It still fails here are the last lines from the log:

9814 verbose npm  v6.14.8
9815 error code ELIFECYCLE
9816 error errno 1
9817 error sodium-native@2.4.9 install: node-gyp-build "node preinstall.js" "node postinstall.js"
9817 error Exit status 1
9818 error Failed at the sodium-native@2.4.9 install script.
9818 error This is probably not a problem with npm. There is likely additional logging output above.
9819 verbose exit [ 1, true ]

to get it run I had to install libtool and the build-essential:

sudo apt install build-essential
sudo apt install libtool

after this I could install sonar.

I'm not sure why but I think that you need libtool for the script stuff from sodium-native@2.4.9 and the g++ compiler from build-essential to compile some stuff which the script is calling.

Frando commented 3 years ago

Yup, we should document this somewhere.