1) Mercurial version control. (Hg)
2) autoconf2.13 ( I installed it from synaptic package manager. It is the easier way)
Here is the step for the installation:
1) Get the spidermonkey source code.
Just copy this in your terminal:
hg clone http://hg.mozilla.org/mozilla-central/
the source code will be downloaded to the folder ‘mozilla-central’.