aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--environment.py4
-rw-r--r--interpreter.py8
2 files changed, 6 insertions, 6 deletions
diff --git a/environment.py b/environment.py
index cb8913a..a29e9e4 100644
--- a/environment.py
+++ b/environment.py
@@ -847,9 +847,9 @@ class Environment():
path = os.path.split(__file__)[0]
return os.path.join(path, 'depfixer.py')
- def detect_cpp_compiler(self):
+ def detect_cpp_compiler(self, want_cross):
evar = 'CXX'
- if self.is_cross_build():
+ if self.is_cross_build() and want_cross:
compilers = [self.cross_info['cpp']]
ccache = []
is_cross = True
diff --git a/interpreter.py b/interpreter.py
index 13c035f..e0adca3 100644
--- a/interpreter.py
+++ b/interpreter.py
@@ -592,17 +592,17 @@ class Executable(BuildTarget):
self.filename = self.name
class StaticLibrary(BuildTarget):
- def __init__(self, name, subdir, sources, environment, kwargs):
- BuildTarget.__init__(self, name, subdir, sources, kwargs)
+ def __init__(self, name, subdir, is_cross, sources, environment, kwargs):
+ BuildTarget.__init__(self, name, subdir, is_cross, sources, kwargs)
prefix = environment.get_static_lib_prefix()
suffix = environment.get_static_lib_suffix()
self.filename = prefix + self.name + '.' + suffix
class SharedLibrary(BuildTarget):
- def __init__(self, name, subdir, sources, environment, kwargs):
+ def __init__(self, name, subdir, is_cross, sources, environment, kwargs):
self.version = None
self.soversion = None
- BuildTarget.__init__(self, name, subdir, sources, kwargs)
+ BuildTarget.__init__(self, name, subdir, is_cross, sources, kwargs)
self.prefix = environment.get_shared_lib_prefix()
self.suffix = environment.get_shared_lib_suffix()