]> code.ossystems Code Review - openembedded-core.git/commitdiff
clutter-1.6: make build for armv4t
authorWolfgang Denk <wd@denx.de>
Thu, 22 Dec 2011 09:21:09 +0000 (10:21 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 30 Jan 2012 16:39:07 +0000 (16:39 +0000)
GCC will define __ARM_ARCH_4T__ when building with "-march=armv4t" so
we can check this to turn off the use of 'clz' instructions, which
otherwise would cause compile errors like "selected processor does
not support ARM mode `clz r3,r0'".

Signed-off-by: Wolfgang Denk <wd@denx.de>
meta/recipes-graphics/clutter/clutter-1.6_1.6.14.bb
meta/recipes-graphics/clutter/clutter/fix_build_for_armv4t.patch [new file with mode: 0644]

index 555133f4829938770053d62723452c2e99b5085b..0aacf0f4a55157f952a8ca2290d377adbbf59272 100644 (file)
@@ -1,6 +1,6 @@
 require recipes-graphics/clutter/clutter.inc
 
-PR = "r2"
+PR = "r3"
 
 # Internal json-glib was removed in Clutter 1.5.2
 STDDEPENDS += "json-glib"
@@ -10,7 +10,9 @@ FILES_${PN}-examples = "${bindir}/test-* ${pkgdatadir}/redhand.png"
 
 SRC_URI = "http://source.clutter-project.org/sources/clutter/1.6/clutter-${PV}.tar.bz2 \
            file://enable_tests-1.4.patch \
-           file://update_gettext_macro_version.patch"
+           file://update_gettext_macro_version.patch \
+          file://fix_build_for_armv4t.patch \
+          "
 
 LIC_FILES_CHKSUM = "file://COPYING;md5=7fbc338309ac38fefcd64b04bb903e34"
 S = "${WORKDIR}/clutter-${PV}"
diff --git a/meta/recipes-graphics/clutter/clutter/fix_build_for_armv4t.patch b/meta/recipes-graphics/clutter/clutter/fix_build_for_armv4t.patch
new file mode 100644 (file)
index 0000000..28cbfa2
--- /dev/null
@@ -0,0 +1,11 @@
+--- clutter-1.6.14/clutter/cogl/cogl/cogl-fixed.c.ORIG 2011-03-22 15:46:17.000000000 +0100
++++ clutter-1.6.14/clutter/cogl/cogl/cogl-fixed.c      2011-12-22 09:26:10.650427310 +0100
+@@ -626,7 +626,7 @@
+       /*
+        * Find the highest bit set
+        */
+-#if __arm__
++#if __arm__ && !defined(__ARM_ARCH_4T__)
+       /* This actually requires at least arm v5, but gcc does not seem
+        * to set the architecture defines correctly, and it is I think
+        * very unlikely that anyone will want to use clutter on anything