]> git.lyx.org Git - lyx.git/blob - development/Win32/packaging/AltInstaller/InstallActions-complete-small.nsh
update installer: update also lyx.bat file (needed for new launcher)
[lyx.git] / development / Win32 / packaging / AltInstaller / InstallActions-complete-small.nsh
1 # this file contains the main installer section
2
3  # The '-' makes the section invisible.
4  Section "-Installation actions" SecInstallation
5
6   # dummy actions to avoid NSIS warnings
7   StrCpy $FileName ""
8   StrCpy $NewString ""
9   StrCpy $OldString ""
10   
11   # extract all files
12   SetOutPath "$INSTDIR"
13   File /r "${PRODUCT_SOURCEDIR}\bin"
14   File /r "${PRODUCT_SOURCEDIR}\etc"
15   File /r "${PRODUCT_SOURCEDIR}\Resources"
16   !if ${INSTALLER_VERSION} == "Complete"
17    File /r "${PRODUCT_SOURCEDIR}\external"
18   !endif
19
20   !if ${INSTALLER_VERSION} == "Complete"
21    # install MiKTeX if not already installed
22    Call InstallMiKTeX # function from LaTeX.nsh
23   !endif
24
25   # install Ghostscript if not already installed
26   Call Ghostscript # function from InstallThirdPartyProgs.nsh
27
28   # install ImageMagick if not already installed
29   Call ImageMagick # function from InstallThirdPartyProgs.nsh
30
31   # install Aspell if not already installed
32   Call InstallAspell # function from Aspell.nsh
33
34   # install Aiksaurus if not already installed
35   Call Aiksaurus # function from InstallThirdPartyProgs.nsh
36
37   !if ${INSTALLER_VERSION} == "Complete"
38    # install GSview if not already installed and the user selected it
39    Call PostScript # function from InstallThirdPartyProgs.nsh
40    
41    # install JabRef if not already installed and the user selected it
42    Call BibTeX # function from InstallThirdPartyProgs.nsh
43   !endif
44
45   # install the LaTeX class files that are delivered with LyX
46   # and enable MiKTeX's automatic package installation
47   Call ConfigureMiKTeX # Function from LaTeX.nsh
48
49   # refresh shell, update the environment variables otherwise the first
50   # configure run will fail when MiKTeX was just installed
51   System::Call 'shell32.dll::SHChangeNotify(i, i, i, i) (${SHCNE_ASSOCCHANGED}, ${SHCNF_IDLIST}, 0, 0)'
52
53   # install Aspell dictionaries
54   Call InstallAspellDictionary # function from Aspell.nsh
55
56   # configure LyX
57   Call ConfigureLyX # Function from ConfigLyX.nsh
58
59   # create Uninstaller
60   WriteUninstaller "${PRODUCT_UNINSTALL_EXE}"
61
62   # run LyX's configure script
63   MessageBox MB_OK|MB_ICONINFORMATION "$(LatexConfigInfo)"
64   ExecWait '"$INSTDIR\Resources\configLyX.bat"'
65   Delete "$INSTDIR\Resources\configLyX.bat"
66
67   # ask to update MiKTeX
68   Call UpdateMiKTeX # function from latex.nsh
69
70  SectionEnd
71