From 0e4ad31902f206e2c6945632bb1f558eae941ff1 Mon Sep 17 00:00:00 2001 From: notaz Date: Wed, 3 May 2017 02:52:15 +0300 Subject: use pc-relative offsets for PIC too --- plugins/dfsound/arm_utils.S | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'plugins/dfsound/arm_utils.S') diff --git a/plugins/dfsound/arm_utils.S b/plugins/dfsound/arm_utils.S index eaeca51..8ac7c30 100644 --- a/plugins/dfsound/arm_utils.S +++ b/plugins/dfsound/arm_utils.S @@ -10,7 +10,7 @@ #include "arm_features.h" -#ifdef __MACH__ +#ifdef TEXRELS_FORBIDDEN .data .align 2 ptr_ChanBuf: .word ESYM(ChanBuf) @@ -20,14 +20,14 @@ ptr_ChanBuf: .word ESYM(ChanBuf) .align 2 .macro load_varadr reg var -#if defined(HAVE_ARMV7) && !defined(__PIC__) - movw \reg, #:lower16:ESYM(\var) - movt \reg, #:upper16:ESYM(\var) -#elif defined(HAVE_ARMV7) && defined(__MACH__) +#if defined(HAVE_ARMV7) && defined(TEXRELS_FORBIDDEN) movw \reg, #:lower16:(ptr_\var-(1678f+8)) movt \reg, #:upper16:(ptr_\var-(1678f+8)) 1678: ldr \reg, [pc, \reg] +#elif defined(HAVE_ARMV7) && !defined(__PIC__) + movw \reg, #:lower16:ESYM(\var) + movt \reg, #:upper16:ESYM(\var) #else ldr \reg, =ESYM(\var) #endif -- cgit v1.2.3