Keep downloaded files in a separate directory

As a side effect, this re-enables building the Windows installer on Linux hosts.
This commit is contained in:
Oliver Brakmann
2015-05-02 16:28:27 +02:00
parent 14886bc3f7
commit f251813f89
21 changed files with 154 additions and 117 deletions

View File

@@ -0,0 +1,25 @@
#!/bin/bash
TAG="$1"
BUILTDIR="$2"
SRCDIR="$3"
OUTPUTDIR="$4"
if [ -x /usr/bin/makensis ]; then
pushd "$SRCDIR" >/dev/null
popd >/dev/null
if [[ ! -f /usr/share/nsis/Include/nsProcess.nsh && ! -f /usr/share/nsis/Plugin/nsProcess.dll ]]; then
echo "Installing NsProcess NSIS plugin in /usr/share/nsis"
sudo unzip -qq -o ${SRCDIR}/thirdparty/download/NsProcess.zip 'Include/*' -d /usr/share/nsis
sudo unzip -qq -j -o ${SRCDIR}/thirdparty/download/NsProcess.zip 'Plugin/*' -d /usr/share/nsis/Plugins
fi
echo "Building Windows setup.exe"
makensis -V2 -DSRCDIR="$BUILTDIR" -DDEPSDIR="${SRCDIR}/thirdparty/download/windows" OpenRA.nsi
if [ $? -eq 0 ]; then
mv OpenRA.Setup.exe "$OUTPUTDIR"/OpenRA-$TAG.exe
else
exit 1
fi
else
echo "Skipping Windows setup.exe build due to missing NSIS"
fi