summaryrefslogtreecommitdiff
path: root/libc/tools/genversion-scripts.py
diff options
context:
space:
mode:
authorDan Albert <danalbert@google.com>2016-08-02 15:19:26 -0700
committerDan Albert <danalbert@google.com>2016-08-02 15:33:53 -0700
commitea701b37905c4e3c8eda9932224e013d97b4ccea (patch)
tree11ccdd180ba1a8159b5a880db422c48166984d4b /libc/tools/genversion-scripts.py
parent10085bfdc0b3b8ce4c30a0dcdeeb8f629a2506f7 (diff)
Only check arch tag if we have *any* arch tags.
With the introduction of new tags for ndk_library, we'll have a lot of tags that aren't architecture tags. If we have something tagged `introduced=21`, it should be in all architectures. Change-Id: Ib67f07db14625f6903919c181050316eb183bed5
Diffstat (limited to 'libc/tools/genversion-scripts.py')
-rwxr-xr-xlibc/tools/genversion-scripts.py11
1 files changed, 10 insertions, 1 deletions
diff --git a/libc/tools/genversion-scripts.py b/libc/tools/genversion-scripts.py
index e6c8053f5..53f4db4d5 100755
--- a/libc/tools/genversion-scripts.py
+++ b/libc/tools/genversion-scripts.py
@@ -33,6 +33,15 @@ bionic_libc_root = os.path.join(os.environ["ANDROID_BUILD_TOP"], "bionic/libc")
warning = "Generated by %s. Do not edit." % script_name
+def has_arch_tags(tags):
+ for arch in all_arches:
+ if arch in tags:
+ return True
+ if 'nobrillo' in tags:
+ return True
+ return False
+
+
class VersionScriptGenerator(object):
def run(self):
@@ -52,7 +61,7 @@ class VersionScriptGenerator(object):
index = line.find("#")
if index != -1:
tags = line[index+1:].split()
- if arch not in tags:
+ if arch not in tags and has_arch_tags(tags):
continue
if brillo and "nobrillo" in tags:
has_nobrillo = True