Inherit LD_LIBRARY_PATH in subprocess
Jeffrey Pfau jeffrey@endrift.com
Thu, 09 Oct 2014 01:36:08 -0700
1 files changed,
5 insertions(+),
1 deletions(-)
jump to
M
tools/perf.py
→
tools/perf.py
@@ -29,7 +29,11 @@ args.extend(self.get_args())
if self.renderer != 'software': args.append('-N') args.append(self.rom) - proc = subprocess.Popen(args, stdout=subprocess.PIPE, cwd=cwd, universal_newlines=True) + env = {} + if 'LD_LIBRARY_PATH' in os.environ: + env['LD_LIBRARY_PATH'] = os.environ['LD_LIBRARY_PATH'] + env['DYLD_LIBRARY_PATH'] = os.environ['LD_LIBRARY_PATH'] # Fake it on OS X + proc = subprocess.Popen(args, stdout=subprocess.PIPE, cwd=cwd, universal_newlines=True, env=env) try: self.wait(proc) proc.wait()