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
commit ffa65ba8f0

View file

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