]> granicus.if.org Git - python/commitdiff
Don't use `where`, it doesn't exist on XP (GH-3330)
authorZachary Ware <zachary.ware@gmail.com>
Tue, 5 Sep 2017 16:34:54 +0000 (09:34 -0700)
committerGitHub <noreply@github.com>
Tue, 5 Sep 2017 16:34:54 +0000 (09:34 -0700)
PCbuild/get_externals.bat

index e83e1d4c9ad4fa75021593e35a2fc3ab6085ea83..92fc9441727f80b9fa9d5a89a46e4c5702782674 100644 (file)
@@ -32,8 +32,11 @@ if "%DO_FETCH%"=="false" goto end
 if "%ORG%"=="" (set ORG=python)
 call "%PCBUILD%find_python.bat" "%PYTHON%"
 
-if "%PYTHON%"=="" (
-    where /Q git || echo Python 3.6 could not be found or installed, and git.exe is not on your PATH && exit /B 1
+git 2>&1 > nul
+if ERRORLEVEL 9009 (
+    if "%PYTHON%"=="" (
+        echo Python 3.6 could not be found or installed, and git.exe is not on your PATH && exit /B 1
+    )
 )
 
 echo.Fetching external libraries...