aboutsummaryrefslogtreecommitdiff
path: root/games/openra/files
diff options
context:
space:
mode:
authorJohn Marino <marino@FreeBSD.org>2014-10-31 12:54:17 +0000
committerJohn Marino <marino@FreeBSD.org>2014-10-31 12:54:17 +0000
commitd6ccfa1296b7c1e378c18506d801b3ba746d2f1c (patch)
treee931f9a864009299f3e90562589f4f50e7e782cf /games/openra/files
parentabaef20b78a6d6d169e4e6ca3e998feae6d0c2b2 (diff)
downloadports-d6ccfa1296b7c1e378c18506d801b3ba746d2f1c.tar.gz
ports-d6ccfa1296b7c1e378c18506d801b3ba746d2f1c.zip
Notes
Diffstat (limited to 'games/openra/files')
-rw-r--r--games/openra/files/patch-Makefile35
-rw-r--r--games/openra/files/patch-xamarin-bug2331925
2 files changed, 60 insertions, 0 deletions
diff --git a/games/openra/files/patch-Makefile b/games/openra/files/patch-Makefile
new file mode 100644
index 000000000000..1b0a197cee30
--- /dev/null
+++ b/games/openra/files/patch-Makefile
@@ -0,0 +1,35 @@
+# Without zenity(1) fallback to either WinForms or no crash dialog
+
+--- Makefile~
++++ Makefile
+@@ -357,10 +357,28 @@ install-linux-desktop:
+ install-linux-scripts:
+ @echo "#!/bin/sh" > openra
+ @echo 'cd "$(gameinstalldir)"' >> openra
+- @echo 'mono OpenRA.Game.exe "$$@"' >> openra
++ @echo 'ZENITY=`which zenity`' >> openra
++ @echo 'if [ -z "$$ZENITY" ] && (' >> openra
++ @echo ' # from mono/io-layer/processes.c' >> openra
++ @echo ' hash xdg-open 2>/dev/null ||' >> openra
++ @echo ' hash gnome-open 2>/dev/null ||' >> openra
++ @echo ' hash kfmclient 2>/dev/null)' >> openra
++ @echo 'then' >> openra
++ @echo ' mono OpenRA.exe "$$@"' >> openra
++ @echo 'else' >> openra
++ @echo ' mono OpenRA.Game.exe "$$@"' >> openra
++ @echo 'fi' >> openra
+ @echo 'if [ $$? != 0 ]' >> openra
+ @echo 'then' >> openra
+- @echo 'ZENITY=`which zenity` || echo "OpenRA needs zenity installed to display a graphical error dialog. See ~/.openra. for log files."' >> openra
++ @echo ' if [ -z "$$ZENITY" ]' >> openra
++ @echo ' then' >> openra
++ @echo ' echo' >> openra
++ @echo ' echo "OpenRA has encountered a fatal error."' >> openra
++ @echo ' echo "Log Files are available in ~/.openra."' >> openra
++ @echo ' echo' >> openra
++ @echo ' echo "See https://github.com/OpenRA/OpenRA/wiki/FAQ"' >> openra
++ @echo ' exit 1' >> openra
++ @echo ' fi' >> openra
+ @echo '$$ZENITY --question --title "OpenRA" --text "OpenRA has encountered a fatal error.\nLog Files are available in ~/.openra." --ok-label "Quit" --cancel-label "View FAQ" || xdg-open https://github.com/OpenRA/OpenRA/wiki/FAQ' >> openra
+ @echo 'exit 1' >> openra
+ @echo 'fi' >> openra
diff --git a/games/openra/files/patch-xamarin-bug23319 b/games/openra/files/patch-xamarin-bug23319
new file mode 100644
index 000000000000..ac51c4bd7298
--- /dev/null
+++ b/games/openra/files/patch-xamarin-bug23319
@@ -0,0 +1,25 @@
+# https://bugzilla.xamarin.com/show_bug.cgi?id=23319
+# https://github.com/mono/mono/commit/1d94d17
+
+--- OpenRA.Game/Exts.cs~
++++ OpenRA.Game/Exts.cs
+@@ -375,7 +375,7 @@ namespace OpenRA
+ for (var i = 0; i < width; i++)
+ for (var j = 0; j < height; j++)
+ result[i, j] = i <= ts.GetUpperBound(0) && j <= ts.GetUpperBound(1)
+- ? ts[i, j] : t;
++ ? (ts[i, j]) : t;
+ return result;
+ }
+
+--- OpenRA.Mods.RA/Render/WithMuzzleFlash.cs~
++++ OpenRA.Mods.RA/Render/WithMuzzleFlash.cs
+@@ -50,7 +50,7 @@ namespace OpenRA.Mods.RA.Render
+ var turreted = self.TraitsImplementing<Turreted>()
+ .FirstOrDefault(t => t.Name == arm.Info.Turret);
+
+- getFacing = turreted != null ? () => turreted.TurretFacing :
++ getFacing = turreted != null ? (() => turreted.TurretFacing) :
+ facing != null ? (Func<int>)(() => facing.Facing) : () => 0;
+
+ var muzzleFlash = new Animation(self.World, render.GetImage(self), getFacing);