aboutsummaryrefslogtreecommitdiff
path: root/projects/checksrc.bat
diff options
context:
space:
mode:
authorJay Satiro <raysatiro@yahoo.com>2018-08-11 16:33:12 -0400
committerJay Satiro <raysatiro@yahoo.com>2018-08-11 16:33:12 -0400
commit220cd241cd8e64c5968df91c6f0a8083b49869ee (patch)
treee4bdc30b3aa9772c36d628e31e4ac3fccecbb62e /projects/checksrc.bat
parentb676b66f4ddc68a0e357fc4cf79b9adb981c8df5 (diff)
projects: Improve Windows perl detection in batch scripts
- Determine if perl is in the user's PATH by running perl.exe. Prior to this change detection was done by checking the PATH for perl/ but that did not work in all cases (eg git install includes perl but not in perl/ path). Bug: https://github.com/curl/curl/pull/2865 Reported-by: Daniel JeliƄski
Diffstat (limited to 'projects/checksrc.bat')
-rw-r--r--projects/checksrc.bat2
1 files changed, 1 insertions, 1 deletions
diff --git a/projects/checksrc.bat b/projects/checksrc.bat
index 3c38f50e6..5c8debf11 100644
--- a/projects/checksrc.bat
+++ b/projects/checksrc.bat
@@ -73,7 +73,7 @@ rem ***************************************************************************
:prerequisites
rem Check we have Perl in our path
- echo %PATH% | findstr /I /C:"\Perl" 1>nul
+ perl --version <NUL 1>NUL 2>&1
if errorlevel 1 (
rem It isn't so check we have it installed and set the path if it is
if exist "%SystemDrive%\Perl" (