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:
25
packaging/windows/buildpackage.sh
Executable file
25
packaging/windows/buildpackage.sh
Executable 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
|
||||
Reference in New Issue
Block a user