-if exist %WORKSPACE%\BaseTools (\r
- set EDK_TOOLS_PATH=%WORKSPACE%\BaseTools\r
-) else (\r
- if defined PACKAGES_PATH (\r
- for %%i IN (%PACKAGES_PATH%) DO (\r
- if exist %%~fi\BaseTools (\r
- set EDK_TOOLS_PATH=%%~fi\BaseTools\r
- goto checkBaseTools\r
+if not defined EDK_TOOLS_PATH (\r
+ if exist %WORKSPACE%\BaseTools (\r
+ set EDK_TOOLS_PATH=%WORKSPACE%\BaseTools\r
+ ) else (\r
+ if defined PACKAGES_PATH (\r
+ for %%i IN (%PACKAGES_PATH%) DO (\r
+ if exist %%~fi\BaseTools (\r
+ set EDK_TOOLS_PATH=%%~fi\BaseTools\r
+ goto checkBaseTools\r
+ )\r