# Note: this is spidermonkey version 1.8.5 (old), for a recent version see spidermonkey

# Note: depends on zip
# Note: depends on perl
# Note: depends on Python2
wget -c http://ftp.mozilla.org/pub/mozilla.org/js/js185-1.0.0.tar.gz
tar -xzf js185-1.0.0.tar.gz
cd js-1.8.5
sed -i -e 's/^Requires:.*/Requires:/' js/src/mozjs185.pc.in # Doesn't actually require nspr
mkdir -p build
cd build
../js/src/configure --prefix="/usr"
make # Doesn't mind -j#
make install