1
0
forked from mirrors/0ad
Files
0ad/libraries/source/spidermonkey/build.sh
T
Ralph Sennhauser 26994b156b Split source package downloads
Instead of fetching the whole svn repo containing all current
dependencies into source, fetch them individually into subdirectories of
source.

Adds a wrapper script to each package to place the build output where
it's currently expected.

This allows adding and removing dependencies as well as changing origin
of those packages on a case by case basis.

It's recommended to run "git clean -dxf libraries/source" to free up
extra space and remove untracked files no longer covered by changes in
.gitignore.

Signed-off-by: Ralph Sennhauser <ralph.sennhauser@gmail.com>
2024-09-08 22:17:08 +02:00

35 lines
741 B
Bash
Executable File

#!/bin/sh
set -e
cd "$(dirname "$0")"
LIB_VERSION=28209
if [ -e .already-built ] && [ "$(cat .already-built)" = "${LIB_VERSION}" ]; then
echo "Spidermonkey is already up to date."
exit
fi
# fetch
svn co "https://svn.wildfiregames.com/public/source-libs/trunk/spidermonkey@${LIB_VERSION}" spidermonkey-svn
# unpack
rm -Rf spidermonkey-build
cp -R spidermonkey-svn spidermonkey-build
# build
(
cd spidermonkey-build
mkdir bin lib
./build.sh
)
# install
rm -Rf bin include-unix-debug include-unix-release lib
cp -R spidermonkey-build/bin spidermonkey-build/include-unix-release spidermonkey-build/lib .
if [ "$(uname -s)" != "FreeBSD" ]; then
cp -R spidermonkey-build/include-unix-debug .
fi
echo "${LIB_VERSION}" >.already-built