[Lldb-commits] [lldb] r349461 - build.py: inherit environment in the gcc builder

Pavel Labath via lldb-commits lldb-commits at lists.llvm.org
Tue Dec 18 01:07:22 PST 2018


Author: labath
Date: Tue Dec 18 01:07:21 2018
New Revision: 349461

URL: http://llvm.org/viewvc/llvm-project?rev=349461&view=rev
Log:
build.py: inherit environment in the gcc builder

Summary:
This should enable the compiler to find the system linker for the link
step.

Reviewers: stella.stamenova, zturner

Subscribers: lldb-commits

Differential Revision: https://reviews.llvm.org/D55736

Modified:
    lldb/trunk/lit/helper/build.py

Modified: lldb/trunk/lit/helper/build.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/lit/helper/build.py?rev=349461&r1=349460&r2=349461&view=diff
==============================================================================
--- lldb/trunk/lit/helper/build.py (original)
+++ lldb/trunk/lit/helper/build.py Tue Dec 18 01:07:21 2018
@@ -153,6 +153,9 @@ def format_text(lines, indent_0, indent_
     return result
 
 def print_environment(env):
+    if env is None:
+        print('    Inherited')
+        return
     for e in env:
         value = env[e]
         lines = value.split(os.pathsep)
@@ -633,7 +636,7 @@ class GccBuilder(Builder):
         args.extend(['-o', obj])
         args.append(source)
 
-        return ('compiling', [source], obj, {}, args)
+        return ('compiling', [source], obj, None, args)
 
     def _get_link_command(self):
         args = []
@@ -649,7 +652,7 @@ class GccBuilder(Builder):
         args.extend(['-o', self._exe_file_name()])
         args.extend(self._obj_file_names())
 
-        return ('linking', self._obj_file_names(), self._exe_file_name(), {}, args)
+        return ('linking', self._obj_file_names(), self._exe_file_name(), None, args)
 
 
     def output_files(self):




More information about the lldb-commits mailing list