summaryrefslogtreecommitdiff
path: root/BaseTools/BinWrappers
diff options
context:
space:
mode:
Diffstat (limited to 'BaseTools/BinWrappers')
-rwxr-xr-xBaseTools/BinWrappers/PosixLike/BPDG6
-rwxr-xr-xBaseTools/BinWrappers/PosixLike/Ecc6
-rwxr-xr-xBaseTools/BinWrappers/PosixLike/GenDepex6
-rwxr-xr-xBaseTools/BinWrappers/PosixLike/GenFds6
-rwxr-xr-xBaseTools/BinWrappers/PosixLike/GenPatchPcdTable6
-rwxr-xr-xBaseTools/BinWrappers/PosixLike/GenerateCapsule6
-rwxr-xr-xBaseTools/BinWrappers/PosixLike/PatchPcdValue6
-rwxr-xr-xBaseTools/BinWrappers/PosixLike/Pkcs7Sign6
-rwxr-xr-xBaseTools/BinWrappers/PosixLike/Rsa2048Sha256GenerateKeys6
-rwxr-xr-xBaseTools/BinWrappers/PosixLike/Rsa2048Sha256Sign6
-rwxr-xr-xBaseTools/BinWrappers/PosixLike/TargetTool6
-rwxr-xr-xBaseTools/BinWrappers/PosixLike/Trim6
-rwxr-xr-xBaseTools/BinWrappers/PosixLike/UPT6
-rwxr-xr-xBaseTools/BinWrappers/PosixLike/build6
-rw-r--r--BaseTools/BinWrappers/WindowsLike/BPDG.bat2
-rw-r--r--BaseTools/BinWrappers/WindowsLike/Ecc.bat2
-rw-r--r--BaseTools/BinWrappers/WindowsLike/GenDepex.bat2
-rw-r--r--BaseTools/BinWrappers/WindowsLike/GenFds.bat2
-rw-r--r--BaseTools/BinWrappers/WindowsLike/GenPatchPcdTable.bat2
-rw-r--r--BaseTools/BinWrappers/WindowsLike/GenerateCapsule.bat2
-rw-r--r--BaseTools/BinWrappers/WindowsLike/PatchPcdValue.bat2
-rw-r--r--BaseTools/BinWrappers/WindowsLike/Pkcs7Sign.bat2
-rw-r--r--BaseTools/BinWrappers/WindowsLike/Rsa2048Sha256GenerateKeys.bat2
-rw-r--r--BaseTools/BinWrappers/WindowsLike/Rsa2048Sha256Sign.bat2
-rw-r--r--BaseTools/BinWrappers/WindowsLike/TargetTool.bat2
-rw-r--r--BaseTools/BinWrappers/WindowsLike/Trim.bat2
-rw-r--r--BaseTools/BinWrappers/WindowsLike/UPT.bat2
-rw-r--r--BaseTools/BinWrappers/WindowsLike/build.bat2
28 files changed, 56 insertions, 56 deletions
diff --git a/BaseTools/BinWrappers/PosixLike/BPDG b/BaseTools/BinWrappers/PosixLike/BPDG
index 99dcf99657..276c7ea207 100755
--- a/BaseTools/BinWrappers/PosixLike/BPDG
+++ b/BaseTools/BinWrappers/PosixLike/BPDG
@@ -1,9 +1,9 @@
#!/usr/bin/env bash
#python `dirname $0`/RunToolFromSource.py `basename $0` $*
-# If a PYTHON3 command is available, use it in preference to python
-if command -v $PYTHON3 >/dev/null 2>&1; then
- python_exe=$PYTHON3
+# If a python2 command is available, use it in preference to python
+if command -v python2 >/dev/null 2>&1; then
+ python_exe=python2
fi
full_cmd=${BASH_SOURCE:-$0} # see http://mywiki.wooledge.org/BashFAQ/028 for a discussion of why $0 is not a good choice here
diff --git a/BaseTools/BinWrappers/PosixLike/Ecc b/BaseTools/BinWrappers/PosixLike/Ecc
index 0032408fa1..1142964028 100755
--- a/BaseTools/BinWrappers/PosixLike/Ecc
+++ b/BaseTools/BinWrappers/PosixLike/Ecc
@@ -1,9 +1,9 @@
#!/usr/bin/env bash
#python `dirname $0`/RunToolFromSource.py `basename $0` $*
-# If a PYTHON3 command is available, use it in preference to python
-if command -v $PYTHON3 >/dev/null 2>&1; then
- python_exe=$PYTHON3
+# If a python2 command is available, use it in preference to python
+if command -v python2 >/dev/null 2>&1; then
+ python_exe=python2
fi
full_cmd=${BASH_SOURCE:-$0} # see http://mywiki.wooledge.org/BashFAQ/028 for a discussion of why $0 is not a good choice here
diff --git a/BaseTools/BinWrappers/PosixLike/GenDepex b/BaseTools/BinWrappers/PosixLike/GenDepex
index f1bd62d7bd..dad174788b 100755
--- a/BaseTools/BinWrappers/PosixLike/GenDepex
+++ b/BaseTools/BinWrappers/PosixLike/GenDepex
@@ -1,9 +1,9 @@
#!/usr/bin/env bash
#python `dirname $0`/RunToolFromSource.py `basename $0` $*
-# If a PYTHON3 command is available, use it in preference to python
-if command -v $PYTHON3 >/dev/null 2>&1; then
- python_exe=$PYTHON3
+# If a python2 command is available, use it in preference to python
+if command -v python2 >/dev/null 2>&1; then
+ python_exe=python2
fi
full_cmd=${BASH_SOURCE:-$0} # see http://mywiki.wooledge.org/BashFAQ/028 for a discussion of why $0 is not a good choice here
diff --git a/BaseTools/BinWrappers/PosixLike/GenFds b/BaseTools/BinWrappers/PosixLike/GenFds
index 99dcf99657..276c7ea207 100755
--- a/BaseTools/BinWrappers/PosixLike/GenFds
+++ b/BaseTools/BinWrappers/PosixLike/GenFds
@@ -1,9 +1,9 @@
#!/usr/bin/env bash
#python `dirname $0`/RunToolFromSource.py `basename $0` $*
-# If a PYTHON3 command is available, use it in preference to python
-if command -v $PYTHON3 >/dev/null 2>&1; then
- python_exe=$PYTHON3
+# If a python2 command is available, use it in preference to python
+if command -v python2 >/dev/null 2>&1; then
+ python_exe=python2
fi
full_cmd=${BASH_SOURCE:-$0} # see http://mywiki.wooledge.org/BashFAQ/028 for a discussion of why $0 is not a good choice here
diff --git a/BaseTools/BinWrappers/PosixLike/GenPatchPcdTable b/BaseTools/BinWrappers/PosixLike/GenPatchPcdTable
index 76effb6da0..01ae23ddeb 100755
--- a/BaseTools/BinWrappers/PosixLike/GenPatchPcdTable
+++ b/BaseTools/BinWrappers/PosixLike/GenPatchPcdTable
@@ -1,9 +1,9 @@
#!/usr/bin/env bash
#python `dirname $0`/RunToolFromSource.py `basename $0` $*
-# If a PYTHON3 command is available, use it in preference to python
-if command -v $PYTHON3 >/dev/null 2>&1; then
- python_exe=$PYTHON3
+# If a python2 command is available, use it in preference to python
+if command -v python2 >/dev/null 2>&1; then
+ python_exe=python2
fi
full_cmd=${BASH_SOURCE:-$0} # see http://mywiki.wooledge.org/BashFAQ/028 for a discussion of why $0 is not a good choice here
diff --git a/BaseTools/BinWrappers/PosixLike/GenerateCapsule b/BaseTools/BinWrappers/PosixLike/GenerateCapsule
index 3a1bd4d4e9..59a6c8ba43 100755
--- a/BaseTools/BinWrappers/PosixLike/GenerateCapsule
+++ b/BaseTools/BinWrappers/PosixLike/GenerateCapsule
@@ -1,9 +1,9 @@
#!/usr/bin/env bash
#python `dirname $0`/RunToolFromSource.py `basename $0` $*
-# If a PYTHON3 command is available, use it in preference to python
-if command -v $PYTHON3 >/dev/null 2>&1; then
- python_exe=$PYTHON3
+# If a python2 command is available, use it in preference to python
+if command -v python2 >/dev/null 2>&1; then
+ python_exe=python2
fi
full_cmd=${BASH_SOURCE:-$0} # see http://mywiki.wooledge.org/BashFAQ/028 for a discussion of why $0 is not a good choice here
diff --git a/BaseTools/BinWrappers/PosixLike/PatchPcdValue b/BaseTools/BinWrappers/PosixLike/PatchPcdValue
index 76effb6da0..01ae23ddeb 100755
--- a/BaseTools/BinWrappers/PosixLike/PatchPcdValue
+++ b/BaseTools/BinWrappers/PosixLike/PatchPcdValue
@@ -1,9 +1,9 @@
#!/usr/bin/env bash
#python `dirname $0`/RunToolFromSource.py `basename $0` $*
-# If a PYTHON3 command is available, use it in preference to python
-if command -v $PYTHON3 >/dev/null 2>&1; then
- python_exe=$PYTHON3
+# If a python2 command is available, use it in preference to python
+if command -v python2 >/dev/null 2>&1; then
+ python_exe=python2
fi
full_cmd=${BASH_SOURCE:-$0} # see http://mywiki.wooledge.org/BashFAQ/028 for a discussion of why $0 is not a good choice here
diff --git a/BaseTools/BinWrappers/PosixLike/Pkcs7Sign b/BaseTools/BinWrappers/PosixLike/Pkcs7Sign
index 76effb6da0..01ae23ddeb 100755
--- a/BaseTools/BinWrappers/PosixLike/Pkcs7Sign
+++ b/BaseTools/BinWrappers/PosixLike/Pkcs7Sign
@@ -1,9 +1,9 @@
#!/usr/bin/env bash
#python `dirname $0`/RunToolFromSource.py `basename $0` $*
-# If a PYTHON3 command is available, use it in preference to python
-if command -v $PYTHON3 >/dev/null 2>&1; then
- python_exe=$PYTHON3
+# If a python2 command is available, use it in preference to python
+if command -v python2 >/dev/null 2>&1; then
+ python_exe=python2
fi
full_cmd=${BASH_SOURCE:-$0} # see http://mywiki.wooledge.org/BashFAQ/028 for a discussion of why $0 is not a good choice here
diff --git a/BaseTools/BinWrappers/PosixLike/Rsa2048Sha256GenerateKeys b/BaseTools/BinWrappers/PosixLike/Rsa2048Sha256GenerateKeys
index 0d7872d24d..1bc1054a34 100755
--- a/BaseTools/BinWrappers/PosixLike/Rsa2048Sha256GenerateKeys
+++ b/BaseTools/BinWrappers/PosixLike/Rsa2048Sha256GenerateKeys
@@ -1,9 +1,9 @@
#!/usr/bin/env bash
#python `dirname $0`/RunToolFromSource.py `basename $0` $*
-# If a PYTHON3 command is available, use it in preference to python
-if command -v $PYTHON3 >/dev/null 2>&1; then
- python_exe=$PYTHON3
+# If a python2 command is available, use it in preference to python
+if command -v python2 >/dev/null 2>&1; then
+ python_exe=python2
fi
full_cmd=${BASH_SOURCE:-$0} # see http://mywiki.wooledge.org/BashFAQ/028 for a discussion of why $0 is not a good choice here
diff --git a/BaseTools/BinWrappers/PosixLike/Rsa2048Sha256Sign b/BaseTools/BinWrappers/PosixLike/Rsa2048Sha256Sign
index 76effb6da0..01ae23ddeb 100755
--- a/BaseTools/BinWrappers/PosixLike/Rsa2048Sha256Sign
+++ b/BaseTools/BinWrappers/PosixLike/Rsa2048Sha256Sign
@@ -1,9 +1,9 @@
#!/usr/bin/env bash
#python `dirname $0`/RunToolFromSource.py `basename $0` $*
-# If a PYTHON3 command is available, use it in preference to python
-if command -v $PYTHON3 >/dev/null 2>&1; then
- python_exe=$PYTHON3
+# If a python2 command is available, use it in preference to python
+if command -v python2 >/dev/null 2>&1; then
+ python_exe=python2
fi
full_cmd=${BASH_SOURCE:-$0} # see http://mywiki.wooledge.org/BashFAQ/028 for a discussion of why $0 is not a good choice here
diff --git a/BaseTools/BinWrappers/PosixLike/TargetTool b/BaseTools/BinWrappers/PosixLike/TargetTool
index 76effb6da0..01ae23ddeb 100755
--- a/BaseTools/BinWrappers/PosixLike/TargetTool
+++ b/BaseTools/BinWrappers/PosixLike/TargetTool
@@ -1,9 +1,9 @@
#!/usr/bin/env bash
#python `dirname $0`/RunToolFromSource.py `basename $0` $*
-# If a PYTHON3 command is available, use it in preference to python
-if command -v $PYTHON3 >/dev/null 2>&1; then
- python_exe=$PYTHON3
+# If a python2 command is available, use it in preference to python
+if command -v python2 >/dev/null 2>&1; then
+ python_exe=python2
fi
full_cmd=${BASH_SOURCE:-$0} # see http://mywiki.wooledge.org/BashFAQ/028 for a discussion of why $0 is not a good choice here
diff --git a/BaseTools/BinWrappers/PosixLike/Trim b/BaseTools/BinWrappers/PosixLike/Trim
index f36bd69d26..6c8dde5bec 100755
--- a/BaseTools/BinWrappers/PosixLike/Trim
+++ b/BaseTools/BinWrappers/PosixLike/Trim
@@ -1,9 +1,9 @@
#!/usr/bin/env bash
#python `dirname $0`/RunToolFromSource.py `basename $0` $*
-# If a PYTHON3 command is available, use it in preference to python
-if command -v $PYTHON3 >/dev/null 2>&1; then
- python_exe=$PYTHON3
+# If a python2 command is available, use it in preference to python
+if command -v python2 >/dev/null 2>&1; then
+ python_exe=python2
fi
full_cmd=${BASH_SOURCE:-$0} # see http://mywiki.wooledge.org/BashFAQ/028 for a discussion of why $0 is not a good choice here
diff --git a/BaseTools/BinWrappers/PosixLike/UPT b/BaseTools/BinWrappers/PosixLike/UPT
index 76effb6da0..01ae23ddeb 100755
--- a/BaseTools/BinWrappers/PosixLike/UPT
+++ b/BaseTools/BinWrappers/PosixLike/UPT
@@ -1,9 +1,9 @@
#!/usr/bin/env bash
#python `dirname $0`/RunToolFromSource.py `basename $0` $*
-# If a PYTHON3 command is available, use it in preference to python
-if command -v $PYTHON3 >/dev/null 2>&1; then
- python_exe=$PYTHON3
+# If a python2 command is available, use it in preference to python
+if command -v python2 >/dev/null 2>&1; then
+ python_exe=python2
fi
full_cmd=${BASH_SOURCE:-$0} # see http://mywiki.wooledge.org/BashFAQ/028 for a discussion of why $0 is not a good choice here
diff --git a/BaseTools/BinWrappers/PosixLike/build b/BaseTools/BinWrappers/PosixLike/build
index 76effb6da0..01ae23ddeb 100755
--- a/BaseTools/BinWrappers/PosixLike/build
+++ b/BaseTools/BinWrappers/PosixLike/build
@@ -1,9 +1,9 @@
#!/usr/bin/env bash
#python `dirname $0`/RunToolFromSource.py `basename $0` $*
-# If a PYTHON3 command is available, use it in preference to python
-if command -v $PYTHON3 >/dev/null 2>&1; then
- python_exe=$PYTHON3
+# If a python2 command is available, use it in preference to python
+if command -v python2 >/dev/null 2>&1; then
+ python_exe=python2
fi
full_cmd=${BASH_SOURCE:-$0} # see http://mywiki.wooledge.org/BashFAQ/028 for a discussion of why $0 is not a good choice here
diff --git a/BaseTools/BinWrappers/WindowsLike/BPDG.bat b/BaseTools/BinWrappers/WindowsLike/BPDG.bat
index 8e2211e3c1..98095cfbd4 100644
--- a/BaseTools/BinWrappers/WindowsLike/BPDG.bat
+++ b/BaseTools/BinWrappers/WindowsLike/BPDG.bat
@@ -1,4 +1,4 @@
@setlocal
@set ToolName=%~n0%
@set PYTHONPATH=%PYTHONPATH%;%BASE_TOOLS_PATH%\Source\Python
-@%PYTHON3% -m %ToolName%.%ToolName% %*
+@%PYTHON_HOME%\python.exe -m %ToolName%.%ToolName% %*
diff --git a/BaseTools/BinWrappers/WindowsLike/Ecc.bat b/BaseTools/BinWrappers/WindowsLike/Ecc.bat
index 151d9e730d..8705e7541e 100644
--- a/BaseTools/BinWrappers/WindowsLike/Ecc.bat
+++ b/BaseTools/BinWrappers/WindowsLike/Ecc.bat
@@ -1,4 +1,4 @@
@setlocal
@set ToolName=%~n0%
@set PYTHONPATH=%PYTHONPATH%;%BASE_TOOLS_PATH%\Source\Python
-@%PYTHON3% -m %ToolName%.EccMain %*
+@%PYTHON_HOME%\python.exe -m %ToolName%.EccMain %*
diff --git a/BaseTools/BinWrappers/WindowsLike/GenDepex.bat b/BaseTools/BinWrappers/WindowsLike/GenDepex.bat
index e8e5753ce3..ffc783d2be 100644
--- a/BaseTools/BinWrappers/WindowsLike/GenDepex.bat
+++ b/BaseTools/BinWrappers/WindowsLike/GenDepex.bat
@@ -1,3 +1,3 @@
@setlocal
@set ToolName=%~n0%
-@%PYTHON3% %BASE_TOOLS_PATH%\Source\Python\AutoGen\%ToolName%.py %*
+@%PYTHON_HOME%\python.exe %BASE_TOOLS_PATH%\Source\Python\AutoGen\%ToolName%.py %*
diff --git a/BaseTools/BinWrappers/WindowsLike/GenFds.bat b/BaseTools/BinWrappers/WindowsLike/GenFds.bat
index 8e2211e3c1..98095cfbd4 100644
--- a/BaseTools/BinWrappers/WindowsLike/GenFds.bat
+++ b/BaseTools/BinWrappers/WindowsLike/GenFds.bat
@@ -1,4 +1,4 @@
@setlocal
@set ToolName=%~n0%
@set PYTHONPATH=%PYTHONPATH%;%BASE_TOOLS_PATH%\Source\Python
-@%PYTHON3% -m %ToolName%.%ToolName% %*
+@%PYTHON_HOME%\python.exe -m %ToolName%.%ToolName% %*
diff --git a/BaseTools/BinWrappers/WindowsLike/GenPatchPcdTable.bat b/BaseTools/BinWrappers/WindowsLike/GenPatchPcdTable.bat
index 160347c700..9fbb704a6e 100644
--- a/BaseTools/BinWrappers/WindowsLike/GenPatchPcdTable.bat
+++ b/BaseTools/BinWrappers/WindowsLike/GenPatchPcdTable.bat
@@ -1,3 +1,3 @@
@setlocal
@set ToolName=%~n0%
-@%PYTHON3% %BASE_TOOLS_PATH%\Source\Python\%ToolName%\%ToolName%.py %*
+@%PYTHON_HOME%\python.exe %BASE_TOOLS_PATH%\Source\Python\%ToolName%\%ToolName%.py %*
diff --git a/BaseTools/BinWrappers/WindowsLike/GenerateCapsule.bat b/BaseTools/BinWrappers/WindowsLike/GenerateCapsule.bat
index a498b1efc5..ca442d181b 100644
--- a/BaseTools/BinWrappers/WindowsLike/GenerateCapsule.bat
+++ b/BaseTools/BinWrappers/WindowsLike/GenerateCapsule.bat
@@ -1 +1 @@
-@%PYTHON3% %BASE_TOOLS_PATH%\Source\Python\Capsule\GenerateCapsule.py %*
+@%PYTHON_HOME%\python.exe %BASE_TOOLS_PATH%\Source\Python\Capsule\GenerateCapsule.py %*
diff --git a/BaseTools/BinWrappers/WindowsLike/PatchPcdValue.bat b/BaseTools/BinWrappers/WindowsLike/PatchPcdValue.bat
index 160347c700..9fbb704a6e 100644
--- a/BaseTools/BinWrappers/WindowsLike/PatchPcdValue.bat
+++ b/BaseTools/BinWrappers/WindowsLike/PatchPcdValue.bat
@@ -1,3 +1,3 @@
@setlocal
@set ToolName=%~n0%
-@%PYTHON3% %BASE_TOOLS_PATH%\Source\Python\%ToolName%\%ToolName%.py %*
+@%PYTHON_HOME%\python.exe %BASE_TOOLS_PATH%\Source\Python\%ToolName%\%ToolName%.py %*
diff --git a/BaseTools/BinWrappers/WindowsLike/Pkcs7Sign.bat b/BaseTools/BinWrappers/WindowsLike/Pkcs7Sign.bat
index 160347c700..9fbb704a6e 100644
--- a/BaseTools/BinWrappers/WindowsLike/Pkcs7Sign.bat
+++ b/BaseTools/BinWrappers/WindowsLike/Pkcs7Sign.bat
@@ -1,3 +1,3 @@
@setlocal
@set ToolName=%~n0%
-@%PYTHON3% %BASE_TOOLS_PATH%\Source\Python\%ToolName%\%ToolName%.py %*
+@%PYTHON_HOME%\python.exe %BASE_TOOLS_PATH%\Source\Python\%ToolName%\%ToolName%.py %*
diff --git a/BaseTools/BinWrappers/WindowsLike/Rsa2048Sha256GenerateKeys.bat b/BaseTools/BinWrappers/WindowsLike/Rsa2048Sha256GenerateKeys.bat
index c3323a742d..df9336567c 100644
--- a/BaseTools/BinWrappers/WindowsLike/Rsa2048Sha256GenerateKeys.bat
+++ b/BaseTools/BinWrappers/WindowsLike/Rsa2048Sha256GenerateKeys.bat
@@ -1 +1 @@
-@%PYTHON3% %BASE_TOOLS_PATH%\Source\Python\Rsa2048Sha256Sign\Rsa2048Sha256GenerateKeys.py %*
+@%PYTHON_HOME%\python.exe %BASE_TOOLS_PATH%\Source\Python\Rsa2048Sha256Sign\Rsa2048Sha256GenerateKeys.py %*
diff --git a/BaseTools/BinWrappers/WindowsLike/Rsa2048Sha256Sign.bat b/BaseTools/BinWrappers/WindowsLike/Rsa2048Sha256Sign.bat
index 160347c700..9fbb704a6e 100644
--- a/BaseTools/BinWrappers/WindowsLike/Rsa2048Sha256Sign.bat
+++ b/BaseTools/BinWrappers/WindowsLike/Rsa2048Sha256Sign.bat
@@ -1,3 +1,3 @@
@setlocal
@set ToolName=%~n0%
-@%PYTHON3% %BASE_TOOLS_PATH%\Source\Python\%ToolName%\%ToolName%.py %*
+@%PYTHON_HOME%\python.exe %BASE_TOOLS_PATH%\Source\Python\%ToolName%\%ToolName%.py %*
diff --git a/BaseTools/BinWrappers/WindowsLike/TargetTool.bat b/BaseTools/BinWrappers/WindowsLike/TargetTool.bat
index 160347c700..9fbb704a6e 100644
--- a/BaseTools/BinWrappers/WindowsLike/TargetTool.bat
+++ b/BaseTools/BinWrappers/WindowsLike/TargetTool.bat
@@ -1,3 +1,3 @@
@setlocal
@set ToolName=%~n0%
-@%PYTHON3% %BASE_TOOLS_PATH%\Source\Python\%ToolName%\%ToolName%.py %*
+@%PYTHON_HOME%\python.exe %BASE_TOOLS_PATH%\Source\Python\%ToolName%\%ToolName%.py %*
diff --git a/BaseTools/BinWrappers/WindowsLike/Trim.bat b/BaseTools/BinWrappers/WindowsLike/Trim.bat
index 160347c700..9fbb704a6e 100644
--- a/BaseTools/BinWrappers/WindowsLike/Trim.bat
+++ b/BaseTools/BinWrappers/WindowsLike/Trim.bat
@@ -1,3 +1,3 @@
@setlocal
@set ToolName=%~n0%
-@%PYTHON3% %BASE_TOOLS_PATH%\Source\Python\%ToolName%\%ToolName%.py %*
+@%PYTHON_HOME%\python.exe %BASE_TOOLS_PATH%\Source\Python\%ToolName%\%ToolName%.py %*
diff --git a/BaseTools/BinWrappers/WindowsLike/UPT.bat b/BaseTools/BinWrappers/WindowsLike/UPT.bat
index 160347c700..9fbb704a6e 100644
--- a/BaseTools/BinWrappers/WindowsLike/UPT.bat
+++ b/BaseTools/BinWrappers/WindowsLike/UPT.bat
@@ -1,3 +1,3 @@
@setlocal
@set ToolName=%~n0%
-@%PYTHON3% %BASE_TOOLS_PATH%\Source\Python\%ToolName%\%ToolName%.py %*
+@%PYTHON_HOME%\python.exe %BASE_TOOLS_PATH%\Source\Python\%ToolName%\%ToolName%.py %*
diff --git a/BaseTools/BinWrappers/WindowsLike/build.bat b/BaseTools/BinWrappers/WindowsLike/build.bat
index 160347c700..9fbb704a6e 100644
--- a/BaseTools/BinWrappers/WindowsLike/build.bat
+++ b/BaseTools/BinWrappers/WindowsLike/build.bat
@@ -1,3 +1,3 @@
@setlocal
@set ToolName=%~n0%
-@%PYTHON3% %BASE_TOOLS_PATH%\Source\Python\%ToolName%\%ToolName%.py %*
+@%PYTHON_HOME%\python.exe %BASE_TOOLS_PATH%\Source\Python\%ToolName%\%ToolName%.py %*