summaryrefslogtreecommitdiff
path: root/libc/tools/symbols.py
diff options
context:
space:
mode:
authorScott Lobdell <slobdell@google.com>2021-04-25 19:53:00 +0000
committerScott Lobdell <slobdell@google.com>2021-04-25 19:53:00 +0000
commitdfa7c0a9b59c4ef591f46f7624dfe687c2bb0a6c (patch)
tree4b78af6f79fb9de2a712ac6268059bf838000a40 /libc/tools/symbols.py
parent987dccb5f063052171fae7a59cbf9fca808f8f80 (diff)
parent4626df89bfb561fc06d805e04d040a15f378919f (diff)
Merge SP1A.210425.001
Change-Id: If71c56f3e2e9fbbeffc7096a560a5ef8b8cd8566
Diffstat (limited to 'libc/tools/symbols.py')
-rw-r--r--libc/tools/symbols.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/libc/tools/symbols.py b/libc/tools/symbols.py
index 3f40aad99..145753421 100644
--- a/libc/tools/symbols.py
+++ b/libc/tools/symbols.py
@@ -41,7 +41,8 @@ def GetFromElf(elf_file, sym_type='--dyn-syms'):
symbols = set()
- output = subprocess.check_output(['readelf', sym_type, '-W', elf_file])
+ output = subprocess.check_output(['readelf', sym_type, '-W', elf_file],
+ text=True)
for line in output.split('\n'):
if ' HIDDEN ' in line or ' UND ' in line:
continue
@@ -76,6 +77,10 @@ def GetFromAndroidSo(files):
if not os.path.isdir(lib_dir):
lib_dir = os.path.join(out_dir, 'system/lib')
+ lib_dir = os.path.join(out_dir, 'apex/com.android.runtime/lib64/bionic/')
+ if not os.path.isdir(lib_dir):
+ lib_dir = os.path.join(out_dir, 'apex/com.android.runtime/lib/bionic/')
+
results = set()
for f in files:
results |= GetFromElf(os.path.join(lib_dir, f))