summaryrefslogtreecommitdiff
path: root/gnu/packages/patches/libmad-mips-newgcc.patch
diff options
context:
space:
mode:
authorMark H Weaver <mhw@netris.org>2013-11-01 00:15:16 -0400
committerMark H Weaver <mhw@netris.org>2013-11-03 23:26:32 -0500
commitdd863f1f39858bf9d3f1a9de4b4eccc8d3f75d62 (patch)
treea0eb1c62c78a2987f6f89efa9420580785e84d38 /gnu/packages/patches/libmad-mips-newgcc.patch
parent46acd054010134eba293c3b978e82edb9ebc21fb (diff)
downloadguix-patches-dd863f1f39858bf9d3f1a9de4b4eccc8d3f75d62.tar
guix-patches-dd863f1f39858bf9d3f1a9de4b4eccc8d3f75d62.tar.gz
gnu: libmad: Fix MIPS assembler code to work with new GCC.
* gnu/packages/patches/libmad-mips-newgcc.patch: New file. * gnu/packages/mp3.scm (libmad): Add patch. * gnu-system.am (dist_patch_DATA): Add patch.
Diffstat (limited to 'gnu/packages/patches/libmad-mips-newgcc.patch')
-rw-r--r--gnu/packages/patches/libmad-mips-newgcc.patch16
1 files changed, 16 insertions, 0 deletions
diff --git a/gnu/packages/patches/libmad-mips-newgcc.patch b/gnu/packages/patches/libmad-mips-newgcc.patch
new file mode 100644
index 0000000000..d22c51255e
--- /dev/null
+++ b/gnu/packages/patches/libmad-mips-newgcc.patch
@@ -0,0 +1,16 @@
+Fix MIPS assembly code to work with newer GCC, where the "=h"
+constraint is no longer supported.
+
+--- libmad/fixed.h.orig 2004-02-16 21:02:03.000000000 -0500
++++ libmad/fixed.h 2011-10-29 18:47:21.000000000 -0400
+@@ -304,8 +304,8 @@
+ * significant bit depends on OPT_ACCURACY via mad_f_scale64().
+ */
+ # define MAD_F_MLX(hi, lo, x, y) \
+- asm ("mult %2,%3" \
+- : "=l" (lo), "=h" (hi) \
++ asm ("mult %2,%3\n\tmfhi %1" \
++ : "=l" (lo), "=r" (hi) \
+ : "%r" (x), "r" (y))
+
+ # if defined(HAVE_MADD_ASM)