mirror of
https://github.com/acidanthera/audk.git
synced 2025-07-29 08:34:07 +02:00
BaseTools/Build: Support python scripts in PREBUILD/POSTBUILD
https://bugzilla.tianocore.org/show_bug.cgi?id=627 Add shell=True in Popen() calls to support direct execution of python scripts Cc: Liming Gao <liming.gao@intel.com> Cc: Yonghong Zhu <yonghong.zhu@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Michael Kinney <michael.d.kinney@intel.com> Reviewed-by: Yonghong Zhu <yonghong.zhu@intel.com>
This commit is contained in:
parent
b1fe2029fa
commit
b926f2f2a4
@ -1036,7 +1036,7 @@ class Build():
|
|||||||
os.remove(self.PlatformBuildPath)
|
os.remove(self.PlatformBuildPath)
|
||||||
if sys.platform == "win32":
|
if sys.platform == "win32":
|
||||||
args = ' && '.join((self.Prebuild, 'set > ' + PrebuildEnvFile))
|
args = ' && '.join((self.Prebuild, 'set > ' + PrebuildEnvFile))
|
||||||
Process = Popen(args, stdout=PIPE, stderr=PIPE)
|
Process = Popen(args, stdout=PIPE, stderr=PIPE, shell=True)
|
||||||
else:
|
else:
|
||||||
args = ' && '.join((self.Prebuild, 'env > ' + PrebuildEnvFile))
|
args = ' && '.join((self.Prebuild, 'env > ' + PrebuildEnvFile))
|
||||||
Process = Popen(args, stdout=PIPE, stderr=PIPE, shell=True)
|
Process = Popen(args, stdout=PIPE, stderr=PIPE, shell=True)
|
||||||
@ -1079,7 +1079,7 @@ class Build():
|
|||||||
if self.Postbuild:
|
if self.Postbuild:
|
||||||
EdkLogger.info("\n- Postbuild Start -\n")
|
EdkLogger.info("\n- Postbuild Start -\n")
|
||||||
if sys.platform == "win32":
|
if sys.platform == "win32":
|
||||||
Process = Popen(self.Postbuild, stdout=PIPE, stderr=PIPE)
|
Process = Popen(self.Postbuild, stdout=PIPE, stderr=PIPE, shell=True)
|
||||||
else:
|
else:
|
||||||
Process = Popen(self.Postbuild, stdout=PIPE, stderr=PIPE, shell=True)
|
Process = Popen(self.Postbuild, stdout=PIPE, stderr=PIPE, shell=True)
|
||||||
# launch two threads to read the STDOUT and STDERR
|
# launch two threads to read the STDOUT and STDERR
|
||||||
|
Loading…
x
Reference in New Issue
Block a user