summaryrefslogtreecommitdiff
path: root/Master/tlpkg/etc/nsis/texlive-installer.nsi
blob: d84d87dca30a6c5c72cece5f2d98e973e62aed2f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
!include "FileFunc.nsh"
!insertmacro GetParent

!define REV "rev10888"

Page directory
Page instfiles

Name "TeX Live Update ${REV}"
OutFile "update-texlive-${REV}.exe"
InstallDir "$PROGRAMFILES\texlive\2008"

DirText "Setup will update your TeX Live installation in the following folder. \
 To install in a different folder, click Browse and select another folder. \
 Click Install to start the update."

Function .onInit
  SearchPath $0 tlmgr.bat
  ${GetParent} $0 $1
  ${GetParent} $1 $0
  ${GetParent} $0 $1
  ;MessageBox MB_OK "tlmgr=$1"
  StrCpy $INSTDIR $1
  ;SetOutPath $1
FunctionEnd

Function .onVerifyInstDir
  IfFileExists $INSTDIR\tlpkg\texlive.tlpdb PathGood
    Abort
  PathGood:
FunctionEnd

Section "MainGroup"
  SetOutPath "$INSTDIR"
  File /r tlupdates\*.*
  ExecWait '"$INSTDIR\bin\win32\tlmgr.bat" _include_tlpobj "$INSTDIR\tlpkg\tlpobj\bin-texlive.tlpobj"'
  ExecWait '"$INSTDIR\bin\win32\tlmgr.bat" _include_tlpobj "$INSTDIR\tlpkg\tlpobj\texlive.infra.tlpobj"'
  ExecWait '"$INSTDIR\bin\win32\tlmgr.bat" _include_tlpobj "$INSTDIR\tlpkg\tlpobj\texlive.infra.doc.tlpobj"'
  ExecWait '"$INSTDIR\bin\win32\tlmgr.bat" _include_tlpobj "$INSTDIR\tlpkg\tlpobj\texlive.infra.win32.tlpobj"'
SectionEnd