Format shell scripts using shfmt
This updates shell scripts to use a consistent style that can be enforced via pre-commit hook. As for choosing tabs over spaces, some arguments are: - tabs can help people with visual impairment - tabs allow for indenting heredocs in bash - tabs are the default for the tool shfmt Signed-off-by: Ralph Sennhauser <ralph.sennhauser@gmail.com>
This commit is contained in:
parent
c763c010b8
commit
abdda50892
@ -28,143 +28,142 @@ mkdir -p files
|
|||||||
pushd files
|
pushd files
|
||||||
|
|
||||||
if [ ! -e boost_1_45_0.tar.bz2 ]; then
|
if [ ! -e boost_1_45_0.tar.bz2 ]; then
|
||||||
wget http://downloads.sourceforge.net/project/boost/boost/1.45.0/boost_1_45_0.tar.bz2
|
wget http://downloads.sourceforge.net/project/boost/boost/1.45.0/boost_1_45_0.tar.bz2
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -e curl-7.33.0.tar.bz2 ]; then
|
if [ ! -e curl-7.33.0.tar.bz2 ]; then
|
||||||
wget http://curl.haxx.se/download/curl-7.33.0.tar.bz2
|
wget http://curl.haxx.se/download/curl-7.33.0.tar.bz2
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -e MysticTreeGames-Boost-for-Android-70838fc.tar.gz ]; then
|
if [ ! -e MysticTreeGames-Boost-for-Android-70838fc.tar.gz ]; then
|
||||||
wget https://github.com/MysticTreeGames/Boost-for-Android/tarball/70838fcfba930646cac724a77f5c626e930431f6 -O MysticTreeGames-Boost-for-Android-70838fc.tar.gz
|
wget https://github.com/MysticTreeGames/Boost-for-Android/tarball/70838fcfba930646cac724a77f5c626e930431f6 -O MysticTreeGames-Boost-for-Android-70838fc.tar.gz
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -e enet-1.3.3.tar.gz ]; then
|
if [ ! -e enet-1.3.3.tar.gz ]; then
|
||||||
wget http://enet.bespin.org/download/enet-1.3.3.tar.gz
|
wget http://enet.bespin.org/download/enet-1.3.3.tar.gz
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -e js185-1.0.0.tar.gz ]; then
|
if [ ! -e js185-1.0.0.tar.gz ]; then
|
||||||
cp ../../../libraries/source/spidermonkey/js185-1.0.0.tar.gz .
|
cp ../../../libraries/source/spidermonkey/js185-1.0.0.tar.gz .
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -e libjpeg-turbo-1.3.0.tar.gz ]; then
|
if [ ! -e libjpeg-turbo-1.3.0.tar.gz ]; then
|
||||||
wget http://downloads.sourceforge.net/project/libjpeg-turbo/1.3.0/libjpeg-turbo-1.3.0.tar.gz
|
wget http://downloads.sourceforge.net/project/libjpeg-turbo/1.3.0/libjpeg-turbo-1.3.0.tar.gz
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -e libpng-1.5.8.tar.xz ]; then
|
if [ ! -e libpng-1.5.8.tar.xz ]; then
|
||||||
wget http://prdownloads.sourceforge.net/libpng/libpng-1.5.8.tar.xz
|
wget http://prdownloads.sourceforge.net/libpng/libpng-1.5.8.tar.xz
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -e libxml2-2.7.8.tar.gz ]; then
|
if [ ! -e libxml2-2.7.8.tar.gz ]; then
|
||||||
wget ftp://xmlsoft.org/libxml2/libxml2-2.7.8.tar.gz
|
wget ftp://xmlsoft.org/libxml2/libxml2-2.7.8.tar.gz
|
||||||
fi
|
fi
|
||||||
|
|
||||||
popd
|
popd
|
||||||
|
|
||||||
|
|
||||||
if [ "$build_toolchain" = "true" ]; then
|
if [ "$build_toolchain" = "true" ]; then
|
||||||
|
|
||||||
rm -r $TOOLCHAIN || true
|
rm -r $TOOLCHAIN || true
|
||||||
$NDK/build/tools/make-standalone-toolchain.sh --platform=android-14 --toolchain=arm-linux-androideabi-4.6 --install-dir=$TOOLCHAIN --system=linux-x86_64
|
$NDK/build/tools/make-standalone-toolchain.sh --platform=android-14 --toolchain=arm-linux-androideabi-4.6 --install-dir=$TOOLCHAIN --system=linux-x86_64
|
||||||
|
|
||||||
mkdir -p $SYSROOT/usr/local
|
mkdir -p $SYSROOT/usr/local
|
||||||
|
|
||||||
# Set up some symlinks to make the SpiderMonkey build system happy
|
# Set up some symlinks to make the SpiderMonkey build system happy
|
||||||
ln -sfT ../platforms $NDK/build/platforms
|
ln -sfT ../platforms $NDK/build/platforms
|
||||||
for f in $TOOLCHAIN/bin/arm-linux-androideabi-*; do
|
for f in $TOOLCHAIN/bin/arm-linux-androideabi-*; do
|
||||||
ln -sf $f ${f/arm-linux-androideabi-/arm-eabi-}
|
ln -sf $f ${f/arm-linux-androideabi-/arm-eabi-}
|
||||||
done
|
done
|
||||||
|
|
||||||
# Set up some symlinks for the typical autoconf-based build systems
|
# Set up some symlinks for the typical autoconf-based build systems
|
||||||
for f in $TOOLCHAIN/bin/arm-linux-androideabi-*; do
|
for f in $TOOLCHAIN/bin/arm-linux-androideabi-*; do
|
||||||
ln -sf $f ${f/arm-linux-androideabi-/arm-linux-eabi-}
|
ln -sf $f ${f/arm-linux-androideabi-/arm-linux-eabi-}
|
||||||
done
|
done
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
mkdir -p temp
|
mkdir -p temp
|
||||||
|
|
||||||
if [ "$build_boost" = "true" ]; then
|
if [ "$build_boost" = "true" ]; then
|
||||||
rm -rf temp/MysticTreeGames-Boost-for-Android-70838fc
|
rm -rf temp/MysticTreeGames-Boost-for-Android-70838fc
|
||||||
tar xvf files/MysticTreeGames-Boost-for-Android-70838fc.tar.gz -C temp/
|
tar xvf files/MysticTreeGames-Boost-for-Android-70838fc.tar.gz -C temp/
|
||||||
cp files/boost_1_45_0.tar.bz2 temp/MysticTreeGames-Boost-for-Android-70838fc/
|
cp files/boost_1_45_0.tar.bz2 temp/MysticTreeGames-Boost-for-Android-70838fc/
|
||||||
patch temp/MysticTreeGames-Boost-for-Android-70838fc/build-android.sh < boost-android-build.patch
|
patch temp/MysticTreeGames-Boost-for-Android-70838fc/build-android.sh <boost-android-build.patch
|
||||||
pushd temp/MysticTreeGames-Boost-for-Android-70838fc
|
pushd temp/MysticTreeGames-Boost-for-Android-70838fc
|
||||||
./build-android.sh $TOOLCHAIN
|
./build-android.sh $TOOLCHAIN
|
||||||
cp -rv build/{include,lib} $SYSROOT/usr/local/
|
cp -rv build/{include,lib} $SYSROOT/usr/local/
|
||||||
popd
|
popd
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$build_curl" = "true" ]; then
|
if [ "$build_curl" = "true" ]; then
|
||||||
rm -rf temp/curl-7.33.0
|
rm -rf temp/curl-7.33.0
|
||||||
tar xvf files/curl-7.33.0.tar.bz2 -C temp/
|
tar xvf files/curl-7.33.0.tar.bz2 -C temp/
|
||||||
pushd temp/curl-7.33.0
|
pushd temp/curl-7.33.0
|
||||||
./configure --host=arm-linux-androideabi --with-sysroot=$SYSROOT --prefix=$SYSROOT/usr/local CFLAGS="$CFLAGS" LDFLAGS="-lm" --disable-shared
|
./configure --host=arm-linux-androideabi --with-sysroot=$SYSROOT --prefix=$SYSROOT/usr/local CFLAGS="$CFLAGS" LDFLAGS="-lm" --disable-shared
|
||||||
make -j3
|
make -j3
|
||||||
make install
|
make install
|
||||||
popd
|
popd
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$build_libpng" = "true" ]; then
|
if [ "$build_libpng" = "true" ]; then
|
||||||
rm -rf temp/libpng-1.5.8
|
rm -rf temp/libpng-1.5.8
|
||||||
tar xvf files/libpng-1.5.8.tar.xz -C temp/
|
tar xvf files/libpng-1.5.8.tar.xz -C temp/
|
||||||
pushd temp/libpng-1.5.8
|
pushd temp/libpng-1.5.8
|
||||||
./configure --host=arm-linux-eabi --with-sysroot=$SYSROOT --prefix=$SYSROOT/usr/local CFLAGS="$CFLAGS"
|
./configure --host=arm-linux-eabi --with-sysroot=$SYSROOT --prefix=$SYSROOT/usr/local CFLAGS="$CFLAGS"
|
||||||
make $JOBS
|
make $JOBS
|
||||||
make install
|
make install
|
||||||
popd
|
popd
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$build_libjpeg" = "true" ]; then
|
if [ "$build_libjpeg" = "true" ]; then
|
||||||
rm -rf temp/libjpeg-turbo-1.3.0
|
rm -rf temp/libjpeg-turbo-1.3.0
|
||||||
tar xvf files/libjpeg-turbo-1.3.0.tar.gz -C temp/
|
tar xvf files/libjpeg-turbo-1.3.0.tar.gz -C temp/
|
||||||
pushd temp/libjpeg-turbo-1.3.0
|
pushd temp/libjpeg-turbo-1.3.0
|
||||||
./configure --host=arm-linux-eabi --with-sysroot=$SYSROOT --prefix=$SYSROOT/usr/local CFLAGS="$CFLAGS" LDFLAGS="-lm"
|
./configure --host=arm-linux-eabi --with-sysroot=$SYSROOT --prefix=$SYSROOT/usr/local CFLAGS="$CFLAGS" LDFLAGS="-lm"
|
||||||
make $JOBS
|
make $JOBS
|
||||||
make install
|
make install
|
||||||
popd
|
popd
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$build_libxml2" = "true" ]; then
|
if [ "$build_libxml2" = "true" ]; then
|
||||||
rm -rf temp/libxml2-2.7.8
|
rm -rf temp/libxml2-2.7.8
|
||||||
tar xvf files/libxml2-2.7.8.tar.gz -C temp/
|
tar xvf files/libxml2-2.7.8.tar.gz -C temp/
|
||||||
patch temp/libxml2-2.7.8/Makefile.in < libxml2-android-build.patch
|
patch temp/libxml2-2.7.8/Makefile.in <libxml2-android-build.patch
|
||||||
pushd temp/libxml2-2.7.8
|
pushd temp/libxml2-2.7.8
|
||||||
./configure --host=arm-linux-eabi --with-sysroot=$SYSROOT --prefix=$SYSROOT/usr/local CFLAGS="$CFLAGS"
|
./configure --host=arm-linux-eabi --with-sysroot=$SYSROOT --prefix=$SYSROOT/usr/local CFLAGS="$CFLAGS"
|
||||||
make $JOBS
|
make $JOBS
|
||||||
make install
|
make install
|
||||||
popd
|
popd
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$build_enet" = "true" ]; then
|
if [ "$build_enet" = "true" ]; then
|
||||||
rm -rf temp/enet-1.3.3
|
rm -rf temp/enet-1.3.3
|
||||||
tar xvf files/enet-1.3.3.tar.gz -C temp/
|
tar xvf files/enet-1.3.3.tar.gz -C temp/
|
||||||
pushd temp/enet-1.3.3
|
pushd temp/enet-1.3.3
|
||||||
./configure --host=arm-linux-eabi --with-sysroot=$SYSROOT --prefix=$SYSROOT/usr/local CFLAGS="$CFLAGS"
|
./configure --host=arm-linux-eabi --with-sysroot=$SYSROOT --prefix=$SYSROOT/usr/local CFLAGS="$CFLAGS"
|
||||||
make $JOBS
|
make $JOBS
|
||||||
make install
|
make install
|
||||||
popd
|
popd
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$build_js185" = "true" ]; then
|
if [ "$build_js185" = "true" ]; then
|
||||||
rm -rf temp/js-1.8.5
|
rm -rf temp/js-1.8.5
|
||||||
tar xvf files/js185-1.0.0.tar.gz -C temp/
|
tar xvf files/js185-1.0.0.tar.gz -C temp/
|
||||||
patch temp/js-1.8.5/js/src/assembler/wtf/Platform.h < js185-android-build.patch
|
patch temp/js-1.8.5/js/src/assembler/wtf/Platform.h <js185-android-build.patch
|
||||||
pushd temp/js-1.8.5/js/src
|
pushd temp/js-1.8.5/js/src
|
||||||
CXXFLAGS="-I $TOOLCHAIN/arm-linux-androideabi/include/c++/4.4.3/arm-linux-androideabi" \
|
CXXFLAGS="-I $TOOLCHAIN/arm-linux-androideabi/include/c++/4.4.3/arm-linux-androideabi" \
|
||||||
HOST_CXXFLAGS="-DFORCE_LITTLE_ENDIAN" \
|
HOST_CXXFLAGS="-DFORCE_LITTLE_ENDIAN" \
|
||||||
./configure \
|
./configure \
|
||||||
--prefix=$SYSROOT/usr/local \
|
--prefix=$SYSROOT/usr/local \
|
||||||
--target=arm-android-eabi \
|
--target=arm-android-eabi \
|
||||||
--with-android-ndk=$NDK \
|
--with-android-ndk=$NDK \
|
||||||
--with-android-sdk=$SDK \
|
--with-android-sdk=$SDK \
|
||||||
--with-android-toolchain=$TOOLCHAIN \
|
--with-android-toolchain=$TOOLCHAIN \
|
||||||
--with-android-version=9 \
|
--with-android-version=9 \
|
||||||
--disable-tests \
|
--disable-tests \
|
||||||
--disable-shared-js \
|
--disable-shared-js \
|
||||||
--with-arm-kuser \
|
--with-arm-kuser \
|
||||||
CFLAGS="$CFLAGS"
|
CFLAGS="$CFLAGS"
|
||||||
make $JOBS JS_DISABLE_SHELL=1
|
make $JOBS JS_DISABLE_SHELL=1
|
||||||
make install JS_DISABLE_SHELL=1
|
make install JS_DISABLE_SHELL=1
|
||||||
popd
|
popd
|
||||||
fi
|
fi
|
||||||
|
@ -8,20 +8,23 @@
|
|||||||
rm -f app.info
|
rm -f app.info
|
||||||
|
|
||||||
for APPDIR in ../workspaces/gcc/obj/*; do
|
for APPDIR in ../workspaces/gcc/obj/*; do
|
||||||
lcov -d "$APPDIR" --zerocounters
|
lcov -d "$APPDIR" --zerocounters
|
||||||
lcov -d "$APPDIR" -b ../workspaces/gcc --capture --initial -o temp.info
|
lcov -d "$APPDIR" -b ../workspaces/gcc --capture --initial -o temp.info
|
||||||
if [ -e app.info ]; then
|
if [ -e app.info ]; then
|
||||||
lcov -a app.info -a temp.info -o app.info
|
lcov -a app.info -a temp.info -o app.info
|
||||||
else
|
else
|
||||||
mv temp.info app.info
|
mv temp.info app.info
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
(cd ../../binaries/system/; ./test_dbg)
|
(
|
||||||
|
cd ../../binaries/system/
|
||||||
|
./test_dbg
|
||||||
|
)
|
||||||
|
|
||||||
for APPDIR in ../workspaces/gcc/obj/*; do
|
for APPDIR in ../workspaces/gcc/obj/*; do
|
||||||
lcov -d "$APPDIR" -b ../workspaces/gcc --capture -o temp.info &&
|
lcov -d "$APPDIR" -b ../workspaces/gcc --capture -o temp.info &&
|
||||||
lcov -a app.info -a temp.info -o app.info
|
lcov -a app.info -a temp.info -o app.info
|
||||||
done
|
done
|
||||||
|
|
||||||
lcov -r app.info '/usr/*' -o app.info
|
lcov -r app.info '/usr/*' -o app.info
|
||||||
@ -30,4 +33,7 @@ lcov -r app.info '*/third_party/*' -o app.info
|
|||||||
|
|
||||||
rm -rf output
|
rm -rf output
|
||||||
mkdir output
|
mkdir output
|
||||||
(cd output; genhtml ../app.info)
|
(
|
||||||
|
cd output
|
||||||
|
genhtml ../app.info
|
||||||
|
)
|
||||||
|
1
build/premake/.already-built
Normal file
1
build/premake/.already-built
Normal file
@ -0,0 +1 @@
|
|||||||
|
premake-5-alpha-14+wildfiregames.1
|
@ -3,10 +3,9 @@ set -e
|
|||||||
|
|
||||||
LIB_VERSION="premake-5-alpha-14+wildfiregames.1"
|
LIB_VERSION="premake-5-alpha-14+wildfiregames.1"
|
||||||
|
|
||||||
if [ -e .already-built ] && [ "$(cat .already-built)" = "${LIB_VERSION}" ]
|
if [ -e .already-built ] && [ "$(cat .already-built)" = "${LIB_VERSION}" ]; then
|
||||||
then
|
echo "Premake 5 is already up to date."
|
||||||
echo "Premake 5 is already up to date."
|
exit
|
||||||
exit
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
JOBS=${JOBS:="-j2"}
|
JOBS=${JOBS:="-j2"}
|
||||||
@ -20,16 +19,16 @@ echo
|
|||||||
PREMAKE_BUILD_DIR=premake5/build/gmake2.unix
|
PREMAKE_BUILD_DIR=premake5/build/gmake2.unix
|
||||||
# BSD and OS X need different Makefiles
|
# BSD and OS X need different Makefiles
|
||||||
case "$OS" in
|
case "$OS" in
|
||||||
"GNU/kFreeBSD" )
|
"GNU/kFreeBSD")
|
||||||
# use default gmake2.unix (needs -ldl as we have a GNU userland and libc)
|
# use default gmake2.unix (needs -ldl as we have a GNU userland and libc)
|
||||||
;;
|
;;
|
||||||
*"BSD" )
|
*"BSD")
|
||||||
PREMAKE_BUILD_DIR=premake5/build/gmake2.bsd
|
PREMAKE_BUILD_DIR=premake5/build/gmake2.bsd
|
||||||
;;
|
;;
|
||||||
"Darwin" )
|
"Darwin")
|
||||||
PREMAKE_BUILD_DIR=premake5/build/gmake2.macosx
|
PREMAKE_BUILD_DIR=premake5/build/gmake2.macosx
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
${MAKE} -C "${PREMAKE_BUILD_DIR}" "${JOBS}" CFLAGS="$CFLAGS" config=release
|
${MAKE} -C "${PREMAKE_BUILD_DIR}" "${JOBS}" CFLAGS="$CFLAGS" config=release
|
||||||
|
|
||||||
echo "${LIB_VERSION}" > .already-built
|
echo "${LIB_VERSION}" >.already-built
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
pyrogenesis=$(which pyrogenesis 2> /dev/null)
|
pyrogenesis=$(which pyrogenesis 2>/dev/null)
|
||||||
if [ -x "$pyrogenesis" ] ; then
|
if [ -x "$pyrogenesis" ]; then
|
||||||
"$pyrogenesis" "$@"
|
"$pyrogenesis" "$@"
|
||||||
else
|
else
|
||||||
echo "Error: pyrogenesis not found in ($PATH)"
|
echo "Error: pyrogenesis not found in ($PATH)"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
@ -1,14 +1,14 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
if [ "$(id -u)" = "0" ]; then
|
if [ "$(id -u)" = "0" ]; then
|
||||||
echo "Running as root will mess up file permissions. Aborting ..." 1>&2
|
echo "Running as root will mess up file permissions. Aborting ..." 1>&2
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
die()
|
die()
|
||||||
{
|
{
|
||||||
echo ERROR: $*
|
echo ERROR: $*
|
||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
|
||||||
OS=${OS:="$(uname -s)"}
|
OS=${OS:="$(uname -s)"}
|
||||||
@ -16,12 +16,12 @@ OS=${OS:="$(uname -s)"}
|
|||||||
# Some of our makefiles depend on GNU make, so we set some sane defaults if MAKE
|
# Some of our makefiles depend on GNU make, so we set some sane defaults if MAKE
|
||||||
# is not set.
|
# is not set.
|
||||||
case "$OS" in
|
case "$OS" in
|
||||||
"FreeBSD" | "OpenBSD" )
|
"FreeBSD" | "OpenBSD")
|
||||||
MAKE=${MAKE:="gmake"}
|
MAKE=${MAKE:="gmake"}
|
||||||
;;
|
;;
|
||||||
* )
|
*)
|
||||||
MAKE=${MAKE:="make"}
|
MAKE=${MAKE:="make"}
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
cd "$(dirname $0)"
|
cd "$(dirname $0)"
|
||||||
@ -35,37 +35,35 @@ enable_atlas=true
|
|||||||
|
|
||||||
JOBS=${JOBS:="-j2"}
|
JOBS=${JOBS:="-j2"}
|
||||||
|
|
||||||
for i in "$@"
|
for i in "$@"; do
|
||||||
do
|
case $i in
|
||||||
case $i in
|
--with-system-premake5) with_system_premake5=true ;;
|
||||||
--with-system-premake5 ) with_system_premake5=true ;;
|
--enable-atlas) enable_atlas=true ;;
|
||||||
--enable-atlas ) enable_atlas=true ;;
|
--disable-atlas) enable_atlas=false ;;
|
||||||
--disable-atlas ) enable_atlas=false ;;
|
-j*) JOBS=$i ;;
|
||||||
-j* ) JOBS=$i ;;
|
# Assume any other --options are for Premake
|
||||||
# Assume any other --options are for Premake
|
--*) premake_args="${premake_args} $i" ;;
|
||||||
--* ) premake_args="${premake_args} $i" ;;
|
esac
|
||||||
esac
|
|
||||||
done
|
done
|
||||||
|
|
||||||
if [ "$enable_atlas" = "true" ]; then
|
if [ "$enable_atlas" = "true" ]; then
|
||||||
premake_args="${premake_args} --atlas"
|
premake_args="${premake_args} --atlas"
|
||||||
if [ "$OS" = "Darwin" ]; then
|
if [ "$OS" = "Darwin" ]; then
|
||||||
# Provide path to wx-config on OS X (as wxwidgets doesn't support pkgconfig)
|
# Provide path to wx-config on OS X (as wxwidgets doesn't support pkgconfig)
|
||||||
export WX_CONFIG="${WX_CONFIG:="$(pwd)/../../libraries/macos/wxwidgets/bin/wx-config"}"
|
export WX_CONFIG="${WX_CONFIG:="$(pwd)/../../libraries/macos/wxwidgets/bin/wx-config"}"
|
||||||
else
|
else
|
||||||
export WX_CONFIG="${WX_CONFIG:="wx-config"}"
|
export WX_CONFIG="${WX_CONFIG:="wx-config"}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -x "$(command -v $WX_CONFIG)" ]
|
if [ ! -x "$(command -v $WX_CONFIG)" ]; then
|
||||||
then
|
echo 'WX_CONFIG must be set and valid or wx-config must be present when --atlas is passed as argument.'
|
||||||
echo 'WX_CONFIG must be set and valid or wx-config must be present when --atlas is passed as argument.'
|
exit 1
|
||||||
exit 1
|
fi
|
||||||
fi
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$OS" = "Darwin" ]; then
|
if [ "$OS" = "Darwin" ]; then
|
||||||
# Set minimal SDK version
|
# Set minimal SDK version
|
||||||
export MIN_OSX_VERSION=${MIN_OSX_VERSION:="10.12"}
|
export MIN_OSX_VERSION=${MIN_OSX_VERSION:="10.12"}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Now build Premake or use system's.
|
# Now build Premake or use system's.
|
||||||
@ -74,10 +72,10 @@ cd ../premake
|
|||||||
premake_command="premake5"
|
premake_command="premake5"
|
||||||
|
|
||||||
if [ "$with_system_premake5" = "false" ]; then
|
if [ "$with_system_premake5" = "false" ]; then
|
||||||
# Build bundled premake
|
# Build bundled premake
|
||||||
MAKE=${MAKE} JOBS=${JOBS} ./build.sh || die "Premake 5 build failed"
|
MAKE=${MAKE} JOBS=${JOBS} ./build.sh || die "Premake 5 build failed"
|
||||||
|
|
||||||
premake_command="premake5/bin/release/premake5"
|
premake_command="premake5/bin/release/premake5"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo
|
echo
|
||||||
@ -87,11 +85,11 @@ export HOSTTYPE="$HOSTTYPE"
|
|||||||
# Now run Premake to create the makefiles
|
# Now run Premake to create the makefiles
|
||||||
echo "Premake args: ${premake_args}"
|
echo "Premake args: ${premake_args}"
|
||||||
if [ "$OS" != "Darwin" ]; then
|
if [ "$OS" != "Darwin" ]; then
|
||||||
${premake_command} --file="premake5.lua" --outpath="../workspaces/gcc/" ${premake_args} gmake || die "Premake failed"
|
${premake_command} --file="premake5.lua" --outpath="../workspaces/gcc/" ${premake_args} gmake || die "Premake failed"
|
||||||
else
|
else
|
||||||
${premake_command} --file="premake5.lua" --outpath="../workspaces/gcc/" --macosx-version-min="${MIN_OSX_VERSION}" ${premake_args} gmake || die "Premake failed"
|
${premake_command} --file="premake5.lua" --outpath="../workspaces/gcc/" --macosx-version-min="${MIN_OSX_VERSION}" ${premake_args} gmake || die "Premake failed"
|
||||||
# Also generate xcode workspaces if on OS X
|
# Also generate xcode workspaces if on OS X
|
||||||
${premake_command} --file="premake5.lua" --outpath="../workspaces/xcode4" --macosx-version-min="${MIN_OSX_VERSION}" ${premake_args} xcode4 || die "Premake failed"
|
${premake_command} --file="premake5.lua" --outpath="../workspaces/xcode4" --macosx-version-min="${MIN_OSX_VERSION}" ${premake_args} xcode4 || die "Premake failed"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# test_root.cpp gets generated by cxxtestgen and passing different arguments to premake could require a regeneration of this file.
|
# test_root.cpp gets generated by cxxtestgen and passing different arguments to premake could require a regeneration of this file.
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -2,17 +2,17 @@
|
|||||||
|
|
||||||
die()
|
die()
|
||||||
{
|
{
|
||||||
echo ERROR: $*
|
echo ERROR: $*
|
||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
|
||||||
# SVN revision to checkout for source-libs
|
# SVN revision to checkout for source-libs
|
||||||
# Update this line when you commit an update to source-libs
|
# Update this line when you commit an update to source-libs
|
||||||
source_svnrev="28207"
|
source_svnrev="28207"
|
||||||
|
|
||||||
if [ "`uname -s`" = "Darwin" ]; then
|
if [ "$(uname -s)" = "Darwin" ]; then
|
||||||
echo 'This script should not be used on macOS: use build-macos-libs.sh instead.'
|
echo 'This script should not be used on macOS: use build-macos-libs.sh instead.'
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
cd "$(dirname $0)"
|
cd "$(dirname $0)"
|
||||||
@ -21,13 +21,13 @@ cd "$(dirname $0)"
|
|||||||
# Check for whitespace in absolute path; this will cause problems in the
|
# Check for whitespace in absolute path; this will cause problems in the
|
||||||
# SpiderMonkey build and maybe elsewhere, so we just forbid it
|
# SpiderMonkey build and maybe elsewhere, so we just forbid it
|
||||||
# Use perl as an alternative to readlink -f, which isn't available on BSD
|
# Use perl as an alternative to readlink -f, which isn't available on BSD
|
||||||
SCRIPTPATH=`perl -MCwd -e 'print Cwd::abs_path shift' "$0"`
|
SCRIPTPATH=$(perl -MCwd -e 'print Cwd::abs_path shift' "$0")
|
||||||
case "$SCRIPTPATH" in
|
case "$SCRIPTPATH" in
|
||||||
*\ * )
|
*\ *)
|
||||||
die "Absolute path contains whitespace, which will break the build - move the game to a path without spaces" ;;
|
die "Absolute path contains whitespace, which will break the build - move the game to a path without spaces"
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
|
||||||
# Parse command-line options (download options and build options):
|
# Parse command-line options (download options and build options):
|
||||||
source_libs_dir="source"
|
source_libs_dir="source"
|
||||||
|
|
||||||
@ -37,25 +37,24 @@ with_system_mozjs=false
|
|||||||
|
|
||||||
JOBS=${JOBS:="-j2"}
|
JOBS=${JOBS:="-j2"}
|
||||||
|
|
||||||
for i in "$@"
|
for i in "$@"; do
|
||||||
do
|
case $i in
|
||||||
case $i in
|
--source-libs-dir=*) source_libs_dir=${1#*=} ;;
|
||||||
--source-libs-dir=* ) source_libs_dir=${1#*=} ;;
|
--source-libs-dir) die "correct syntax is --source-libs-dir=/path/to/dir" ;;
|
||||||
--source-libs-dir ) die "correct syntax is --source-libs-dir=/path/to/dir" ;;
|
--without-nvtt) without_nvtt=true ;;
|
||||||
--without-nvtt ) without_nvtt=true ;;
|
--with-system-nvtt) with_system_nvtt=true ;;
|
||||||
--with-system-nvtt ) with_system_nvtt=true ;;
|
--with-system-mozjs) with_system_mozjs=true ;;
|
||||||
--with-system-mozjs ) with_system_mozjs=true ;;
|
-j*) JOBS=$i ;;
|
||||||
-j* ) JOBS=$i ;;
|
esac
|
||||||
esac
|
|
||||||
done
|
done
|
||||||
|
|
||||||
# Download source libs
|
# Download source libs
|
||||||
echo "Downloading source libs..."
|
echo "Downloading source libs..."
|
||||||
echo
|
echo
|
||||||
if [ -e ${source_libs_dir}/.svn ]; then
|
if [ -e ${source_libs_dir}/.svn ]; then
|
||||||
(cd ${source_libs_dir} && svn cleanup && svn up -r $source_svnrev)
|
(cd ${source_libs_dir} && svn cleanup && svn up -r $source_svnrev)
|
||||||
else
|
else
|
||||||
svn co -r $source_svnrev https://svn.wildfiregames.com/public/source-libs/trunk ${source_libs_dir}
|
svn co -r $source_svnrev https://svn.wildfiregames.com/public/source-libs/trunk ${source_libs_dir}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Build/update bundled external libraries
|
# Build/update bundled external libraries
|
||||||
@ -64,23 +63,23 @@ echo
|
|||||||
|
|
||||||
# Some of our makefiles depend on GNU make, so we set some sane defaults if MAKE
|
# Some of our makefiles depend on GNU make, so we set some sane defaults if MAKE
|
||||||
# is not set.
|
# is not set.
|
||||||
case "`uname -s`" in
|
case "$(uname -s)" in
|
||||||
"FreeBSD" | "OpenBSD" )
|
"FreeBSD" | "OpenBSD")
|
||||||
MAKE=${MAKE:="gmake"}
|
MAKE=${MAKE:="gmake"}
|
||||||
;;
|
;;
|
||||||
* )
|
*)
|
||||||
MAKE=${MAKE:="make"}
|
MAKE=${MAKE:="make"}
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
(cd ${source_libs_dir}/fcollada && MAKE=${MAKE} JOBS=${JOBS} ./build.sh) || die "FCollada build failed"
|
(cd ${source_libs_dir}/fcollada && MAKE=${MAKE} JOBS=${JOBS} ./build.sh) || die "FCollada build failed"
|
||||||
echo
|
echo
|
||||||
if [ "$with_system_nvtt" = "false" ] && [ "$without_nvtt" = "false" ]; then
|
if [ "$with_system_nvtt" = "false" ] && [ "$without_nvtt" = "false" ]; then
|
||||||
(cd ${source_libs_dir}/nvtt && MAKE=${MAKE} JOBS=${JOBS} ./build.sh) || die "NVTT build failed"
|
(cd ${source_libs_dir}/nvtt && MAKE=${MAKE} JOBS=${JOBS} ./build.sh) || die "NVTT build failed"
|
||||||
fi
|
fi
|
||||||
echo
|
echo
|
||||||
if [ "$with_system_mozjs" = "false" ]; then
|
if [ "$with_system_mozjs" = "false" ]; then
|
||||||
(cd ${source_libs_dir}/spidermonkey && MAKE=${MAKE} JOBS=${JOBS} ./build.sh) || die "SpiderMonkey build failed"
|
(cd ${source_libs_dir}/spidermonkey && MAKE=${MAKE} JOBS=${JOBS} ./build.sh) || die "SpiderMonkey build failed"
|
||||||
fi
|
fi
|
||||||
echo
|
echo
|
||||||
|
|
||||||
@ -88,29 +87,29 @@ echo "Copying built files..."
|
|||||||
# Copy built binaries to binaries/system/
|
# Copy built binaries to binaries/system/
|
||||||
cp ${source_libs_dir}/fcollada/bin/* ../binaries/system/
|
cp ${source_libs_dir}/fcollada/bin/* ../binaries/system/
|
||||||
if [ "$with_system_nvtt" = "false" ] && [ "$without_nvtt" = "false" ]; then
|
if [ "$with_system_nvtt" = "false" ] && [ "$without_nvtt" = "false" ]; then
|
||||||
cp ${source_libs_dir}/nvtt/bin/* ../binaries/system/
|
cp ${source_libs_dir}/nvtt/bin/* ../binaries/system/
|
||||||
fi
|
fi
|
||||||
if [ "$with_system_mozjs" = "false" ]; then
|
if [ "$with_system_mozjs" = "false" ]; then
|
||||||
cp ${source_libs_dir}/spidermonkey/bin/* ../binaries/system/
|
cp ${source_libs_dir}/spidermonkey/bin/* ../binaries/system/
|
||||||
fi
|
fi
|
||||||
# If a custom source-libs dir was used, includes and static libs should be copied to libraries/source/
|
# If a custom source-libs dir was used, includes and static libs should be copied to libraries/source/
|
||||||
# and all other bundled content should be copied.
|
# and all other bundled content should be copied.
|
||||||
if [ "$source_libs_dir" != "source" ]; then
|
if [ "$source_libs_dir" != "source" ]; then
|
||||||
rsync -avzq \
|
rsync -avzq \
|
||||||
--exclude fcollada \
|
--exclude fcollada \
|
||||||
--exclude nvtt \
|
--exclude nvtt \
|
||||||
--exclude spidermonkey \
|
--exclude spidermonkey \
|
||||||
${source_libs_dir}/ source
|
${source_libs_dir}/ source
|
||||||
|
|
||||||
mkdir -p source/fcollada
|
mkdir -p source/fcollada
|
||||||
cp -r ${source_libs_dir}/fcollada/{include,lib} source/fcollada/
|
cp -r ${source_libs_dir}/fcollada/{include,lib} source/fcollada/
|
||||||
if [ "$with_system_nvtt" = "false" ] && [ "$without_nvtt" = "false" ]; then
|
if [ "$with_system_nvtt" = "false" ] && [ "$without_nvtt" = "false" ]; then
|
||||||
mkdir -p source/nvtt
|
mkdir -p source/nvtt
|
||||||
cp -r ${source_libs_dir}/nvtt/{include,lib} source/nvtt/
|
cp -r ${source_libs_dir}/nvtt/{include,lib} source/nvtt/
|
||||||
fi
|
fi
|
||||||
if [ "$with_system_mozjs" = "false" ]; then
|
if [ "$with_system_mozjs" = "false" ]; then
|
||||||
mkdir -p source/spidermonkey
|
mkdir -p source/spidermonkey
|
||||||
cp -r ${source_libs_dir}/spidermonkey/{include-unix-debug,include-unix-release,lib} source/spidermonkey/
|
cp -r ${source_libs_dir}/spidermonkey/{include-unix-debug,include-unix-release,lib} source/spidermonkey/
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
echo "Done."
|
echo "Done."
|
||||||
|
@ -12,9 +12,9 @@ cd "$(dirname $0)"
|
|||||||
echo "Cleaning bundled third-party dependencies..."
|
echo "Cleaning bundled third-party dependencies..."
|
||||||
|
|
||||||
if [ -e source/.svn ]; then
|
if [ -e source/.svn ]; then
|
||||||
(cd source && svn revert -R . && svn st --no-ignore | cut -c 9- | xargs rm -rf)
|
(cd source && svn revert -R . && svn st --no-ignore | cut -c 9- | xargs rm -rf)
|
||||||
else
|
else
|
||||||
rm -rf source
|
rm -rf source
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo
|
echo
|
||||||
|
25
source/tools/dist/build-archives.sh
vendored
25
source/tools/dist/build-archives.sh
vendored
@ -25,18 +25,17 @@ REGEX=".*/\("${REGEX:2}"\)\.[-A-Za-z0-9_.]\+\.po"
|
|||||||
find binaries/ -name "*.po" | grep -v "$REGEX" | xargs rm -v || die "Error filtering languages."
|
find binaries/ -name "*.po" | grep -v "$REGEX" | xargs rm -v || die "Error filtering languages."
|
||||||
|
|
||||||
# Build archive(s) - don't archive the _test.* mods
|
# Build archive(s) - don't archive the _test.* mods
|
||||||
pushd binaries/data/mods > /dev/null
|
pushd binaries/data/mods >/dev/null
|
||||||
archives=""
|
archives=""
|
||||||
ONLY_MOD="${ONLY_MOD:=false}"
|
ONLY_MOD="${ONLY_MOD:=false}"
|
||||||
if [ "${ONLY_MOD}" = true ]; then
|
if [ "${ONLY_MOD}" = true ]; then
|
||||||
archives="mod"
|
archives="mod"
|
||||||
else
|
else
|
||||||
for modname in [a-zA-Z0-9]*
|
for modname in [a-zA-Z0-9]*; do
|
||||||
do
|
|
||||||
archives="${archives} ${modname}"
|
archives="${archives} ${modname}"
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
popd > /dev/null
|
popd >/dev/null
|
||||||
|
|
||||||
BUILD_SHADERS="${BUILD_SHADERS:=true}"
|
BUILD_SHADERS="${BUILD_SHADERS:=true}"
|
||||||
if [ "${BUILD_SHADERS}" = true ]; then
|
if [ "${BUILD_SHADERS}" = true ]; then
|
||||||
@ -48,35 +47,31 @@ if [ "${BUILD_SHADERS}" = true ]; then
|
|||||||
[ -n "${GLSLC}" ] || die "Error: glslc is not available. Install it with the Vulkan SDK before proceeding."
|
[ -n "${GLSLC}" ] || die "Error: glslc is not available. Install it with the Vulkan SDK before proceeding."
|
||||||
[ -n "${SPIRV_REFLECT}" ] || die "Error: spirv-reflect is not available. Install it with the Vulkan SDK before proceeding."
|
[ -n "${SPIRV_REFLECT}" ] || die "Error: spirv-reflect is not available. Install it with the Vulkan SDK before proceeding."
|
||||||
|
|
||||||
pushd "source/tools/spirv" > /dev/null
|
pushd "source/tools/spirv" >/dev/null
|
||||||
|
|
||||||
ENGINE_VERSION=${ENGINE_VERSION:="0.0.xx"}
|
ENGINE_VERSION=${ENGINE_VERSION:="0.0.xx"}
|
||||||
rulesFile="rules.${ENGINE_VERSION}.json"
|
rulesFile="rules.${ENGINE_VERSION}.json"
|
||||||
|
|
||||||
if [ ! -e "$rulesFile" ]
|
if [ ! -e "$rulesFile" ]; then
|
||||||
then
|
|
||||||
# The rules.json file should be present in release tarballs, for
|
# The rules.json file should be present in release tarballs, for
|
||||||
# some Linux CIs don't have access to the internet.
|
# some Linux CIs don't have access to the internet.
|
||||||
download="$(command -v wget || echo "curl -sLo ""${rulesFile}""")"
|
download="$(command -v wget || echo "curl -sLo ""${rulesFile}""")"
|
||||||
$download "https://releases.wildfiregames.com/spir-v/$rulesFile"
|
$download "https://releases.wildfiregames.com/spir-v/$rulesFile"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
for modname in $archives
|
for modname in $archives; do
|
||||||
do
|
|
||||||
modLocation="../../../binaries/data/mods/${modname}"
|
modLocation="../../../binaries/data/mods/${modname}"
|
||||||
if [ -e "${modLocation}/shaders/spirv/" ]
|
if [ -e "${modLocation}/shaders/spirv/" ]; then
|
||||||
then
|
|
||||||
echo "Removing existing spirv shaders for '${modname}'..."
|
echo "Removing existing spirv shaders for '${modname}'..."
|
||||||
rm -rf "${modLocation}/shaders/spirv"
|
rm -rf "${modLocation}/shaders/spirv"
|
||||||
fi
|
fi
|
||||||
echo "Building shader for '${modname}'..."
|
echo "Building shader for '${modname}'..."
|
||||||
$PYTHON compile.py "$modLocation" "$rulesFile" "$modLocation" --dependency "../../../binaries/data/mods/mod/"
|
$PYTHON compile.py "$modLocation" "$rulesFile" "$modLocation" --dependency "../../../binaries/data/mods/mod/"
|
||||||
done
|
done
|
||||||
popd > /dev/null
|
popd >/dev/null
|
||||||
fi
|
fi
|
||||||
|
|
||||||
for modname in $archives
|
for modname in $archives; do
|
||||||
do
|
|
||||||
echo "Building archive for '${modname}'..."
|
echo "Building archive for '${modname}'..."
|
||||||
ARCHIVEBUILD_INPUT="binaries/data/mods/${modname}"
|
ARCHIVEBUILD_INPUT="binaries/data/mods/${modname}"
|
||||||
ARCHIVEBUILD_OUTPUT="archives/${modname}"
|
ARCHIVEBUILD_OUTPUT="archives/${modname}"
|
||||||
@ -84,5 +79,5 @@ do
|
|||||||
mkdir -p "${ARCHIVEBUILD_OUTPUT}"
|
mkdir -p "${ARCHIVEBUILD_OUTPUT}"
|
||||||
|
|
||||||
(./binaries/system/pyrogenesis -mod=mod -archivebuild="${ARCHIVEBUILD_INPUT}" -archivebuild-output="${ARCHIVEBUILD_OUTPUT}/${modname}.zip") || die "Archive build for '${modname}' failed!"
|
(./binaries/system/pyrogenesis -mod=mod -archivebuild="${ARCHIVEBUILD_INPUT}" -archivebuild-output="${ARCHIVEBUILD_OUTPUT}/${modname}.zip") || die "Archive build for '${modname}' failed!"
|
||||||
cp "${ARCHIVEBUILD_INPUT}/mod.json" "${ARCHIVEBUILD_OUTPUT}" &> /dev/null || true
|
cp "${ARCHIVEBUILD_INPUT}/mod.json" "${ARCHIVEBUILD_OUTPUT}" &>/dev/null || true
|
||||||
done
|
done
|
||||||
|
22
source/tools/dist/build-osx-executable.sh
vendored
22
source/tools/dist/build-osx-executable.sh
vendored
@ -13,18 +13,18 @@ export CC=${CC:="clang"} CXX=${CXX:="clang++"}
|
|||||||
|
|
||||||
die()
|
die()
|
||||||
{
|
{
|
||||||
echo ERROR: $*
|
echo ERROR: $*
|
||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
|
||||||
# Check that we're actually on OS X
|
# Check that we're actually on OS X
|
||||||
if [ "`uname -s`" != "Darwin" ]; then
|
if [ "$(uname -s)" != "Darwin" ]; then
|
||||||
die "This script is intended for OS X only"
|
die "This script is intended for OS X only"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Check SDK exists
|
# Check SDK exists
|
||||||
if [ ! -d "${SYSROOT}" ]; then
|
if [ ! -d "${SYSROOT}" ]; then
|
||||||
die "${SYSROOT} does not exist! You probably need to install Xcode"
|
die "${SYSROOT} does not exist! You probably need to install Xcode"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
cd "build/workspaces/"
|
cd "build/workspaces/"
|
||||||
@ -46,10 +46,10 @@ fi
|
|||||||
|
|
||||||
# Build libraries against SDK
|
# Build libraries against SDK
|
||||||
echo "\nBuilding libraries\n"
|
echo "\nBuilding libraries\n"
|
||||||
pushd ../../libraries/osx > /dev/null
|
pushd ../../libraries/osx >/dev/null
|
||||||
SYSROOT="${SYSROOT}" MIN_OSX_VERSION="${MIN_OSX_VERSION}" \
|
SYSROOT="${SYSROOT}" MIN_OSX_VERSION="${MIN_OSX_VERSION}" \
|
||||||
./build-osx-libs.sh $JOBS "${BUILD_LIBS_ARGS}" || die "Libraries build script failed"
|
./build-osx-libs.sh $JOBS "${BUILD_LIBS_ARGS}" || die "Libraries build script failed"
|
||||||
popd > /dev/null
|
popd >/dev/null
|
||||||
|
|
||||||
# Update workspaces
|
# Update workspaces
|
||||||
echo "\nGenerating workspaces\n"
|
echo "\nGenerating workspaces\n"
|
||||||
@ -58,13 +58,13 @@ echo "\nGenerating workspaces\n"
|
|||||||
(SYSROOT="${SYSROOT}" MIN_OSX_VERSION="${MIN_OSX_VERSION}" \
|
(SYSROOT="${SYSROOT}" MIN_OSX_VERSION="${MIN_OSX_VERSION}" \
|
||||||
./update-workspaces.sh --sysroot="${SYSROOT}" --macosx-version-min="${MIN_OSX_VERSION}") || die "update-workspaces.sh failed!"
|
./update-workspaces.sh --sysroot="${SYSROOT}" --macosx-version-min="${MIN_OSX_VERSION}") || die "update-workspaces.sh failed!"
|
||||||
|
|
||||||
pushd gcc > /dev/null
|
pushd gcc >/dev/null
|
||||||
echo "\nBuilding game\n"
|
echo "\nBuilding game\n"
|
||||||
(make clean && CC="$CC -arch $ARCH" CXX="$CXX -arch $ARCH" make ${JOBS}) || die "Game build failed!"
|
(make clean && CC="$CC -arch $ARCH" CXX="$CXX -arch $ARCH" make ${JOBS}) || die "Game build failed!"
|
||||||
popd > /dev/null
|
popd >/dev/null
|
||||||
|
|
||||||
# Run test to confirm all is OK
|
# Run test to confirm all is OK
|
||||||
pushd ../../binaries/system > /dev/null
|
pushd ../../binaries/system >/dev/null
|
||||||
echo "\nRunning tests\n"
|
echo "\nRunning tests\n"
|
||||||
./test || die "Post-build testing failed!"
|
./test || die "Post-build testing failed!"
|
||||||
popd > /dev/null
|
popd >/dev/null
|
||||||
|
6
source/tools/dist/build-unix-win32.sh
vendored
6
source/tools/dist/build-unix-win32.sh
vendored
@ -19,9 +19,9 @@ tar cf $PREFIX-unix-build.tar \
|
|||||||
|
|
||||||
tar cf $PREFIX-unix-data.tar \
|
tar cf $PREFIX-unix-data.tar \
|
||||||
--exclude='binaries/data/config/dev.cfg' \
|
--exclude='binaries/data/config/dev.cfg' \
|
||||||
-s "|archives|$PREFIX/binaries/data/mods|" \
|
-s "|archives|$PREFIX/binaries/data/mods|" \
|
||||||
-s "|binaries|$PREFIX/binaries|" \
|
-s "|binaries|$PREFIX/binaries|" \
|
||||||
binaries/data/{config,tools} archives/
|
binaries/data/{config,tools} archives/
|
||||||
# TODO: ought to include generated docs in here, perhaps?
|
# TODO: ought to include generated docs in here, perhaps?
|
||||||
|
|
||||||
# Compress
|
# Compress
|
||||||
|
@ -9,7 +9,7 @@ cd "$(dirname $0)"
|
|||||||
svn export --force --depth files https://svn.wildfiregames.com/nightly-build/trunk/binaries/data/l10n ../../../binaries/data/l10n
|
svn export --force --depth files https://svn.wildfiregames.com/nightly-build/trunk/binaries/data/l10n ../../../binaries/data/l10n
|
||||||
|
|
||||||
for m in "mod" "public"; do
|
for m in "mod" "public"; do
|
||||||
svn export --force --depth files https://svn.wildfiregames.com/nightly-build/trunk/binaries/data/mods/${m}/l10n ../../../binaries/data/mods/${m}/l10n
|
svn export --force --depth files https://svn.wildfiregames.com/nightly-build/trunk/binaries/data/mods/${m}/l10n ../../../binaries/data/mods/${m}/l10n
|
||||||
done
|
done
|
||||||
|
|
||||||
svn export --force https://svn.wildfiregames.com/nightly-build/trunk/binaries/data/mods/public/gui/credits/texts/translators.json ../../../binaries/data/mods/public/gui/credits/texts/translators.json
|
svn export --force https://svn.wildfiregames.com/nightly-build/trunk/binaries/data/mods/public/gui/credits/texts/translators.json ../../../binaries/data/mods/public/gui/credits/texts/translators.json
|
||||||
|
@ -6,5 +6,5 @@ set -ev
|
|||||||
cd "$(dirname $0)"
|
cd "$(dirname $0)"
|
||||||
|
|
||||||
for m in "mod" "public"; do
|
for m in "mod" "public"; do
|
||||||
svn export --force https://svn.wildfiregames.com/nightly-build/trunk/binaries/data/mods/${m}/shaders/spirv ../../../binaries/data/mods/${m}/shaders/spirv
|
svn export --force https://svn.wildfiregames.com/nightly-build/trunk/binaries/data/mods/${m}/shaders/spirv ../../../binaries/data/mods/${m}/shaders/spirv
|
||||||
done
|
done
|
||||||
|
@ -1,11 +1,10 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# check arguments count
|
# check arguments count
|
||||||
if [ $# -ne 1 ]; then
|
if [ $# -ne 1 ]; then
|
||||||
echo 'usage: '$0' directory'
|
echo 'usage: '$0' directory'
|
||||||
exit
|
exit
|
||||||
fi
|
fi
|
||||||
# assign arguments to variables with readable names
|
# assign arguments to variables with readable names
|
||||||
input_directory=$1
|
input_directory=$1
|
||||||
# perform work
|
# perform work
|
||||||
find $input_directory -name \*.xml -exec xsltproc -o {} templatessorter.xsl {} \;
|
find $input_directory -name \*.xml -exec xsltproc -o {} templatessorter.xsl {} \;
|
||||||
|
|
||||||
|
@ -13,11 +13,10 @@ export TLDIR="$(dirname $(realpath $0))"
|
|||||||
|
|
||||||
# Use semicolons to separate values on Windows.
|
# Use semicolons to separate values on Windows.
|
||||||
# If that produces bogus output, you can try with commas instead.
|
# If that produces bogus output, you can try with commas instead.
|
||||||
if [ "${OS}" = "Windows_NT" ]
|
if [ "${OS}" = "Windows_NT" ]; then
|
||||||
then
|
export TLLOG="Default;IonCompiler"
|
||||||
export TLLOG="Default;IonCompiler"
|
export TLOPTIONS="EnableMainThread;EnableOffThread;EnableGraph"
|
||||||
export TLOPTIONS="EnableMainThread;EnableOffThread;EnableGraph"
|
|
||||||
else
|
else
|
||||||
export TLLOG=Default,IonCompiler
|
export TLLOG=Default,IonCompiler
|
||||||
export TLOPTIONS=EnableMainThread,EnableOffThread,EnableGraph
|
export TLOPTIONS=EnableMainThread,EnableOffThread,EnableGraph
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user