2

Android ndk-build options : Is there any flag(s) or option(s) which can be set during build process in order to remove symbol table information from ".so" file ?

This question Is it possible to remove symbols from a shared library built with Android NDK? gives answer to change code but I need something like "strip" utility performs because I don't have source code with me.

Community
  • 1
  • 1
avenger
  • 156
  • 1
  • 10

1 Answers1

3

NDK gives you the necessary tool. Choose the appropriate toolchain (e.g. arm GCC 4.8) and run (from command line)

$(NDK_ROOT)/toolchains/arm-linux-android-4.8/prebuilt/darwin-x86_64/bin/arm-linux-android-objcopy -N foo a.so

See How can I remove a symbol from a shared object? for more details.

Community
  • 1
  • 1
Alex Cohn
  • 56,089
  • 9
  • 113
  • 307