Create separate Windows launchers for each mod.
This commit is contained in:
22
packaging/windows/buildpackage.sh
Executable file → Normal file
22
packaging/windows/buildpackage.sh
Executable file → Normal file
@@ -8,6 +8,13 @@ OUTPUTDIR="$4"
|
||||
LAUNCHER_LIBS="-r:System.dll -r:System.Drawing.dll -r:System.Windows.Forms.dll -r:${BUILTDIR}/OpenRA.Game.exe"
|
||||
FAQ_URL="http://wiki.openra.net/FAQ"
|
||||
|
||||
SUFFIX=" (dev)"
|
||||
if [[ $TAG == release* ]]; then
|
||||
SUFFIX=""
|
||||
elif [[ $TAG == playtest* ]]; then
|
||||
SUFFIX=" (playtest)"
|
||||
fi
|
||||
|
||||
function makelauncher()
|
||||
{
|
||||
sed "s|DISPLAY_NAME|$2|" WindowsLauncher.cs.in | sed "s|MOD_ID|$3|" | sed "s|FAQ_URL|${FAQ_URL}|" > WindowsLauncher.cs
|
||||
@@ -16,12 +23,17 @@ function makelauncher()
|
||||
mono ${SRCDIR}/fixheader.exe $1 > /dev/null
|
||||
}
|
||||
|
||||
echo "Compiling Windows launcher"
|
||||
makelauncher ${BUILTDIR}/OpenRA.exe "OpenRA" "" OpenRA.ico
|
||||
echo "Compiling Windows launchers"
|
||||
makelauncher ${BUILTDIR}/RedAlert.exe "Red Alert" "ra" RedAlert.ico
|
||||
makelauncher ${BUILTDIR}/TiberianDawn.exe "Tiberian Dawn" "cnc" TiberianDawn.ico
|
||||
makelauncher ${BUILTDIR}/Dune2000.exe "Dune 2000" "d2k" Dune2000.ico
|
||||
|
||||
# Windows specific icons
|
||||
cp OpenRA.ico RedAlert.ico TiberianDawn.ico Dune2000.ico ${BUILTDIR}
|
||||
|
||||
if [ -x /usr/bin/makensis ]; then
|
||||
echo "Building Windows setup.exe"
|
||||
makensis -V2 -DSRCDIR="$BUILTDIR" -DDEPSDIR="${SRCDIR}/thirdparty/download/windows" OpenRA.nsi
|
||||
makensis -V2 -DSRCDIR="$BUILTDIR" -DDEPSDIR="${SRCDIR}/thirdparty/download/windows" -DTAG="${TAG}" OpenRA.nsi
|
||||
if [ $? -eq 0 ]; then
|
||||
mv OpenRA.Setup.exe "$OUTPUTDIR"/OpenRA-$TAG.exe
|
||||
else
|
||||
@@ -30,3 +42,7 @@ if [ -x /usr/bin/makensis ]; then
|
||||
else
|
||||
echo "Skipping Windows setup.exe build due to missing NSIS"
|
||||
fi
|
||||
|
||||
# Cleanup
|
||||
rm ${BUILTDIR}/OpenRA.ico ${BUILTDIR}/RedAlert.ico ${BUILTDIR}/TiberianDawn.ico ${BUILTDIR}/Dune2000.ico
|
||||
rm ${BUILTDIR}/RedAlert.exe ${BUILTDIR}/TiberianDawn.exe ${BUILTDIR}/Dune2000.exe
|
||||
|
||||
Reference in New Issue
Block a user