OSDN Git Service

Android: only add notext to x86
authorChih-Wei Huang <cwhuang@linux.org.tw>
Thu, 5 Dec 2019 10:18:30 +0000 (18:18 +0800)
committerChih-Wei Huang <cwhuang@linux.org.tw>
Thu, 5 Dec 2019 10:18:30 +0000 (18:18 +0800)
The flag adds text relocations to the shared library.
However, x86_64 should not have it.

android/build.mk

index ac81d88..c09c1da 100644 (file)
@@ -74,7 +74,8 @@ LOCAL_CFLAGS += \
 LOCAL_ASFLAGS_x86 := -Pconfig-x86.asm
 LOCAL_ASFLAGS_x86_64 := -Pconfig-x86_64.asm
 
-LOCAL_LDFLAGS := -Wl,--no-fatal-warnings -Wl,-Bsymbolic -Wl,-z,notext
+LOCAL_LDFLAGS := -Wl,--no-fatal-warnings -Wl,-Bsymbolic
+LOCAL_LDFLAGS_x86 := -Wl,-z,notext
 
 LOCAL_CLANG_CFLAGS += -Wno-unknown-attributes
 LOCAL_CLANG_ASFLAGS += $(if $(filter x86,$(FFMPEG_ARCH_DIR)),,-no-integrated-as)