rpms/csmash/devel csmash-0.6.6-64bit-gcc4-fixes.patch, NONE, 1.1 csmash.spec, 1.6, 1.7 csmash-0.6.6-64bit-fixes.patch, 1.1, NONE

Matthias Saou (thias) fedora-extras-commits at redhat.com
Tue May 3 11:05:20 UTC 2005


Author: thias

Update of /cvs/extras/rpms/csmash/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv1738

Modified Files:
	csmash.spec 
Added Files:
	csmash-0.6.6-64bit-gcc4-fixes.patch 
Removed Files:
	csmash-0.6.6-64bit-fixes.patch 
Log Message:
Include gcc4 fixes.


csmash-0.6.6-64bit-gcc4-fixes.patch:

--- NEW FILE csmash-0.6.6-64bit-gcc4-fixes.patch ---
diff -urN ../tmp-orig/csmash-0.6.6/matrix ./matrix
--- csmash-0.6.6.orig/matrix	2002-03-06 17:46:01.000000000 +0100
+++ csmash-0.6.6/matrix	2005-01-06 19:43:32.037852232 +0100
@@ -42,15 +42,6 @@
 
 /* __BEGIN__BEGIN__ */
 //__NAMESPACE_BEGIN(ese);
-#if (!defined __GNUG__) || (__GNUC__ == 3)
-template<typename T>
-void swap(T& a, T& b)
-{
-    T c = a;
-    a = b;
-    b = c;
-}
-#endif
 
 // matrix_size MUST BE larger than 1
 template<int matrix_size, typename _float_t = float>
@@ -174,9 +165,10 @@
 		    mx = x;
 		}
 	    }
-	    swap(pivot[k], pivot[piv]);
 
 	    int kk = pivot[k];
+            pivot[k] = pivot[piv];
+            pivot[piv] = kk;
 	    float_t t = m[kk][kk];
 	    if (0 == t) {
 		return 0;
@@ -222,9 +214,10 @@
 		    mx = x;
 		}
 	    }
-	    swap(pivot[k], pivot[piv]);
 
 	    int kk = pivot[kk];
+	    pivot[k] = pivot[piv];
+	    pivot[piv] = kk;
 	    double t = a[kk][kk];
 	    if (0 == t) {
 		return 0;
@@ -283,7 +276,8 @@
 	    }
 	    ik = ip[j];
 	    if (j != k) {
-		swap(ip[j], ip[k]);
+		ip[j] = ip[k];
+		ip[k] = ik;
 		det = -det;
 	    }
 	    u = a[ik][k];


Index: csmash.spec
===================================================================
RCS file: /cvs/extras/rpms/csmash/devel/csmash.spec,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- csmash.spec	6 Apr 2005 22:11:36 -0000	1.6
+++ csmash.spec	3 May 2005 11:05:18 -0000	1.7
@@ -1,13 +1,12 @@
 Summary: 3D tabletennis game
 Name: csmash
 Version: 0.6.6
-Release: 6
-
+Release: 7
 License: GPL
 Group: Amusements/Games
 URL: http://cannonsmash.sourceforge.net/
 Source: http://dl.sf.net/cannonsmash/csmash-%{version}.tar.gz
-Patch: csmash-0.6.6-64bit-fixes.patch
+Patch: csmash-0.6.6-64bit-gcc4-fixes.patch
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
 BuildRequires: Mesa-devel, libjpeg-devel, zlib-devel, gtk2-devel >= 2.0.0
 BuildRequires: SDL-devel >= 1.2.0, SDL_mixer-devel, SDL_image-devel
@@ -22,7 +21,7 @@
 
 %prep
 %setup
-%patch -p0 -b .64bit
+%patch -p1 -b .64bit-gcc4
 
 
 %build
@@ -68,8 +67,8 @@
 
 
 %changelog
-* Fri Apr  7 2005 Michael Schwendt <mschwendt[AT]users.sf.net>
-- rebuilt
+* Tue May  3 2005 Matthias Saou <http://freshrpms.net/> 0.6.6-7
+- Update 64bit patch to add gcc4 fixes too (from Debian bug #289015).
 
 * Tue Nov 16 2004 Matthias Saou <http://freshrpms.net/> 0.6.6-5
 - Bump release to provide Extras upgrade path.


--- csmash-0.6.6-64bit-fixes.patch DELETED ---




More information about the fedora-extras-commits mailing list