add patch to fix some 64-bit issues from Tyler Montbriand via bug #66263
authorMichael Sterrett <mr_bones_@gentoo.org>
Thu, 9 Dec 2004 09:46:42 +0000 (09:46 +0000)
committerMichael Sterrett <mr_bones_@gentoo.org>
Thu, 9 Dec 2004 09:46:42 +0000 (09:46 +0000)
games-action/armagetron/ChangeLog
games-action/armagetron/Manifest
games-action/armagetron/armagetron-0.2.6.0.ebuild
games-action/armagetron/files/0.2.6.0-64bit.patch [new file with mode: 0644]

index 57fd4cc07bcbbe92cb7965e0c2af83dc5abcb3d6..c82afd3aa2ec5895f18eef26e5346805b281a6e9 100644 (file)
@@ -1,6 +1,10 @@
 # ChangeLog for games-action/armagetron
 # Copyright 2002-2004 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/games-action/armagetron/ChangeLog,v 1.6 2004/12/07 09:32:13 mr_bones_ Exp $
+# $Header: /var/cvsroot/gentoo-x86/games-action/armagetron/ChangeLog,v 1.7 2004/12/09 09:46:42 mr_bones_ Exp $
+
+  09 Dec 2004; Michael Sterrett <mr_bones_@gentoo.org>
+  +files/0.2.6.0-64bit.patch, armagetron-0.2.6.0.ebuild:
+  add patch to fix some 64-bit issues from Tyler Montbriand via bug #66263
 
   07 Dec 2004; Michael Sterrett <mr_bones_@gentoo.org>
   armagetron-0.2.6.0.ebuild:
index b9dfa4cdf85dc1a115777419c7b2f8906a7ab383..8fdf9d1f70b22e55b79cb9ceca46b960128baf22 100644 (file)
@@ -1,5 +1,5 @@
-MD5 7bbdf8cd83b959dc051b5846d77b456e ChangeLog 2841
-MD5 8abcc483a1617a96316bf53cfda824f1 armagetron-0.2.6.0.ebuild 1794
+MD5 cccf98da23c162419d94245d1161ef58 ChangeLog 3029
+MD5 2349f54428f35ca0f0ba148dac148c7a armagetron-0.2.6.0.ebuild 1834
 MD5 18f4639411b07b64d8b764c6af213eb5 metadata.xml 283
 MD5 b099d1ac147af025edade2ecdb5d4ba0 files/armagetron-0.1.4.9-Makefile.global.in.patch 400
 MD5 778ff6fa5181b49c27da527ddf9a246f files/armagetron-0.1.4.9-configure.patch 422
@@ -8,3 +8,4 @@ MD5 c3f60ccaa75a462e14fa0bca9633a2e3 files/armagetron-0.2.4-r1.sh 358
 MD5 eff25d87d4215b2dba1dcc575047cb67 files/armagetron-0.2.4.sh 425
 MD5 e28f3cbd064e6429d08a76e3b91e6afe files/armagetron-0.2_pre2.sh 434
 MD5 51635e129293b0d044d43c423a71b1d2 files/digest-armagetron-0.2.6.0 194
+MD5 b1283f2afd817f0c7e712fca4ba17d4e files/0.2.6.0-64bit.patch 3109
index 379d499778783743d94f65aed69a5db7ff25fcc6..d165d3b72fe5692ae298bb3d59720cd0197f8978 100644 (file)
@@ -1,6 +1,6 @@
 # Copyright 1999-2004 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/games-action/armagetron/armagetron-0.2.6.0.ebuild,v 1.7 2004/12/07 09:32:13 mr_bones_ Exp $
+# $Header: /var/cvsroot/gentoo-x86/games-action/armagetron/armagetron-0.2.6.0.ebuild,v 1.8 2004/12/09 09:46:42 mr_bones_ Exp $
 
 inherit games flag-o-matic
 
@@ -33,6 +33,7 @@ src_unpack() {
                -e 's/$(SYNC)/$(SYNCDISK)/' Makefile.global.in \
                || die 'sed Makefile.global.in failed'
        filter-flags -fno-exceptions
+       epatch "${FILESDIR}/${PV}-64bit.patch"
 }
 
 src_install() {
diff --git a/games-action/armagetron/files/0.2.6.0-64bit.patch b/games-action/armagetron/files/0.2.6.0-64bit.patch
new file mode 100644 (file)
index 0000000..7ec5bae
--- /dev/null
@@ -0,0 +1,69 @@
+diff --unified -r armagetron-0.2.6.0/src/engine/eWall.cpp armagetron-patch/src/engine/eWall.cpp
+--- armagetron-0.2.6.0/src/engine/eWall.cpp    2003-10-13 14:43:15.000000000 -0600
++++ armagetron-patch/src/engine/eWall.cpp      2004-10-03 15:14:47.953792336 -0600
+@@ -280,6 +280,6 @@
+ #else
+   static eWall* pwall = NULL;
+   static eWall& wall = *pwall; 
+-  return reinterpret_cast<eWall *> (reinterpret_cast<int>(&this[-viewer]) - reinterpret_cast<int>(&wall.view[0]) + reinterpret_cast<int>(&wall));
++  return reinterpret_cast<eWall *> (reinterpret_cast<long int>(&this[-viewer]) - reinterpret_cast<long int>(&wall.view[0]) + reinterpret_cast<long int>(&wall));
+ #endif
+ }
+diff --unified -r armagetron-0.2.6.0/src/network/nNetwork.cpp armagetron-patch/src/network/nNetwork.cpp
+--- armagetron-0.2.6.0/src/network/nNetwork.cpp        2003-10-14 01:38:56.000000000 -0600
++++ armagetron-patch/src/network/nNetwork.cpp  2004-10-03 15:17:14.870457608 -0600
+@@ -1618,7 +1618,7 @@
+ 
+                               //       if (peer!=id)
+                               //  con << "Changed incoming address.\n";
+-                              int lenleft = reinterpret_cast<int>(bend) - reinterpret_cast<int>(b);
++                              int lenleft = reinterpret_cast<long int>(bend) - reinterpret_cast<long int>(b);
+ 
+ #ifndef NOEXCEPT
+                               try
+@@ -1629,7 +1629,7 @@
+                                       pmess = tNEW( nMessage )(b,id,lenleft);
+                                       nMessage& mess = *pmess;
+ 
+-                                      lenleft = reinterpret_cast<int>(bend) - reinterpret_cast<int>(b);
++                                      lenleft = reinterpret_cast<long int>(bend) - reinterpret_cast<long int>(b);
+ 
+                                       bool mess_is_new=true;
+                                       // see if we have got this packet before
+diff --unified -r armagetron-0.2.6.0/src/network/nServerInfo.cpp armagetron-patch/src/network/nServerInfo.cpp
+--- armagetron-0.2.6.0/src/network/nServerInfo.cpp     2003-10-13 14:43:15.000000000 -0600
++++ armagetron-patch/src/network/nServerInfo.cpp       2004-10-03 15:16:02.983386104 -0600
+@@ -403,8 +403,8 @@
+       static nServerInfo& info = *this; // will not cause recursion since it is called only once.
+       // uaaa. Pointer magic...
+       return reinterpret_cast<nServerInfo *>
+-              ( reinterpret_cast<int> (anchor) -
+-                reinterpret_cast<int> (&info.next) + reinterpret_cast<int>( &info )
++              ( reinterpret_cast<long int> (anchor) -
++                reinterpret_cast<long int> (&info.next) + reinterpret_cast<long int>( &info )
+                 );
+ }
+ 
+diff --unified -r armagetron-0.2.6.0/src/network/net_udp.cpp armagetron-patch/src/network/net_udp.cpp
+--- armagetron-0.2.6.0/src/network/net_udp.cpp 2003-10-13 14:43:15.000000000 -0600
++++ armagetron-patch/src/network/net_udp.cpp   2004-10-03 15:19:34.741194024 -0600
+@@ -420,7 +420,8 @@
+ 
+ int ANET_Read (int& sock, int8 *buf, int len, struct sockaddr *addr)
+ {
+-  NET_SIZE addrlen = sizeof (struct sockaddr);
++//  NET_SIZE addrlen = sizeof (struct sockaddr);
++  socklen_t addrlen = (socklen_t)sizeof (struct sockaddr);
+ 
+   int ret;
+   
+@@ -541,7 +542,8 @@
+ 
+ int ANET_GetSocketAddr (int sock, struct sockaddr *addr)
+ {
+-  NET_SIZE addrlen = sizeof(struct sockaddr);
++//  NET_SIZE addrlen = sizeof(struct sockaddr);
++  socklen_t addrlen = (socklen_t)sizeof(struct sockaddr);
+   unsigned int a;
+   
+   memset(addr, 0, sizeof(struct sockaddr));