Re: [PATCH v1] BaseTools: toolsetup.bat always execute PYTHON_HOME


Rebecca Cran
 

On 5/25/23 6:09 PM, gua.guo@... wrote:

-%PYTHON_COMMAND% %BASE_TOOLS_PATH%\Tests\PythonTest.py %PYTHON_VER_MAJOR% %PYTHON_VER_MINOR% >NUL 2>NUL
-if %ERRORLEVEL% EQU 1 (
- echo.
- echo !!! ERROR !!! Python %PYTHON_VER_MAJOR%.%PYTHON_VER_MINOR% or newer is required.
- echo.
- goto end
+ %PYTHON_COMMAND% %BASE_TOOLS_PATH%\Tests\PythonTest.py %PYTHON_VER_MAJOR% %PYTHON_VER_MINOR% >NUL 2>NUL
+ if %ERRORLEVEL% EQU 1 (
+ echo.
+ echo !!! ERROR !!! Python %PYTHON_VER_MAJOR%.%PYTHON_VER_MINOR% or newer is required.
+ echo.
+ goto end
+ )
)
If PYTHON_COMMAND is already defined we do still want to check it's a version we can use. So I don't think this part of the change is correct.


--

Rebecca Cran

Join {devel@edk2.groups.io to automatically receive all group messages.