View Single Post
Posts: 11 | Thanked: 7 times | Joined on May 2010
#1
Installing Diaspora on the Nokia N900:

The following guide is something I threw together in an afternoon whilst tinkering with my N900, which is currently the only device I own that has hardware which resembles that of a SheevaPlug or GuruPlug, on which I do intend to run as a Diaspora node full time when I get around to purchasing one. So the following is a result of me getting my feat wet before taking the dive, so to speak.

The steps below are broken up into the sections taken from: http://github.com/diaspora/diaspora/...nning-Diaspora
Simply so I could keep track of where I was.

Unfortunately, and this is something to absolutely keep in mind, as it currently stands this guide will NOT (yet) get you to the point of having a working Disapora node on your N900, this is due to the lack of ARM support offered currently by MongoDB.

So, my motivation for sharing this information is with the hopes of getting the fantastic community here on board to work this one out.

A little disclaimer before we begin:

!! BACK UP ALL DATA ON YOUR DEVICE BEFORE PERFORMING THE FOLLOWING !!
!! I AM NOT TO BE HELD RESPONSIBLE OR ACCOUNTABLE FOR ANY DAMAGE TO YOUR DEVICE OR LOSS OFF DATA !!
!! FOLLOW THE GUIDE BELOW AT YOUR OWN RISK !!


Getting to where I did was quite tricky, as there are many dependencies that need to be installed on your device. Most of which are from source, so while I'll try to make this as 'n00b' friendly as I can, if you don't fully know what you're doing the following isn't really where you should be cutting your teeth on such things. So just a friendly warning for all before we finally begin.

Now briefly the following is a list of some software you will need to have installed on your device:
wget, gnu-grep and others that will be covered in this guide.

(optionally you may also want to consider running an ssh server on your device, this will make inputting the following commands a lot easier. Unless, of course, you are literally that comfortable navigating the N900's QWERTY keyboard, and in which case I tip my hat to you!)

For the SSH peeps:
Code:
ssh root@YOUR-PHONE-IP
password: (you'll need to remember the password you set when installing the ssh server)
Preparing your System:

First things first, the following command will need to be run, which will basically move the /tmp directory onto your SDCard. Without this being set later on you will most likely run into errors whilst compiling where your /tmp drive runs out of space.
Code:
mkdir /media/mmc1/tmp
mount /media/mmc1/tmp /tmp
Build Tools

Code:
nano /etc/apt/sources.list.d/external_repos.list

#Dev Tools
deb http://repository.maemo.org/ fremantle sdk/free sdk/non-free tools/free tools/non-free
deb-src http://repository.maemo.org/ fremantle sdk/free sdk/non-free tools/free tools/non-free

apt-get update (ran twice)
apt-get install build-essential libxslt1.1 libxslt1-dev libxml2 (if this throws an error try --fix-missing)
Ruby

Code:
apt-get install ruby-full
completed without a hitch, nice!

MongoDB

Code:
cd /home/user
mkdir src
cd src
Now get all the source files needed to compile MongoDB:
Begin by installing scons:
Code:
tar xzf scons-2.0.1.tar.gz
cd scons-2.0.1
python setup.py install
Done with the above? Ok now lets compile pcre:
Code:
tar xzf pcre-8.10.tar.gz
cd pcre-8.10
sh ./configure; make; make install
Compiling will take some time, so at this point go fetch yourself a beverage, you've earned it.

a few more dependencies to take care of...
Code:
apt-get -y install libboost-dev libreadline5-dev
Building Spider Monkey:
Code:
wget ftp://ftp.mozilla.org/pub/mozilla.or...s-1.7.0.tar.gz
tar zxf js-1.7.0.tar.gz
cd js/src
export CFLAGS="-DJS_C_STRINGS_ARE_UTF8"
make -f Makefile.ref
JS_DIST=/usr make -f Makefile.ref export

Finally, lets compile mondodb:
Code:
tar xzf mongodb-src-r1.6.3.tar.gz
cd mongodb-src-r1.6.3
scons
This is, unfortunately, where the show comes to an end.
You'll receive an error:
Code:
db/../bson/util/atomic_int.h:96:4: error: #error "unsupported compiler or platform"
and at this point, this is where we'll leave it.

But in case progress is made I'll maintain this post. Updating it with useful links and information. Hopefully before too long we'll actually see this thing working!

I look forward to hearing everyones thoughts on this topic.
 

The Following 3 Users Say Thank You to joshgillies For This Useful Post: