# HG changeset patch
# User sheepluva <sheepluva@users.noreply.github.com>
# Date 1420465028 -3600
# Node ID 8060cb5c2fa6f83ed3cf9ba459ac6acedbd6d704
# Parent  e5d6a6a25b7cfec32114b0ad9b12a319e1f12f50# Parent  eedd0697d55ce2406fa1696fe1b35954a6e69e5f
Merge pull request #27 from LocutusOfBorg/fix-build2

Fix arm* build failures

< LocutusOfBorg1> sheepluva, the problem is fpc, so the workaround might be necessary even if they patch it :(
http://bugs.freepascal.org/view.php?id=27222

diff -r e5d6a6a25b7c -r 8060cb5c2fa6 hedgewars/uRender.pas
--- a/hedgewars/uRender.pas	Mon Jan 05 14:05:09 2015 +0100
+++ b/hedgewars/uRender.pas	Mon Jan 05 14:37:08 2015 +0100
@@ -535,11 +535,14 @@
 end;
 
 procedure openglRotatef(RotX, RotY, RotZ: GLfloat; dir: LongInt); inline;
+{ workaround for pascal bug http://bugs.freepascal.org/view.php?id=27222 }
+var tmpdir: LongInt;
 begin
+tmpdir:=dir;
 {$IFDEF GL2}
-    hglRotatef(RotX, RotY, RotZ, dir);
+    hglRotatef(RotX, RotY, RotZ, tmpdir);
 {$ELSE}
-    glRotatef(RotX, RotY, RotZ, dir);
+    glRotatef(RotX, RotY, RotZ, tmpdir);
 {$ENDIF}
 end;