All of lore.kernel.org
 help / color / mirror / Atom feed
From: Khem Raj <raj.khem@gmail.com>
To: openembedded-core@lists.openembedded.org
Subject: [PATCH 11/14] xserver-xorg: Fix build for mips64
Date: Sun, 20 May 2012 20:35:46 -0700	[thread overview]
Message-ID: <de21917ba83f104a2d53941f40a9b2b8d35dce49.1337570904.git.raj.khem@gmail.com> (raw)
In-Reply-To: <77dc886107e1b9cdaf6803141dc97c3ebfc22910.1337570904.git.raj.khem@gmail.com>
In-Reply-To: <cover.1337570904.git.raj.khem@gmail.com>

mips64 N64 ABI has different size for int and pointer
which means the compiler will complain about conversions
which works fine for 32 bit since sizes are same.

amd64 is taken care of already so we take care of mips64
with this patch by understanding the difference in sizes
in compiler.h

Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 .../xorg-xserver/xserver-xorg-1.11.2.inc           |    1 +
 .../xserver-xorg-1.11.2/mips64-compiler.patch      |   29 ++++++++++++++++++++
 2 files changed, 30 insertions(+), 0 deletions(-)
 create mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg-1.11.2/mips64-compiler.patch

diff --git a/meta/recipes-graphics/xorg-xserver/xserver-xorg-1.11.2.inc b/meta/recipes-graphics/xorg-xserver/xserver-xorg-1.11.2.inc
index fc41568..595ab77 100644
--- a/meta/recipes-graphics/xorg-xserver/xserver-xorg-1.11.2.inc
+++ b/meta/recipes-graphics/xorg-xserver/xserver-xorg-1.11.2.inc
@@ -2,6 +2,7 @@
 SRC_URI += "file://crosscompile.patch \
             file://fix_open_max_preprocessor_error.patch \
             file://gcc-47-warning.patch \
+	    file://mips64-compiler.patch \
            "
 
 SRC_URI[md5sum] = "8796fff441e5435ee36a72579008af24"
diff --git a/meta/recipes-graphics/xorg-xserver/xserver-xorg-1.11.2/mips64-compiler.patch b/meta/recipes-graphics/xorg-xserver/xserver-xorg-1.11.2/mips64-compiler.patch
new file mode 100644
index 0000000..e6bc95b
--- /dev/null
+++ b/meta/recipes-graphics/xorg-xserver/xserver-xorg-1.11.2/mips64-compiler.patch
@@ -0,0 +1,29 @@
+on mips64/n64 pointers are 64bit therefore the pointer conversions to int dont work well
+so we end up with incompatible conversion errors
+
+This patch choses the right values for mips64
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Upstream-Status: Pending
+Index: xorg-server-1.11.2/hw/xfree86/common/compiler.h
+===================================================================
+--- xorg-server-1.11.2.orig/hw/xfree86/common/compiler.h	2012-05-10 12:19:59.485599046 -0700
++++ xorg-server-1.11.2/hw/xfree86/common/compiler.h	2012-05-10 12:20:53.109602488 -0700
+@@ -104,6 +104,7 @@
+ 
+ #  if !defined(__arm__)
+ #   if !defined(__sparc__) && !defined(__sparc) && !defined(__arm32__) && !defined(__nds32__) \
++      && !defined(__mips64) \
+       && !(defined(__alpha__) && defined(linux)) \
+       && !(defined(__ia64__) && defined(linux)) \
+ 
+@@ -708,7 +709,7 @@
+ }
+ 
+ #   elif defined(__mips__) || (defined(__arm32__) && !defined(__linux__))
+-#    ifdef __arm32__
++#    if defined (__arm32__) || defined (__mips64)
+ #     define PORT_SIZE long
+ #    else
+ #     define PORT_SIZE short
-- 
1.7.5.4




  parent reply	other threads:[~2012-05-21  3:46 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-21  3:35 [RFC][PATCH 00/14] mips64 support and sh4 support Khem Raj
2012-05-21  3:35 ` [PATCH 01/14] insane.bbclass: Add mips64{el} to known machines Khem Raj
2012-05-21  3:35 ` [PATCH 02/14] site: Add mips64 eglibc and uclibc site files Khem Raj
2012-05-21  3:35 ` [PATCH 03/14] gcc-4.6, gcc-4.7: Add support for building mips64 cross compiler Khem Raj
2012-05-21  3:35 ` [PATCH 04/14] binutils: Default to n64 when configured for mips64 Khem Raj
2012-05-21  3:35 ` [PATCH 05/14] kernel-arch.bbclass: Map mips64{el} to mips KARCH Khem Raj
2012-05-21  3:35 ` [PATCH 06/14] eglibc-2.15: Support mips64 Khem Raj
2012-05-21  3:35 ` [PATCH 07/14] libc-package: Add sh4 and mips64 to arch options Khem Raj
2012-05-21  3:35 ` [PATCH 08/14] runqemu: Add qemush4 and qemumips64 knowledge Khem Raj
2012-05-21  3:35 ` [PATCH 09/14] netbase: Add interface files for qemumips64 and qemush4 Khem Raj
2012-05-21  3:35 ` [PATCH 10/14] site/sh-common: Add missing caches variables to build glib-2.32 Khem Raj
2012-05-21  3:35 ` Khem Raj [this message]
2012-05-21  3:35 ` [PATCH 12/14] tune-mips64.inc: Add new tune file for mips64 big-endian Khem Raj
2012-05-21  3:35 ` [PATCH 13/14] qemumips64.conf: Add machine configuration for mips64(eb) Khem Raj
2012-05-21  3:35 ` [PATCH 14/14] qemush4.conf: Add machine configuration for qemush4 Khem Raj
2012-05-21  8:21 ` [RFC][PATCH 00/14] mips64 support and sh4 support Richard Purdie
2012-05-21 14:36   ` Khem Raj
2012-05-21 15:51   ` Mark Hatle
2012-05-21 12:43 ` Bruce Ashfield

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=de21917ba83f104a2d53941f40a9b2b8d35dce49.1337570904.git.raj.khem@gmail.com \
    --to=raj.khem@gmail.com \
    --cc=openembedded-core@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.