summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
authorSiep Kroonenberg <siepo@cybercomm.nl>2018-03-12 20:40:42 +0000
committerSiep Kroonenberg <siepo@cybercomm.nl>2018-03-12 20:40:42 +0000
commit06a29c260a39508ef0fd55b0a6a42a6eddaaf912 (patch)
tree24e228f699c038349f2b579e0f6305c075a45b00 /Master
parent59b18d5b518dda81140a2d4ae6856723f3236a54 (diff)
Test for later Windows versions; no more need for UNC mappings
git-svn-id: svn://tug.org/texlive/trunk@46932 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rwxr-xr-xMaster/install-tl-windows.bat72
1 files changed, 36 insertions, 36 deletions
diff --git a/Master/install-tl-windows.bat b/Master/install-tl-windows.bat
index ac6ed7904fa..b326adbac31 100755
--- a/Master/install-tl-windows.bat
+++ b/Master/install-tl-windows.bat
@@ -1,16 +1,24 @@
@echo off
-rem $Id: install-tl.bat 30369 2013-05-10 13:01:27Z siepo $
+rem $Id: install-tl.bat 30369 2018-03-11 13:01:27Z siepo $
rem Wrapper script to set up environment for installer
rem
rem Public domain.
rem Originally written 2009 by Tomasz M. Trzeciak.
-rem First, check if this is DOS based system
-rem in DOS '^' is just a normal character
-if not ^x==x goto DOS
-
rem Localize environment changes
-setlocal enableextensions
+setlocal enableextensions enabledelayedexpansion
+
+rem check for version later than vista
+for /f "usebackq tokens=2 delims=[]" %%I in (`ver`) do set ver_str=%%I
+set ver_str=%ver_str:* =%
+rem windows 9x, 2000, xp, vista unsupported
+if %ver_str:~,2% == 4. goto tooold
+if %ver_str:~,2% == 5. goto tooold
+if %ver_str:~,3% == 6.0 (
+ echo WARNING: Windows 7 is the earliest supported version.
+ echo TeX Live 2018 has not been tested on Windows Vista.
+ pause
+)
rem version of external perl, if any
set extperl=0
@@ -18,20 +26,27 @@ for /f "usebackq tokens=2 delims='" %%a in (`perl -V:version 2^>NUL`) do (
set extperl=%%a
)
-rem Batch subroutines require a cd to the batchfile directory.
-rem For UNC paths, pushd will create a temporary mapping.
-pushd "%~dp0"
-
-rem Remove any double quotes from PATH (why we care for it at all???)
-set "path=%path:"=%"
-
-rem Break search path into dir list and rebuild w/o tex dirs
-call :rebuildpath ";" "%path:;=" "%"
-if "%path:~0,1%"==";" set "path=%path:~1%"
+rem Check for tex directories on path and remove them.
+rem Need to remove any double quotes from path
+set path=%path:"=%
+rem Break search path into dir list and rebuild w/o tex dirs.
+set path="%path:;=" "%"
+set newpath=
+for /d %%I in (%path%) do (
+ set ii=%%I
+ set ii=!ii:"=!
+ if not exist !ii!\pdftex.exe (
+ if not exist !ii!pdftex.exe (
+ set newpath=!newpath!;!ii!
+ )
+ )
+)
+path %newpath%
+if "%path:~,1%"==";" set "path=%path:~1%"
rem Use TL Perl
-set "path=%~dp0tlpkg\tlperl\bin;%path%"
-set "PERL5LIB=%~dp0tlpkg\tlperl\lib"
+path %~dp0tlpkg\tlperl\bin;%path%
+set PERL5LIB=%~dp0tlpkg\tlperl\lib
rem Clean environment from other Perl variables
set PERL5OPT=
@@ -63,24 +78,9 @@ if errorlevel 1 set errlev=1
pause
goto :eoff
-rem Subroutine to build search path without tex directories
-rem any dir containing pdftex.exe is considered a tex dir
-:rebuildpath ";" dir list ...
-shift
-rem The first argument (";") serves as a marker to reset the path
-if "%~0"==";" set path=
-rem Finish if no more arguments to process
-if [%1]==[] goto :eof
-rem Continue if tex dir
-if exist "%~1\pdftex.exe" goto :rebuildpath
-rem Add dir to path
-set "path=%path%;%~1"
-goto :rebuildpath
-
-:DOS
-echo DOS and Windows 9x systems are not supported. Sorry.
-echo Windows 2000 or newer is required.
+:tooold
+echo TeX Live does not run on this Windows version.
+echo TeX Live is supported on Windows 7 and later.
pause
:eoff
-if unc == 1 popd