diff options
author | Lluís Batlle i Rossell <viric@vicerveza.homeunix.net> | 2012-01-21 00:34:30 +0000 |
---|---|---|
committer | Lluís Batlle i Rossell <viric@vicerveza.homeunix.net> | 2012-01-21 00:34:30 +0000 |
commit | 6945a75f7b95f1c6eabb7a46479d17ea90af0794 (patch) | |
tree | 632fbc9da573324ecb797962690aa71a3e3a04eb /pkgs/development/libraries/mesa | |
parent | 09fee60ee260c468aabbc93c1321b002e7cd213d (diff) |
Adding a patch for mesa, for it to build on the loongson2f.
svn path=/nixpkgs/trunk/; revision=31749
Diffstat (limited to 'pkgs/development/libraries/mesa')
-rw-r--r-- | pkgs/development/libraries/mesa/default.nix | 3 | ||||
-rw-r--r-- | pkgs/development/libraries/mesa/mips_wmb.patch | 16 |
2 files changed, 18 insertions, 1 deletions
diff --git a/pkgs/development/libraries/mesa/default.nix b/pkgs/development/libraries/mesa/default.nix index edbde5a9b4942..8543b6324ad09 100644 --- a/pkgs/development/libraries/mesa/default.nix +++ b/pkgs/development/libraries/mesa/default.nix @@ -17,7 +17,8 @@ stdenv.mkDerivation { sha256 = "0msk1fh4yw4yi7z37v75vhpa23z49lkwgin6drczbihbqsl6lx2p"; }; - patches = [ ./swrast-settexbuffer.patch ]; + patches = [ ./swrast-settexbuffer.patch ] ++ stdenv.lib.optional + (stdenv.system == "mips64-linux") ./mips_wmb.patch; prePatch = "patchShebangs ."; diff --git a/pkgs/development/libraries/mesa/mips_wmb.patch b/pkgs/development/libraries/mesa/mips_wmb.patch new file mode 100644 index 0000000000000..1ffa1bdd8df48 --- /dev/null +++ b/pkgs/development/libraries/mesa/mips_wmb.patch @@ -0,0 +1,16 @@ +rixed told me (viric) it's the patch to apply for mesa. +I adapted his patch for mesa 7.5 to this 7.10 + +diff --git a/src/mesa/drivers/dri/sis/sis_context.h b/src/mesa/drivers/dri/sis/sis_context.h +index a82a659..d8d8d9a 100644 +--- a/src/mesa/drivers/dri/sis/sis_context.h ++++ b/src/mesa/drivers/dri/sis/sis_context.h +@@ -404,6 +404,8 @@ struct sis_context + #define MMIO_WMB() __asm __volatile("" : : : "memory") + #elif defined(__ia64__) + #define MMIO_WMB() __asm __volatile("mf" : : : "memory") ++#elif defined(__mips__) ++#define MMIO_WMB() __asm __volatile("" : : : "memory") + #else + #error platform needs WMB + #endif |