Installing Leafnode using Linuxbrew
Leafnode is an NNTP proxy news server which you can use to quite conveniently keep your un/read status synced over several newsreaders on different devices.
You can install Leafnode on your uberspace using linuxbrew, which is a fork of the well-known homebrew for mac.
Installing linuxbrew
The uberspace-wiki already holds most of the steps neccessary to install linuxbrew, i.e.:
$ git clone https://github.com/Homebrew/linuxbrew.git ~/.linuxbrew $ echo "PATH=\"$HOME/.linuxbrew/bin:$PATH\"" >> ~/.bashrc $ echo "MANPATH=\"$HOME/.linuxbrew/share/man:$MANPATH\"" >> ~/.bashrc $ echo "INFOPATH=\"$HOME/.linuxbrew/share/info:$INFOPATH\"" >> ~/.bashrc
Do not forget to source your .bashrc-file or just logout and login again.
Installing Leafnode version 1.11.10
does NOT run on uberspace, though. Install Leafnode-2 instead!
So far, so good, but if you want to install leafnode, it will throw the following error-msg at you:
$ brew install leafnode ==> Installing dependencies for leafnode: bzip2, pcre ==> Installing leafnode dependency: bzip2 Error: bzip2 cannot be built with any available compilers. To install this formula, you may need to: brew install gcc
This leads to a kind of recursive situation, though:
$ brew install gcc ==> Installing dependencies for gcc: gmp, mpfr, libmpc, isl, cloog ==> Installing gcc dependency: gmp Error: gmp cannot be built with any available compilers. To install this formula, you may need to: brew install gcc
Luckily, i was not the first one encountering this problem, so the solution was already there - you have to add a symlink in your .linuxbrew-directory to your gcc/g++ compiler:
$ ln -s `which gcc` ~/.linuxbrew/bin/gcc-`gcc -dumpversion |cut -d. -f1,2` $ ln -s `which g++` ~/.linuxbrew/bin/g++-`g++ -dumpversion |cut -d. -f1,2`
Having done this, you can install leafnode without any further problems:
$ brew install leafnode ==> Installing dependencies for leafnode: bzip2, pcre ==> Installing leafnode dependency: bzip2 ==> Downloading http://www.bzip.org/1.0.6/bzip2-1.0.6.tar.gz ######################################################################## 100.0% ==> make install PREFIX=/home/USER/.linuxbrew/Cellar/bzip2/1.0.6 ==> make -f Makefile-libbz2_so clean ==> make -f Makefile-libbz2_so /home/USER/.linuxbrew/Cellar/bzip2/1.0.6: 22 files, 1.3M, built in 5 seconds ==> Installing leafnode dependency: pcre ==> Downloading https://ftp.csx.cam.ac.uk/pub/software/programming/pcre/pcre-8.37.tar.bz2 ######################################################################## 100.0% ==> ./configure --prefix=/home/USER/.linuxbrew/Cellar/pcre/8.37 --enable-utf8 --enable-pcre8 --enable-pcre16 --ena ==> make ==> make test ==> make install /home/USER/.linuxbrew/Cellar/pcre/8.37: 146 files, 5.6M, built in 45 seconds ==> Installing leafnode ==> Downloading https://downloads.sourceforge.net/project/leafnode/leafnode/1.11.10/leafnode-1.11.10.tar.bz2 ######################################################################## 100.0% ==> ./configure --prefix=/home/hosted/.linuxbrew/Cellar/leafnode/1.11.10 ==> make install /home/USER/.linuxbrew/Cellar/leafnode/1.11.10: 27 files, 820K, built in 10 seconds
Next step is to configure it properly.
Note:
You might encounter the following, GitHub related, error:
$ brew search git git Error: GitHub API rate limit exceeded for x.x.x.x. (But here's the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.) Try again in 40 minutes 22 seconds, or create an personal access token: https://github.com/settings/tokens and then set it as HOMEBREW_GITHUB_API_TOKEN.
To fix this, create your GitHub API token (you need to have an GitHub account for that) and add the following line to your ~/.linuxbrew/bin/brew file:
#!/bin/sh
export HOMEBREW_GITHUB_API_TOKEN=xxx