Force everything to use python3 for consistency.
Rather than "whatever people have installed as 'python' on their machine".
I've removed check-symbols.py because that's been broken for years and
we never even noticed, and I'm not sure it's worth fixing.
Test: treehugger, manual
Change-Id: Ieb996bbdf790a18d4b1fb46a409cc240ba2a2a49
diff --git a/libc/tools/symbols.py b/libc/tools/symbols.py
index 3f40aad..1457534 100644
--- a/libc/tools/symbols.py
+++ b/libc/tools/symbols.py
@@ -41,7 +41,8 @@
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 @@
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))