From 275dee1cfd4d40b121ef4c74629db38d7498e9df Mon Sep 17 00:00:00 2001 From: Jian Wang Date: Tue, 08 Mar 2016 09:29:49 +0000 Subject: PD#118065: cts: fixed amffmpeg has text relocations error merged from newer ffmpeg: commit f963f80399deb1a2b44c1bac3af7123e8a0c9e46 Author: Martin Storsjo Date: Sun Nov 16 12:51:54 2014 +0200 arm: Use .data.rel.ro for const data with relocations Signed-off-by: Martin Storsjo Change-Id: I086d3affaeaf5a3ce8b08e4826dd1a9ec75a60ed --- diff --git a/config.h b/config.h index 085588f..abe0d98 100644 --- a/config.h +++ b/config.h @@ -258,6 +258,7 @@ #define HAVE_SARESTART 1 #define HAVE_SCHED_GETAFFINITY 0 #define HAVE_SDL 0 +#define HAVE_SECTION_DATA_REL_RO 1 #define HAVE_SETCONSOLETEXTATTRIBUTE 0 #define HAVE_SETMODE 0 #define HAVE_SETRLIMIT 1 diff --git a/configure b/configure index af322f5..25d58da 100755 --- a/configure +++ b/configure @@ -1514,6 +1514,7 @@ HAVE_LIST=" sarestart sched_getaffinity sdl + section_data_rel_ro SetConsoleTextAttribute setmode setrlimit @@ -3635,6 +3636,7 @@ case $target_os in add_cppflags -U__STRICT_ANSI__ ;; linux) + enable section_data_rel_ro enable dv1394 ;; irix*) diff --git a/libavcodec/arm/fft_fixed_neon.S b/libavcodec/arm/fft_fixed_neon.S index d4a38a2..c0a14a0 100644 --- a/libavcodec/arm/fft_fixed_neon.S +++ b/libavcodec/arm/fft_fixed_neon.S @@ -242,7 +242,7 @@ function ff_fft_fixed_calc_neon, export=1 bx r3 endfunc -const fft_fixed_tab_neon +const fft_fixed_tab_neon, relocate=1 .word fft4_neon .word fft8_neon .word fft16_neon diff --git a/libavcodec/arm/fft_neon.S b/libavcodec/arm/fft_neon.S index 8b9ae2a..48f8dfc 100644 --- a/libavcodec/arm/fft_neon.S +++ b/libavcodec/arm/fft_neon.S @@ -348,7 +348,7 @@ function ff_fft_permute_neon, export=1 pop {r4,pc} endfunc -const fft_tab_neon +const fft_tab_neon, relocate=1 .word fft4_neon .word fft8_neon .word fft16_neon diff --git a/libavutil/arm/asm.S b/libavutil/arm/asm.S index 9cdcce9..2b0d0f6 100644 --- a/libavutil/arm/asm.S +++ b/libavutil/arm/asm.S @@ -79,12 +79,16 @@ ELF .type \name, %function \name: .endm -.macro const name, align=2 +.macro const name, align=2, relocate=0 .macro endconst ELF .size \name, . - \name .purgem endconst .endm +.if HAVE_SECTION_DATA_REL_RO && \relocate + .section .data.rel.ro +.else .section .rodata +.endif .align \align \name: .endm -- cgit