Fix libcxx.android.compiler for interface changes.
Test: ./run_tests.py Bug: http://b/34740564 Change-Id: I68846f5a5a951d5bd368907c662b2c980e1c89a9
This commit is contained in:
@@ -1,3 +1,4 @@
|
|||||||
|
import copy
|
||||||
import os
|
import os
|
||||||
import re
|
import re
|
||||||
import shlex
|
import shlex
|
||||||
@@ -13,6 +14,9 @@ class AndroidCXXCompiler(libcxx.compiler.CXXCompiler):
|
|||||||
self.link_template = link_template
|
self.link_template = link_template
|
||||||
self.build_top = os.getenv('ANDROID_BUILD_TOP')
|
self.build_top = os.getenv('ANDROID_BUILD_TOP')
|
||||||
|
|
||||||
|
def copy(self):
|
||||||
|
return copy.deepcopy(self)
|
||||||
|
|
||||||
def get_triple(self):
|
def get_triple(self):
|
||||||
if 'clang' in self.path:
|
if 'clang' in self.path:
|
||||||
return self.get_clang_triple()
|
return self.get_clang_triple()
|
||||||
@@ -38,15 +42,15 @@ class AndroidCXXCompiler(libcxx.compiler.CXXCompiler):
|
|||||||
return match.group(1)
|
return match.group(1)
|
||||||
return None
|
return None
|
||||||
|
|
||||||
def compile(self, source_files, out=None, flags=None, env=None, cwd=None):
|
def compile(self, source_files, out=None, flags=None, cwd=None):
|
||||||
flags = [] if flags is None else flags
|
flags = [] if flags is None else flags
|
||||||
return super(AndroidCXXCompiler, self).compile(source_files, out, flags,
|
return super(AndroidCXXCompiler, self).compile(source_files, out, flags,
|
||||||
env, self.build_top)
|
self.build_top)
|
||||||
|
|
||||||
def link(self, source_files, out=None, flags=None, env=None, cwd=None):
|
def link(self, source_files, out=None, flags=None, cwd=None):
|
||||||
flags = [] if flags is None else flags
|
flags = [] if flags is None else flags
|
||||||
return super(AndroidCXXCompiler, self).link(source_files, out, flags,
|
return super(AndroidCXXCompiler, self).link(source_files, out, flags,
|
||||||
env, self.build_top)
|
self.build_top)
|
||||||
|
|
||||||
def compileCmd(self, source_files, out=None, flags=None):
|
def compileCmd(self, source_files, out=None, flags=None):
|
||||||
if out is None:
|
if out is None:
|
||||||
|
|||||||
Reference in New Issue
Block a user