summaryrefslogtreecommitdiff
path: root/libavcodec/ppc/asm.S
diff options
context:
space:
mode:
Diffstat (limited to 'libavcodec/ppc/asm.S')
-rw-r--r--libavcodec/ppc/asm.S8
1 files changed, 7 insertions, 1 deletions
diff --git a/libavcodec/ppc/asm.S b/libavcodec/ppc/asm.S
index 700aa0d340..6222b8be06 100644
--- a/libavcodec/ppc/asm.S
+++ b/libavcodec/ppc/asm.S
@@ -24,6 +24,12 @@
#define JOIN(a, b) GLUE(a, b)
#define X(s) JOIN(EXTERN_ASM, s)
+#if __APPLE__
+#define R(n) r ## n
+#else
+#define R(n) n
+#endif
+
#if ARCH_PPC64
#define PTR .quad
@@ -53,7 +59,7 @@ L(\name):
.endm
.macro movrel rd, sym, gp
- ld \rd, \sym@got(2)
+ ld \rd, \sym@got(R(2))
.endm
.macro get_got rd