Patchwork [44/50] clutter-box2d: Replace use of finite macro with C99 compliant isfinite()

login
register
mail settings
Submitter Saul Wold
Date July 20, 2011, 8:28 a.m.
Message ID <6553480f1a0d19545d688460b1f6ad8cf42daa05.1311150183.git.sgw@linux.intel.com>
Download mbox | patch
Permalink /patch/8025/
State New, archived
Headers show

Comments

Saul Wold - July 20, 2011, 8:28 a.m.
From: Khem Raj <raj.khem@gmail.com>

Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 .../clutter/clutter-box2d-1.6_0.10.0.bb            |    6 ++++--
 .../clutter/clutter-box2d/isfinite.patch           |   19 +++++++++++++++++++
 2 files changed, 23 insertions(+), 2 deletions(-)
 create mode 100644 meta/recipes-graphics/clutter/clutter-box2d/isfinite.patch

Patch

diff --git a/meta/recipes-graphics/clutter/clutter-box2d-1.6_0.10.0.bb b/meta/recipes-graphics/clutter/clutter-box2d-1.6_0.10.0.bb
index ad94aa5..a0024d0 100644
--- a/meta/recipes-graphics/clutter/clutter-box2d-1.6_0.10.0.bb
+++ b/meta/recipes-graphics/clutter/clutter-box2d-1.6_0.10.0.bb
@@ -1,11 +1,13 @@ 
 require clutter-box2d.inc
 
-PR = "r0"
+PR = "r1"
 
 DEPENDS += "clutter-1.6"
 
 SRC_URI = "http://source.clutter-project.org/sources/clutter-box2d/0.10/clutter-box2d-${PV}.tar.bz2 \
-           file://fix-disable-introspection.patch"
+           file://fix-disable-introspection.patch \
+           file://isfinite.patch \
+          "
 
 S = "${WORKDIR}/clutter-box2d-${PV}"
 
diff --git a/meta/recipes-graphics/clutter/clutter-box2d/isfinite.patch b/meta/recipes-graphics/clutter/clutter-box2d/isfinite.patch
new file mode 100644
index 0000000..fd2bf74
--- /dev/null
+++ b/meta/recipes-graphics/clutter/clutter-box2d/isfinite.patch
@@ -0,0 +1,19 @@ 
+_finite is obsoleted and C99 has isfinite instead so we should use it
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Upstream-Status: Pending
+
+Index: clutter-box2d-0.10.0/box2d/Source/Common/b2Math.h
+===================================================================
+--- clutter-box2d-0.10.0.orig/box2d/Source/Common/b2Math.h	2008-12-16 06:42:10.000000000 -0800
++++ clutter-box2d-0.10.0/box2d/Source/Common/b2Math.h	2011-07-17 02:10:29.833825198 -0700
+@@ -60,7 +60,7 @@
+ #ifdef _MSC_VER
+ 	return _finite(x) != 0;
+ #else
+-	return finite(x) != 0;
++	return std::isfinite(x) != 0;
+ #endif
+ }
+