|
1 ; $Header$ |
|
2 ; Script generated by ProjectDefinition. |
|
3 |
|
4 !define PRODUCT_NAME "TeaCompiler" |
|
5 !define PRODUCT_FILENAME "TeaCompiler" |
|
6 !define PRODUCT_VERSION "6.2.5.0" |
|
7 !define PRODUCT_PUBLISHER "Jan Vrany" |
|
8 !define PRODUCT_WEB_SITE "http://www.yoursite.com" |
|
9 !define PRODUCT_UNINST_KEY "Software\Microsoft\Windows\CurrentVersion\Uninstall\${PRODUCT_FILENAME}" |
|
10 !define PRODUCT_UNINST_ROOT_KEY "HKLM" |
|
11 |
|
12 !define STX_ROOT "..\..\..\..\stx\.." |
|
13 |
|
14 SetCompressor /solid lzma |
|
15 |
|
16 !include "MUI2.nsh" |
|
17 !include "x64.nsh" |
|
18 |
|
19 ; MUI Settings |
|
20 |
|
21 !define MUI_WELCOMEPAGE_TITLE_3LINES |
|
22 !define MUI_ABORTWARNING |
|
23 !define MUI_ICON "${NSISDIR}\Contrib\Graphics\Icons\modern-install.ico" |
|
24 ;; !define MUI_ICON "nil.ico" |
|
25 !define MUI_UNICON "${NSISDIR}\Contrib\Graphics\Icons\modern-uninstall.ico" |
|
26 ;; !define MUI_UNICON "nil.ico" |
|
27 |
|
28 ; Language Selection Dialog Settings |
|
29 !define MUI_LANGDLL_REGISTRY_ROOT "${PRODUCT_UNINST_ROOT_KEY}" |
|
30 !define MUI_LANGDLL_REGISTRY_KEY "${PRODUCT_UNINST_KEY}" |
|
31 !define MUI_LANGDLL_REGISTRY_VALUENAME "NSIS:Language" |
|
32 |
|
33 ; Welcome page |
|
34 !insertmacro MUI_PAGE_WELCOME |
|
35 ; License page |
|
36 ; !define MUI_LICENSEPAGE_CHECKBOX |
|
37 |
|
38 |
|
39 !insertmacro MUI_PAGE_COMPONENTS |
|
40 ; Directory page |
|
41 !insertmacro MUI_PAGE_DIRECTORY |
|
42 ; Instfiles page |
|
43 !insertmacro MUI_PAGE_INSTFILES |
|
44 ; Finish page |
|
45 !insertmacro MUI_PAGE_FINISH |
|
46 |
|
47 ; Uninstaller pages |
|
48 !insertmacro MUI_UNPAGE_INSTFILES |
|
49 |
|
50 ; Language files |
|
51 !insertmacro MUI_LANGUAGE "English" |
|
52 !insertmacro MUI_LANGUAGE "German" |
|
53 |
|
54 ; MUI end ------ |
|
55 |
|
56 |
|
57 |
|
58 Name "${PRODUCT_NAME} ${PRODUCT_VERSION}" |
|
59 VIProductVersion "${PRODUCT_VERSION}.0" |
|
60 VIAddVersionKey /LANG=${LANG_ENGLISH} "ProductName" "${PRODUCT_NAME}" |
|
61 VIAddVersionKey /LANG=${LANG_ENGLISH} "CompanyName" "${PRODUCT_PUBLISHER}" |
|
62 VIAddVersionKey /LANG=${LANG_ENGLISH} "FileVersion" "6.2.32767.32767" |
|
63 VIAddVersionKey /LANG=${LANG_ENGLISH} "FileDescription" "${PRODUCT_NAME} Installer" |
|
64 VIAddVersionKey /LANG=${LANG_ENGLISH} "ProductVersion" "${PRODUCT_VERSION}" |
|
65 VIAddVersionKey /LANG=${LANG_ENGLISH} "LegalCopyright" "(C) 2015 Jan Vrany" |
|
66 |
|
67 |
|
68 OutFile "TeaCompilerSetup.exe" |
|
69 InstallDir "$PROGRAMFILES\cli" |
|
70 ShowInstDetails show |
|
71 ShowUnInstDetails show |
|
72 |
|
73 Function .onInit |
|
74 !insertmacro MUI_LANGDLL_DISPLAY |
|
75 FunctionEnd |
|
76 |
|
77 InstType Full |
|
78 InstType Partial |
|
79 |
|
80 Section "Programme" Section1 |
|
81 SectionIn 1 2 |
|
82 SetOutPath "$INSTDIR\bin" |
|
83 SetOverwrite ifnewer |
|
84 File "teak.com" |
|
85 File "*.dll" |
|
86 File "symbols.stc" |
|
87 File "*.stx" |
|
88 File "*.rc" |
|
89 File /r /x CVS /x ".*" resources |
|
90 |
|
91 |
|
92 |
|
93 |
|
94 |
|
95 WriteRegStr HKCR "Jv.TeaCompiler.1" "" "TeaCompiler File" |
|
96 WriteRegStr HKCR "Jv.TeaCompiler.1\DefaultIcon" "" '$INSTDIR\bin\teak.exe,0' |
|
97 WriteRegStr HKCR "Jv.TeaCompiler.1\Shell\open" "" $(appOpen) |
|
98 WriteRegStr HKCR "Jv.TeaCompiler.1\Shell\open\command" "" '"$INSTDIR\bin\teak.exe" -- "%1"' |
|
99 SectionEnd |
|
100 |
|
101 ;; Section "Online-Documentation for TeaCompiler" Section2 |
|
102 ;; SectionIn 1 |
|
103 ;; SetOutPath "$INSTDIR\doc" |
|
104 ;; SetOverwrite ifnewer |
|
105 ;; File /r /x CVS "${STX_ROOT}\jv\teak\doc\*" |
|
106 ;; SectionEnd |
|
107 |
|
108 ;; Section "TeaCompiler Libraries and Demos" Section3 |
|
109 ;; SectionIn 1 |
|
110 ;; SetOutPath "$INSTDIR\lib" |
|
111 ;; SetOverwrite ifnewer |
|
112 ;; ; File /r /x CVS "${STX_ROOT}\jv\teak\examples\*" |
|
113 ;; SectionEnd |
|
114 ;; |
|
115 ;; Section "TeaCompiler Reports and Printing" Section4 |
|
116 ;; SectionIn 1 |
|
117 ;; SetOutPath "$INSTDIR\reportGenerator" |
|
118 ;; SetOverwrite ifnewer |
|
119 ;; ; File /r /x CVS "..\reportGenerator\java" "..\reportGenerator\rules" "..\reportGenerator\*.xml" "..\reportGenerator\*.xslt" "..\reportGenerator\CloseApp.exe" "..\reportGenerator\expecco.jpg" |
|
120 ;; SectionEnd |
|
121 |
|
122 |
|
123 |
|
124 |
|
125 |
|
126 |
|
127 |
|
128 |
|
129 Section -AdditionalIcons |
|
130 SetOutPath "$INSTDIR\bin" |
|
131 WriteIniStr "$INSTDIR\${PRODUCT_FILENAME}.url" "InternetShortcut" "URL" "${PRODUCT_WEB_SITE}" |
|
132 CreateDirectory "$SMPROGRAMS\${PRODUCT_FILENAME}" |
|
133 CreateShortCut "$SMPROGRAMS\${PRODUCT_FILENAME}\teak.lnk" "$INSTDIR\bin\teak.exe" |
|
134 CreateShortCut "$DESKTOP\teak.lnk" "$INSTDIR\bin\teak.exe" |
|
135 CreateShortCut "$SMPROGRAMS\${PRODUCT_FILENAME}\Website.lnk" "$INSTDIR\${PRODUCT_FILENAME}.url" |
|
136 CreateShortCut "$SMPROGRAMS\${PRODUCT_FILENAME}\Uninstall.lnk" "$INSTDIR\uninst.exe" |
|
137 SectionEnd |
|
138 |
|
139 Section -Post |
|
140 WriteUninstaller "$INSTDIR\uninst.exe" |
|
141 WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayName" "$(^Name)" |
|
142 WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "UninstallString" "$INSTDIR\uninst.exe" |
|
143 WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayVersion" "${PRODUCT_VERSION}" |
|
144 WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "URLInfoAbout" "${PRODUCT_WEB_SITE}" |
|
145 WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "Publisher" "${PRODUCT_PUBLISHER}" |
|
146 SectionEnd |
|
147 |
|
148 LangString appOpen ${LANG_GERMAN} "Mit TeaCompiler öffnen" |
|
149 LangString appOpen ${LANG_ENGLISH} "Open with TeaCompiler" |
|
150 |
|
151 LangString DESC_Section1 ${LANG_ENGLISH} "Program components of TeaCompiler" |
|
152 LangString DESC_Section1 ${LANG_GERMAN} "Alle Programmkomponenten von TeaCompiler" |
|
153 ;; LangString DESC_Section2 ${LANG_ENGLISH} "Online-Documentation of TeaCompiler" |
|
154 ;; LangString DESC_Section2 ${LANG_GERMAN} "Online-Dokumentation zu TeaCompiler" |
|
155 ;; LangString DESC_Section3 ${LANG_ENGLISH} "Libraries and Demo Projects" |
|
156 ;; LangString DESC_Section3 ${LANG_GERMAN} "Bibliotheken und Beispielprojekte" |
|
157 ;; LangString DESC_Section4 ${LANG_ENGLISH} "Logfile Printing and Report Generation" |
|
158 ;; LangString DESC_Section4 ${LANG_GERMAN} "Drucken und Report-Generierung aus Log-Dateien" |
|
159 ;; LangString DESC_Section3 ${LANG_ENGLISH} "Sources of ST/X (Base-System)" |
|
160 ;; LangString DESC_Section3 ${LANG_GERMAN} "Quellcode von ST/X (Basis-System)" |
|
161 ;; LangString DESC_Section4 ${LANG_ENGLISH} "Sources of TeaCompiler" |
|
162 ;; LangString DESC_Section4 ${LANG_GERMAN} "Quellcode von TeaCompiler" |
|
163 |
|
164 |
|
165 !insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN |
|
166 !insertmacro MUI_DESCRIPTION_TEXT ${Section1} $(DESC_Section1) |
|
167 ;; !insertmacro MUI_DESCRIPTION_TEXT ${Section2} $(DESC_Section2) |
|
168 ;; !insertmacro MUI_DESCRIPTION_TEXT ${Section3} $(DESC_Section3) |
|
169 ;; !insertmacro MUI_DESCRIPTION_TEXT ${Section4} $(DESC_Section4) |
|
170 |
|
171 !insertmacro MUI_FUNCTION_DESCRIPTION_END |
|
172 |
|
173 |
|
174 |
|
175 Function un.onUninstSuccess |
|
176 HideWindow |
|
177 MessageBox MB_ICONINFORMATION|MB_OK "TeaCompiler wurde erfolgreich deinstalliert" |
|
178 FunctionEnd |
|
179 |
|
180 Function un.onInit |
|
181 !insertmacro MUI_UNGETLANGUAGE |
|
182 MessageBox MB_ICONQUESTION|MB_YESNO|MB_DEFBUTTON2 "Möchten Sie TeaCompiler und alle seine Komponenten deinstallieren?" IDYES +2 |
|
183 Abort |
|
184 FunctionEnd |
|
185 |
|
186 Section Uninstall |
|
187 Delete "$INSTDIR\${PRODUCT_FILENAME}.url" |
|
188 Delete "$INSTDIR\uninst.exe" |
|
189 |
|
190 Delete "$INSTDIR\*" |
|
191 RMDir /r "$INSTDIR" |
|
192 |
|
193 Delete "$SMPROGRAMS\${PRODUCT_FILENAME}\Uninstall.lnk" |
|
194 Delete "$SMPROGRAMS\${PRODUCT_FILENAME}\Website.lnk" |
|
195 Delete "$SMPROGRAMS\${PRODUCT_FILENAME}\teak.lnk" |
|
196 Delete "$DESKTOP\teak.lnk" |
|
197 |
|
198 RMDir "$SMPROGRAMS\${PRODUCT_FILENAME}" |
|
199 |
|
200 DeleteRegKey ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" |
|
201 DeleteRegKey HKCR "Jv.TeaCompiler.1" |
|
202 |
|
203 |
|
204 |
|
205 SetAutoClose true |
|
206 SectionEnd |