Here’s how to quickly and easily build spidermonkey-bin from source on Ubuntu Linux.
sudo apt-get install mercurial autoconf2.13 hg clone http://hg.mozilla.org/mozilla-central spidermonkey cd spidermonkey/js/src autoconf2.13 ./configure make sudo make install
Enjoy!