Also if you have
This needs to be removed.
the steps are the same
git clone https://github.com/esp8266/Arduino.git esp8266 cd esp8266/tools python get.py
then you have all you need to build a binary for the ESP
So on Linux you just follow crosstool-ng manual and do something like
./bootstrap && ./configure --prefix=`pwd` && make && make install ./ct-ng xtensa-lx106-elf ./ct-ng build
After that the toolchain will be inside builds/xtensa-lx106-elf directory