]> git.lyx.org Git - features.git/blob - development/Win32/packaging/installer/LyXWinInstaller/InstallActions-complete-small.nsh
f60d744c60f4d467623576d04c9bc4908a0ad190
[features.git] / development / Win32 / packaging / installer / LyXWinInstaller / InstallActions-complete-small.nsh
1 # this file contains the main installer sections
2
3 !if ${INSTALLER_VERSION} == "Complete"
4
5  # The '-' makes the section invisible.
6  Section "-Installation actions" SecInstallation
7
8   # dummy actions to avoid NSIS warnings
9   StrCpy $FileName ""
10   StrCpy $NewString ""
11   StrCpy $OldString ""
12   
13   # extract all files
14   SetOutPath "$INSTDIR"
15   File /r "${PRODUCT_SOURCEDIR}\bin"
16   File /r "${PRODUCT_SOURCEDIR}\etc"
17   File /r "${PRODUCT_SOURCEDIR}\Resources"
18   File /r "${PRODUCT_SOURCEDIR}\external"
19
20   # install MiKTeX if not already installed
21   Call InstallMiKTeX # function from LaTeX.nsh
22
23   # install Ghostscript if not already installed
24   Call Ghostscript # function from InstallThirdPartyProgs.nsh
25
26   # install ImageMagick if not already installed
27   Call ImageMagick # function from InstallThirdPartyProgs.nsh
28
29   # install Aspell if not already installed
30   Call InstallAspell # function from Aspell.nsh
31
32   # install Aiksaurus if not already installed
33   Call Aiksaurus # function from InstallThirdPartyProgs.nsh
34
35   # install GSview if not already installed and the user selected it
36   Call PostScript # function from InstallThirdPartyProgs.nsh
37
38   # install JabRef if not already installed and the user selected it
39   Call BibTeX # function from InstallThirdPartyProgs.nsh
40
41   # install the LaTeX class files that are delivered with LyX
42   # and enable MiKTeX's automatic package installation
43   Call ConfigureMiKTeX # Function from LaTeX.nsh
44
45   # install Aspell dictionaries
46   Call InstallAspellDictionary # function from Aspell.nsh
47
48   # configure LyX
49   Call ConfigureLyX # Function from ConfigLyX.nsh
50
51   # refresh shell, update the environment variables otherwise the first
52   # configure run will fail when MiKTeX was just installed
53   System::Call 'shell32.dll::SHChangeNotify(i, i, i, i) (${SHCNE_ASSOCCHANGED}, ${SHCNF_IDLIST}, 0, 0)'
54   
55   # create Uninstaller
56   WriteUninstaller "${PRODUCT_UNINSTALL_EXE}"
57   
58   # run LyX's configure script
59   MessageBox MB_OK|MB_ICONINFORMATION "$(LatexConfigInfo)"
60   ExecWait '"$INSTDIR\Resources\configLyX.bat"'
61   Delete "$INSTDIR\Resources\configLyX.bat"
62   
63   # ask to update MiKTeX
64   Call UpdateMiKTeX # function from latex.nsh
65
66  SectionEnd
67
68 !endif # endif ${INSTALLER_VERSION} == "Complete"
69
70 # ----------------------------------------------------------------------------
71
72 !if ${INSTALLER_VERSION} == "Small"
73
74  # The '-' makes the section invisible.
75  Section "-Installation actions" SecInstallation
76
77   # dummy actions to avoid NSIS warnings
78   StrCpy $FileName ""
79   StrCpy $NewString ""
80   StrCpy $OldString ""
81   
82   # extract all files
83   SetOutPath "$INSTDIR"
84   File /r "${PRODUCT_SOURCEDIR}\bin"
85   File /r "${PRODUCT_SOURCEDIR}\etc"
86   File /r "${PRODUCT_SOURCEDIR}\Resources"
87
88   # install GhostScript if not already installed
89   Call Ghostscript # function from InstallThirdPartyProgs.nsh
90
91   # install ImageMagick if not already installed
92   Call ImageMagick # function from InstallThirdPartyProgs.nsh
93
94   # install Aspell if not already installed
95   Call InstallAspell # function from Aspell.nsh
96
97   # install Aiksaurus if not already installed
98   Call Aiksaurus # function from InstallThirdPartyProgs.nsh
99
100   # install the LaTeX class files that are delivered with LyX
101   # and enable MiKTeX's automatic package installation
102   Call ConfigureMiKTeX # Function from LaTeX.nsh
103
104   # install Aspell dictionaries
105   Call InstallAspellDictionary # function from Aspell.nsh
106
107   # configure LyX
108   Call ConfigureLyX # Function from ConfigLyX.nsh
109
110   # create Uninstaller
111   WriteUninstaller "${PRODUCT_UNINSTALL_EXE}"
112
113   # run LyX's configure script
114   MessageBox MB_OK|MB_ICONINFORMATION "$(LatexConfigInfo)"
115   ExecWait '"$INSTDIR\Resources\configLyX.bat"'
116   Delete "$INSTDIR\Resources\configLyX.bat"
117   
118   # ask to update MiKTeX
119   Call UpdateMiKTeX # function from latex.nsh
120
121  SectionEnd
122
123 !endif # endif ${INSTALLER_VERSION} == "Small"
124