installer: sync with branch
[lyx.git] / development / Win32 / packaging / AltInstaller / InstallActions-complete-small.nsh
blob71fd485e471fbdf823d035a3b7ff24312433a957
1 # this file contains the main installer section
3  # The '-' makes the section invisible.
4  Section "-Installation actions" SecInstallation
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
20   !if ${INSTALLER_VERSION} == "Complete"
21    # install MiKTeX if not already installed
22    Call InstallMiKTeX # function from LaTeX.nsh
23   !endif
25   # install Ghostscript if not already installed
26   Call Ghostscript # function from InstallThirdPartyProgs.nsh
28   # install ImageMagick if not already installed
29   Call ImageMagick # function from InstallThirdPartyProgs.nsh
31   # install Aspell if not already installed
32   Call InstallAspell # function from Aspell.nsh
34   # install eLyXer as Python module
35   Call eLyXer # function from InstallThirdPartyProgs.nsh
36   
37   # install Aiksaurus if not already installed
38   Call Aiksaurus # function from InstallThirdPartyProgs.nsh
39   
40   # install Metafile2eps if not already installed
41   Call Metafile2eps # function from InstallThirdPartyProgs.nsh
43   !if ${INSTALLER_VERSION} == "Complete"
44    # install GSview if not already installed and the user selected it
45    Call PostScript # function from InstallThirdPartyProgs.nsh
46    
47    # install JabRef if not already installed and the user selected it
48    Call BibTeX # function from InstallThirdPartyProgs.nsh
49   !endif
51   # install the LaTeX class files that are delivered with LyX
52   # and enable MiKTeX's automatic package installation
53   Call ConfigureMiKTeX # Function from LaTeX.nsh
55   # refresh shell, update the environment variables otherwise the first
56   # configure run will fail when MiKTeX was just installed
57   System::Call 'shell32.dll::SHChangeNotify(i, i, i, i) (${SHCNE_ASSOCCHANGED}, ${SHCNF_IDLIST}, 0, 0)'
59   # install Aspell dictionaries
60   Call InstallAspellDictionary # function from Aspell.nsh
62   # configure LyX
63   Call ConfigureLyX # Function from ConfigLyX.nsh
65   # create Uninstaller
66   WriteUninstaller "${PRODUCT_UNINSTALL_EXE}"
68   # run LyX's configure script
69   MessageBox MB_OK|MB_ICONINFORMATION "$(LatexConfigInfo)"
70   ExecWait '"$INSTDIR\Resources\configLyX.bat"'
71   Delete "$INSTDIR\Resources\configLyX.bat"
73   # ask to update MiKTeX
74   Call UpdateMiKTeX # function from latex.nsh
76  SectionEnd