all repos — mgba @ 562a33d98b8faf2c19b8e3a22118e50604e9c385

mGBA Game Boy Advance Emulator

Inherit LD_LIBRARY_PATH in subprocess
Jeffrey Pfau jeffrey@endrift.com
Thu, 09 Oct 2014 01:36:08 -0700
commit

562a33d98b8faf2c19b8e3a22118e50604e9c385

parent

dbd939022cf461336879da1b479ca12623be1cd0

1 files changed, 5 insertions(+), 1 deletions(-)

jump to
M tools/perf.pytools/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()