summaryrefslogtreecommitdiff
path: root/games
diff options
context:
space:
mode:
authorwiedi <wiedi>2014-02-09 17:12:33 +0000
committerwiedi <wiedi>2014-02-09 17:12:33 +0000
commit59cfb021a222708a58af0aea904cf19aa245acc3 (patch)
tree76841cd4119826e9c119fc9636757e68cc61a3da /games
parent3922e48150eaad4d80c4904eef8d02eaea70b8b0 (diff)
downloadpkgsrc-59cfb021a222708a58af0aea904cf19aa245acc3.tar.gz
fix "sqrt(int) is ambiguous" on SunOS
Diffstat (limited to 'games')
-rw-r--r--games/lbreakout/distinfo3
-rw-r--r--games/lbreakout/patches/patch-lbreakout_breakout.cpp23
2 files changed, 25 insertions, 1 deletions
diff --git a/games/lbreakout/distinfo b/games/lbreakout/distinfo
index abafb5a0c32..392ac472560 100644
--- a/games/lbreakout/distinfo
+++ b/games/lbreakout/distinfo
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.10 2010/01/29 23:35:57 joerg Exp $
+$NetBSD: distinfo,v 1.11 2014/02/09 17:12:33 wiedi Exp $
SHA1 (lbreakout-010315.tar.gz) = 9385f4690aee645955acb23d8481957aaaf0e2fb
RMD160 (lbreakout-010315.tar.gz) = ecb5784ec9475766035fabd84609c8a71581219d
@@ -6,3 +6,4 @@ Size (lbreakout-010315.tar.gz) = 655418 bytes
SHA1 (patch-aa) = 42dbfbf5cdbbe72b652319dc7e43867fa1907c76
SHA1 (patch-ab) = 5eb50dd1e4925ac9ad9469b03b92ca351baad305
SHA1 (patch-ac) = 0dd6692789e41eb0f32d34dc2f4efd9efc1fec8a
+SHA1 (patch-lbreakout_breakout.cpp) = d52bdbd16a9a764c954d7fc52d39bd78eb183495
diff --git a/games/lbreakout/patches/patch-lbreakout_breakout.cpp b/games/lbreakout/patches/patch-lbreakout_breakout.cpp
new file mode 100644
index 00000000000..abd6eaf3b1d
--- /dev/null
+++ b/games/lbreakout/patches/patch-lbreakout_breakout.cpp
@@ -0,0 +1,23 @@
+$NetBSD: patch-lbreakout_breakout.cpp,v 1.1 2014/02/09 17:12:33 wiedi Exp $
+
+fix "sqrt(int) is ambiguous" on SunOS
+--- lbreakout/breakout.cpp.orig 2001-03-15 15:27:33.000000000 +0000
++++ lbreakout/breakout.cpp
+@@ -1437,7 +1437,7 @@ void BreakOut::Club_HandleContact(Ball *
+ b->club_con = 1;
+
+ if (a.x != 0 && a.y != 0) {
+- d = sqrt(2);
++ d = sqrt((double)2);
+ a.x /= d; a.y /= d;
+ }
+
+@@ -1557,7 +1557,7 @@ void BreakOut::Ball_CheckBrickReflection
+
+ // norm //
+ if (a.x != 0 && a.y != 0) {
+- d = sqrt(2);
++ d = sqrt((double)2);
+ a.x /= d; a.y /= d;
+ }
+