Home > OS >  How the CmakeLists. Implement LOCAL_CFLAGS TXT:=-fvisibility=hidden hidden symbol table
How the CmakeLists. Implement LOCAL_CFLAGS TXT:=-fvisibility=hidden hidden symbol table

Time:11-24

Everybody is good:
In Android. Mk file to add a LOCAL_CFLAGS:=-fvisibility=hidden, can achieve the effect of symbol table, hidden yes export function does not display in the IDA, now in the latest version of the Android Studio in CmakeLists. TXT to implement? I know Android Studio can also use the Android. Mk, this wants to achieve in Cmake,

CodePudding user response:

To ask ah, don't know whether that is
Set (LOCAL_CFLAGS -fvisibility="hidden")

CodePudding user response:

Google to this
C: set (CMAKE_C_VISIBILITY_PRESET hidden)
C + + : set (CMAKE_CXX_VISIBILITY_PRESET hidden)
Try as if can use

CodePudding user response:

Thank you very much needed

CodePudding user response:

refer to the second floor spydh response:
Google to this
C: set (CMAKE_C_VISIBILITY_PRESET hidden)
C + + : set (CMAKE_CXX_VISIBILITY_PRESET hidden)
Try as if can use


And deceptive "?????

CodePudding user response:

reference 4 floor diybl response:
Quote: refer to the second floor spydh response:

Google to this
C: set (CMAKE_C_VISIBILITY_PRESET hidden)
C + + : set (CMAKE_CXX_VISIBILITY_PRESET hidden)
Try as if can use


And deceptive "?????

Why I traps, I test can ah, in CMakeList. TXT and set (CMAKE_C_VISIBILITY_PRESET hidden) this sentence useful ah,

CodePudding user response:

reference 5 floor spydh reply:
Quote: refer to 4th floor diybl response:

Quote: refer to the second floor spydh response:

Google to this
C: set (CMAKE_C_VISIBILITY_PRESET hidden)
C + + : set (CMAKE_CXX_VISIBILITY_PRESET hidden)
Try as if can use


And deceptive "?????

Why I traps, I test can ah, in CMakeList. TXT and set (CMAKE_C_VISIBILITY_PRESET hidden) this sentence useful ah,

This didn't effect
The last was solved strip

CodePudding user response:

refer to 6th floor diybl response:
Quote: refer to the fifth floor spydh reply:

Quote: refer to 4th floor diybl response:

Quote: refer to the second floor spydh response:

Google to this
C: set (CMAKE_C_VISIBILITY_PRESET hidden)
C + + : set (CMAKE_CXX_VISIBILITY_PRESET hidden)
Try as if can use


And deceptive "?????

Why I traps, I test can ah, in CMakeList. TXT and set (CMAKE_C_VISIBILITY_PRESET hidden) this sentence useful ah,

This didn't effect
Finally solved strip

Excuse me, is how you use strip

CodePudding user response:

Write a batch strip

refer to 7th floor qq372848728 response:
Quote: refer to the sixth floor diybl response:

Quote: refer to the fifth floor spydh reply:

Quote: refer to 4th floor diybl response:

Quote: refer to the second floor spydh response:

Google to this
C: set (CMAKE_C_VISIBILITY_PRESET hidden)
C + + : set (CMAKE_CXX_VISIBILITY_PRESET hidden)
Try as if can use


And deceptive "?????

Why I traps, I test can ah, in CMakeList. TXT and set (CMAKE_C_VISIBILITY_PRESET hidden) this sentence useful ah,

This didn't effect
Finally solved strip

Excuse me, how are you using strip

CodePudding user response:

Using add_definitions (" ") :
Example:
If you need to control in the code # define DEBUG_FLAGS
So the Android. Mk is:
LOCAL_CFALGS:=- DDEBUG_FLAGS
In CMakeLists. TXT is:
- DDEBUG_FLAGS add_definitions (" ");
Other situations and so on,

CodePudding user response:

Set (CMAKE_C_VISIBILITY_PRESET hidden)
Set (CMAKE_CXX_VISIBILITY_PRESET hidden)

With the use, the internal use of library interface hides
  • Related