Merge "Only link the MTE notes against executables."

This commit is contained in:
Peter Collingbourne
2021-04-12 21:26:05 +00:00
committed by Gerrit Code Review

View File

@@ -211,10 +211,12 @@ endif
ifneq ($(filter memtag_heap,$(my_sanitize)),) ifneq ($(filter memtag_heap,$(my_sanitize)),)
# Add memtag ELF note. # Add memtag ELF note.
ifneq ($(filter memtag_heap,$(my_sanitize_diag)),) ifneq ($(filter EXECUTABLES NATIVE_TESTS,$(LOCAL_MODULE_CLASS)),)
my_whole_static_libraries += note_memtag_heap_sync ifneq ($(filter memtag_heap,$(my_sanitize_diag)),)
else my_whole_static_libraries += note_memtag_heap_sync
my_whole_static_libraries += note_memtag_heap_async else
my_whole_static_libraries += note_memtag_heap_async
endif
endif endif
# This is all that memtag_heap does - it is not an actual -fsanitize argument. # This is all that memtag_heap does - it is not an actual -fsanitize argument.
# Remove it from the list. # Remove it from the list.