Restore process $PATH for SCons

This commit is contained in:
Ivan Kravets
2015-08-03 12:53:21 +03:00
parent 0f8b506c76
commit 0646ffc93f

View File

@ -123,10 +123,13 @@ for opt in ("LIB_IGNORE", "LIB_USE"):
continue continue
env[opt] = [l.strip() for l in env[opt].split(",") if l.strip()] env[opt] = [l.strip() for l in env[opt].split(",") if l.strip()]
env.PrependENVPath( # restore process $PATH
"PATH", env['ENV']['PATH'] = getenv("PATH")
env.subst(join("$PIOPACKAGES_DIR", "$PIOPACKAGE_TOOLCHAIN", "bin")) if env.subst("$PIOPACKAGE_TOOLCHAIN"):
) env.PrependENVPath(
"PATH",
env.subst(join("$PIOPACKAGES_DIR", "$PIOPACKAGE_TOOLCHAIN", "bin"))
)
SConscriptChdir(0) SConscriptChdir(0)
SConscript(env.subst("$BUILD_SCRIPT")) SConscript(env.subst("$BUILD_SCRIPT"))