1 ;OpenAFS Install Script for NSIS
3 ; Written by Rob Murawski <rsm4@ieee.org>
6 ;NSIS Modern User Interface version 1.63
7 ;MultiLanguage Example Script
8 ;Written by Joost Verburg
10 ; Read in the environment information
11 !include ${INCLUDEDIR}\nsi-includes.nsi
12 ; Define DEBUG if building a DEBUG installer
14 ; This version compiles with NSIS v2.0
18 Name "OpenAFS ${AFS_VERSION} ${__DATE__} ${__TIME__}"
20 Name "OpenAFS ${AFS_VERSION} ${__DATE__} ${__TIME__} Checked/Debug"
21 !endif ; End DEBUG/!DEBUG
24 Name "OpenAFS ${AFS_VERSION}"
26 Name "OpenAFS ${AFS_VERSION} Checked/Debug"
27 !endif ; End DEBUG/!DEBUG
29 VIProductVersion "${AFS_VERSION}.00"
30 VIAddVersionKey "ProductName" "OpenAFS"
31 VIAddVersionKey "CompanyName" "OpenAFS.org"
32 VIAddVersionKey "ProductVersion" ${AFS_VERSION}
33 VIAddVersionKey "FileVersion" ${AFS_VERSION}
34 VIAddVersionKey "FileDescription" "OpenAFS for Windows Installer"
35 VIAddVersionKey "LegalCopyright" "(C)2000-2004"
37 VIAddVersionKey "PrivateBuild" "Checked/Debug"
44 ;--------------------------------
47 !define REPLACEDLL_NOREGISTER
51 OutFile "${AFS_DESTDIR}\WinInstall\OpenAFSforWindows.exe"
53 OutFile "${AFS_DESTDIR}\WinInstall\OpenAFSforWindows-DEBUG.exe"
57 !define MUI_ICON "..\..\client_config\afs_config.ico"
58 !define MUI_UNICON "..\..\client_config\afs_config.ico"
59 !define AFS_COMPANY_NAME "OpenAFS"
60 !define AFS_PRODUCT_NAME "OpenAFS"
61 !define AFS_REGKEY_ROOT "Software\TransarcCorporation"
64 ;Folder selection page
65 InstallDir "$PROGRAMFILES\OpenAFS" ; Install to shorter path
67 ;Remember install folder
68 InstallDirRegKey HKCU ${AFS_REGKEY_ROOT} ""
70 ;Remember the installer language
71 !define MUI_LANGDLL_REGISTRY_ROOT "HKCU"
72 !define MUI_LANGDLL_REGISTRY_KEY ${AFS_REGKEY_ROOT}
73 !define MUI_LANGDLL_REGISTRY_VALUENAME "Installer Language"
76 !define AFS_CLIENT_BUILDDIR "${AFS_DESTDIR}\root.client\usr\vice\etc"
77 !define AFS_WININSTALL_DIR "${AFS_DESTDIR}\WinInstall\Config"
78 !define AFS_BUILD_INCDIR "${AFS_DESTDIR}\include"
79 !define AFS_CLIENT_LIBDIR "${AFS_DESTDIR}\lib"
80 !define AFS_SERVER_BUILDDIR "${AFS_DESTDIR}\root.server\usr\afs\bin"
81 !define AFS_ETC_BUILDDIR "${AFS_DESTDIR}\etc"
82 !define SYSTEMDIR "$%SystemRoot%\System32"
84 ;--------------------------------
85 ;Modern UI Configuration
87 ;!define MUI_LICENSEPAGE
88 !define MUI_CUSTOMPAGECOMMANDS
89 !define MUI_WELCOMEPAGE
90 !define MUI_COMPONENTSPAGE
91 !define MUI_COMPONENTSPAGE_SMALLDESC
92 !define MUI_DIRECTORYPAGE
94 !define MUI_ABORTWARNING
95 !define MUI_FINISHPAGE
97 !define MUI_UNINSTALLER
98 !define MUI_UNCONFIRMPAGE
101 !insertmacro MUI_PAGE_WELCOME
102 !insertmacro MUI_PAGE_COMPONENTS
103 !insertmacro MUI_PAGE_DIRECTORY
104 Page custom AFSPageGetCellServDB
105 Page custom AFSPageGetCellName
106 !insertmacro MUI_PAGE_INSTFILES
107 !insertmacro MUI_PAGE_FINISH
109 ;LicenseData "Licenses.rtf"
110 ;--------------------------------
113 !insertmacro MUI_LANGUAGE "English"
114 ;!insertmacro MUI_LANGUAGE "French"
115 !insertmacro MUI_LANGUAGE "German"
116 !insertmacro MUI_LANGUAGE "Spanish"
117 !insertmacro MUI_LANGUAGE "SimpChinese"
118 !insertmacro MUI_LANGUAGE "TradChinese"
119 !insertmacro MUI_LANGUAGE "Japanese"
120 !insertmacro MUI_LANGUAGE "Korean"
121 ;!insertmacro MUI_LANGUAGE "Italian"
122 ;!insertmacro MUI_LANGUAGE "Dutch"
123 ;!insertmacro MUI_LANGUAGE "Danish"
124 ;!insertmacro MUI_LANGUAGE "Greek"
125 ;!insertmacro MUI_LANGUAGE "Russian"
126 !insertmacro MUI_LANGUAGE "PortugueseBR"
127 ;!insertmacro MUI_LANGUAGE "Polish"
128 ;!insertmacro MUI_LANGUAGE "Ukrainian"
129 ;!insertmacro MUI_LANGUAGE "Czech"
130 ;!insertmacro MUI_LANGUAGE "Slovak"
131 ;!insertmacro MUI_LANGUAGE "Croatian"
132 ;!insertmacro MUI_LANGUAGE "Bulgarian"
133 ;!insertmacro MUI_LANGUAGE "Hungarian"
134 ;!insertmacro MUI_LANGUAGE "Thai"
135 ;!insertmacro MUI_LANGUAGE "Romanian"
136 ;!insertmacro MUI_LANGUAGE "Macedonian"
137 ;!insertmacro MUI_LANGUAGE "Turkish"
139 ;--------------------------------
143 LangString DESC_SecCopyUI ${LANG_ENGLISH} "OpenAFS for Windows: English"
144 ;LangString DESC_SecCopyUI ${LANG_FRENCH} "OpenAFS for Windows: French"
145 LangString DESC_SecCopyUI ${LANG_GERMAN} "OpenAFS for Windows: German"
146 LangString DESC_SecCopyUI ${LANG_SPANISH} "OpenAFS for Windows: Spanish"
147 LangString DESC_SecCopyUI ${LANG_SIMPCHINESE} "OpenAFS for Windows: Simplified Chinese"
148 LangString DESC_SecCopyUI ${LANG_TRADCHINESE} "OpenAFS for Windows: Traditional Chinese description"
149 LangString DESC_SecCopyUI ${LANG_JAPANESE} "OpenAFS for Windows: Japanese description"
150 LangString DESC_SecCopyUI ${LANG_KOREAN} "OpenAFS for Windows: Korean description"
151 ;LangString DESC_SecCopyUI ${LANG_ITALIAN} "OpenAFS for Windows: Italian description"
152 ;LangString DESC_SecCopyUI ${LANG_DUTCH} "OpenAFS for Windows: Dutch description"
153 ;LangString DESC_SecCopyUI ${LANG_DANISH} "OpenAFS for Windows: Danish description"
154 ;LangString DESC_SecCopyUI ${LANG_GREEK} "OpenAFS for Windows: Greek description"
155 ;LangString DESC_SecCopyUI ${LANG_RUSSIAN} "OpenAFS for Windows: Russian description"
156 LangString DESC_SecCopyUI ${LANG_PORTUGUESEBR} "OpenAFS for Windows: Portuguese (Brasil) description"
157 ;LangString DESC_SecCopyUI ${LANG_POLISH} "OpenAFS for Windows: Polish description"
158 ;LangString DESC_SecCopyUI ${LANG_UKRAINIAN} "OpenAFS for Windows: Ukrainian description"
159 ;LangString DESC_SecCopyUI ${LANG_CZECH} "OpenAFS for Windows: Czechian description"
160 ;LangString DESC_SecCopyUI ${LANG_SLOVAK} "OpenAFS for Windows: Slovakian description"
161 ;LangString DESC_SecCopyUI ${LANG_CROATIAN} "OpenAFS for Windows: Slovakian description"
162 ;LangString DESC_SecCopyUI ${LANG_BULGARIAN} "OpenAFS for Windows: Bulgarian description"
163 ;LangString DESC_SecCopyUI ${LANG_HUNGARIAN} "OpenAFS for Windows: Hungarian description"
164 ;LangString DESC_SecCopyUI ${LANG_THAI} "OpenAFS for Windows: Thai description"
165 ;LangString DESC_SecCopyUI ${LANG_ROMANIAN} "OpenAFS for Windows: Romanian description"
166 ;LangString DESC_SecCopyUI ${LANG_MACEDONIAN} "OpenAFS for Windows: Macedonian description"
167 ;LangString DESC_SecCopyUI ${LANG_TURKISH} "OpenAFS for Windows: Turkish description"
169 LangString DESC_secClient ${LANG_ENGLISH} "OpenAFS Client: Allows you to access AFS from your Windows PC."
170 LangString DESC_secClient ${LANG_GERMAN} "OpenAFS Client: Allows you to access AFS from your Windows PC."
171 LangString DESC_secClient ${LANG_SPANISH} "OpenAFS Client: Allows you to access AFS from your Windows PC."
172 LangString DESC_secClient ${LANG_SIMPCHINESE} "OpenAFS Client: Allows you to access AFS from your Windows PC."
173 LangString DESC_secClient ${LANG_TRADCHINESE} "OpenAFS Client: Allows you to access AFS from your Windows PC."
174 LangString DESC_secClient ${LANG_JAPANESE} "OpenAFS Client: Allows you to access AFS from your Windows PC."
175 LangString DESC_secClient ${LANG_KOREAN} "OpenAFS Client: Allows you to access AFS from your Windows PC."
176 LangString DESC_secClient ${LANG_PORTUGUESEBR} "OpenAFS Client: Allows you to access AFS from your Windows PC."
178 LangString DESC_secServer ${LANG_ENGLISH} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
179 LangString DESC_secServer ${LANG_GERMAN} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
180 LangString DESC_secServer ${LANG_SPANISH} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
181 LangString DESC_secServer ${LANG_SIMPCHINESE} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
182 LangString DESC_secServer ${LANG_TRADCHINESE} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
183 LangString DESC_secServer ${LANG_JAPANESE} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
184 LangString DESC_secServer ${LANG_KOREAN} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
185 LangString DESC_secServer ${LANG_PORTUGUESEBR} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
187 LangString DESC_secControl ${LANG_ENGLISH} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
188 LangString DESC_secControl ${LANG_GERMAN} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
189 LangString DESC_secControl ${LANG_SPANISH} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
190 LangString DESC_secControl ${LANG_SIMPCHINESE} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
191 LangString DESC_secControl ${LANG_TRADCHINESE} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
192 LangString DESC_secControl ${LANG_JAPANESE} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
193 LangString DESC_secControl ${LANG_KOREAN} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
194 LangString DESC_secControl ${LANG_PORTUGUESEBR} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
196 LangString DESC_secDocs ${LANG_ENGLISH} "Supplemental Documentation: Additional documentation for using OpenAFS."
197 LangString DESC_secDocs ${LANG_GERMAN} "Supplemental Documentation: Additional documentation for using OpenAFS."
198 LangString DESC_secDocs ${LANG_SPANISH} "Supplemental Documentation: Additional documentation for using OpenAFS."
199 LangString DESC_secDocs ${LANG_SIMPCHINESE} "Supplemental Documentation: Additional documentation for using OpenAFS."
200 LangString DESC_secDocs ${LANG_TRADCHINESE} "Supplemental Documentation: Additional documentation for using OpenAFS."
201 LangString DESC_secDocs ${LANG_JAPANESE} "Supplemental Documentation: Additional documentation for using OpenAFS."
202 LangString DESC_secDocs ${LANG_KOREAN} "Supplemental Documentation: Additional documentation for using OpenAFS."
203 LangString DESC_secDocs ${LANG_PORTUGUESEBR} "Supplemental Documentation: Additional documentation for using OpenAFS."
205 LangString DESC_secSDK ${LANG_ENGLISH} "SDK: Header files and libraries for developing software with OpenAFS."
206 LangString DESC_secSDK ${LANG_GERMAN} "SDK: Header files and libraries for developing software with OpenAFS."
207 LangString DESC_secSDK ${LANG_SPANISH} "SDK: Header files and libraries for developing software with OpenAFS."
208 LangString DESC_secSDK ${LANG_SIMPCHINESE} "SDK: Header files and libraries for developing software with OpenAFS."
209 LangString DESC_secSDK ${LANG_TRADCHINESE} "SDK: Header files and libraries for developing software with OpenAFS."
210 LangString DESC_secSDK ${LANG_JAPANESE} "SDK: Header files and libraries for developing software with OpenAFS."
211 LangString DESC_secSDK ${LANG_KOREAN} "SDK: Header files and libraries for developing software with OpenAFS."
212 LangString DESC_secSDK ${LANG_PORTUGUESEBR} "SDK: Header files and libraries for developing software with OpenAFS."
214 ; Popup error messages
215 LangString CellError ${LANG_ENGLISH} "You must specify a valid CellServDB file to copy during install"
216 LangString CellError ${LANG_GERMAN} "You must specify a valid CellServDB file to copy during the install"
217 LangString CellError ${LANG_SPANISH} "You must specify a valid CellServDB file to copy during the install"
218 LangString CellError ${LANG_SIMPCHINESE} "You must specify a valid CellServDB file to copy during the install"
219 LangString CellError ${LANG_TRADCHINESE} "You must specify a valid CellServDB file to copy during the install"
220 LangString CellError ${LANG_JAPANESE} "You must specify a valid CellServDB file to copy during the install"
221 LangString CellError ${LANG_KOREAN} "You must specify a valid CellServDB file to copy during the install"
222 LangString CellError ${LANG_PORTUGUESEBR} "You must specify a valid CellServDB file to copy during the install"
224 LangString CellNameError ${LANG_ENGLISH} "You must specify a cell name for your client to use."
225 LangString CellNameError ${LANG_GERMAN} "You must specify a cell name for your client to use."
226 LangString CellNameError ${LANG_SPANISH} "You must specify a cell name for your client to use."
227 LangString CellNameError ${LANG_SIMPCHINESE} "You must specify a cell name for your client to use."
228 LangString CellNameError ${LANG_TRADCHINESE} "You must specify a cell name for your client to use."
229 LangString CellNameError ${LANG_JAPANESE} "You must specify a cell name for your client to use."
230 LangString CellNameError ${LANG_KOREAN} "You must specify a cell name for your client to use."
231 LangString CellNameError ${LANG_PORTUGUESEBR} "You must specify a cell name for your client to use."
233 LangString URLError ${LANG_ENGLISH} "You must specify a URL if you choose the option to download the CellServDB."
234 LangString URLError ${LANG_GERMAN} "You must specify a URL if you choose the option to download the CellServDB."
235 LangString URLError ${LANG_SPANISH} "You must specify a URL if you choose the option to download the CellServDB."
236 LangString URLError ${LANG_SIMPCHINESE} "You must specify a URL if you choose the option to download the CellServDB."
237 LangString URLError ${LANG_TRADCHINESE} "You must specify a URL if you choose the option to download the CellServDB."
238 LangString URLError ${LANG_JAPANESE} "You must specify a URL if you choose the option to download the CellServDB."
239 LangString URLError ${LANG_KOREAN} "You must specify a URL if you choose the option to download the CellServDB."
240 LangString URLError ${LANG_PORTUGUESEBR} "You must specify a URL if you choose the option to download the CellServDB."
243 ; Upgrade/re-install strings
244 LangString UPGRADE_CLIENT ${LANG_ENGLISH} "Upgrade AFS Client"
245 LangString UPGRADE_CLIENT ${LANG_GERMAN} "Upgrade AFS Client"
246 LangString UPGRADE_CLIENT ${LANG_SPANISH} "Upgrade AFS Client"
247 LangString UPGRADE_CLIENT ${LANG_SIMPCHINESE} "Upgrade AFS Client"
248 LangString UPGRADE_CLIENT ${LANG_TRADCHINESE} "Upgrade AFS Client"
249 LangString UPGRADE_CLIENT ${LANG_JAPANESE} "Upgrade AFS Client"
250 LangString UPGRADE_CLIENT ${LANG_KOREAN} "Upgrade AFS Client"
251 LangString UPGRADE_CLIENT ${LANG_PORTUGUESEBR} "Upgrade AFS Client"
253 LangString REINSTALL_CLIENT ${LANG_ENGLISH} "Re-install AFS Client"
254 LangString REINSTALL_CLIENT ${LANG_GERMAN} "Re-install AFS Client"
255 LangString REINSTALL_CLIENT ${LANG_SPANISH} "Re-install AFS Client"
256 LangString REINSTALL_CLIENT ${LANG_SIMPCHINESE} "Re-install AFS Client"
257 LangString REINSTALL_CLIENT ${LANG_TRADCHINESE} "Re-install AFS Client"
258 LangString REINSTALL_CLIENT ${LANG_JAPANESE} "Re-install AFS Client"
259 LangString REINSTALL_CLIENT ${LANG_KOREAN} "Re-install AFS Client"
260 LangString REINSTALL_CLIENT ${LANG_PORTUGUESEBR} "Re-install AFS Client"
262 LangString UPGRADE_SERVER ${LANG_ENGLISH} "Upgrade AFS Server"
263 LangString UPGRADE_SERVER ${LANG_GERMAN} "Upgrade AFS Server"
264 LangString UPGRADE_SERVER ${LANG_SPANISH} "Upgrade AFS Server"
265 LangString UPGRADE_SERVER ${LANG_SIMPCHINESE} "Upgrade AFS Server"
266 LangString UPGRADE_SERVER ${LANG_TRADCHINESE} "Upgrade AFS Server"
267 LangString UPGRADE_SERVER ${LANG_JAPANESE} "Upgrade AFS Server"
268 LangString UPGRADE_SERVER ${LANG_KOREAN} "Upgrade AFS Server"
269 LangString UPGRADE_SERVER ${LANG_PORTUGUESEBR} "Upgrade AFS Server"
271 LangString REINSTALL_SERVER ${LANG_ENGLISH} "Re-install AFS Server"
272 LangString REINSTALL_SERVER ${LANG_GERMAN} "Re-install AFS Server"
273 LangString REINSTALL_SERVER ${LANG_SPANISH} "Re-install AFS Server"
274 LangString REINSTALL_SERVER ${LANG_SIMPCHINESE} "Re-install AFS Server"
275 LangString REINSTALL_SERVER ${LANG_TRADCHINESE} "Re-install AFS Server"
276 LangString REINSTALL_SERVER ${LANG_JAPANESE} "Re-install AFS Server"
277 LangString REINSTALL_SERVER ${LANG_KOREAN} "Re-install AFS Server"
278 LangString REINSTALL_SERVER ${LANG_PORTUGUESEBR} "Re-install AFS Server"
280 ReserveFile "CellServPage.ini"
281 ReserveFile "AFSCell.ini"
282 !insertmacro MUI_RESERVEFILE_INSTALLOPTIONS ;InstallOptions plug-in
283 !insertmacro MUI_RESERVEFILE_LANGDLL ;Language selection dialog
284 ;--------------------------------
286 ; Macro - Upgrade DLL File
287 ; Written by Joost Verburg
288 ; ------------------------
291 ; LOCALFILE - Location of the new DLL file (on the compiler system)
292 ; DESTFILE - Location of the DLL file that should be upgraded
293 ; (on the user's system)
294 ; TEMPBASEDIR - Directory on the user's system to store a temporary file
295 ; when the system has to be rebooted.
296 ; For Win9x support, this should be on the same volume as the
298 ; The Windows temp directory could be located on any volume,
299 ; so you cannot use this directory.
301 ; Define REPLACEDLL_NOREGISTER if you want to upgrade a DLL that does not
302 ; have to be registered.
304 ; Note: If you want to support Win9x, you can only use
305 ; short filenames (8.3).
308 ; !insertmacro ReplaceDLL "dllname.dll" "$SYSDIR\dllname.dll" "$SYSDIR"
311 !macro ReplaceDLL LOCALFILE DESTFILE TEMPBASEDIR
320 ;------------------------
321 ;Unique number for labels
323 !define REPLACEDLL_UNIQUE ${__LINE__}
325 ;------------------------
326 ;Copy the parameters used on run-time to a variable
327 ;This allows the usage of variables as paramter
329 StrCpy $R4 "${DESTFILE}"
330 StrCpy $R5 "${TEMPBASEDIR}"
332 ;------------------------
333 ;Check file and version
335 IfFileExists $R4 0 replacedll.copy_${REPLACEDLL_UNIQUE}
338 ; GetDLLVersionLocal "${LOCALFILE}" $R0 $R1
339 ; GetDLLVersion $R4 $R2 $R3
340 ;IfErrors replacedll.upgrade_${REPLACEDLL_UNIQUE}
342 ;IntCmpU $R0 $R2 0 replacedll.done_${REPLACEDLL_UNIQUE} \
343 ; replacedll.upgrade_${REPLACEDLL_UNIQUE}
344 ;IntCmpU $R1 $R3 replacedll.done_${REPLACEDLL_UNIQUE} \
345 ; replacedll.done_${REPLACEDLL_UNIQUE} \
346 ; replacedll.upgrade_${REPLACEDLL_UNIQUE}
348 ;------------------------
349 ;Let's replace the DLL!
353 ;replacedll.upgrade_${REPLACEDLL_UNIQUE}:
354 !ifndef REPLACEDLL_NOREGISTER
359 ;------------------------
360 ;Try to copy the DLL directly
364 Call :replacedll.file_${REPLACEDLL_UNIQUE}
365 IfErrors 0 replacedll.noreboot_${REPLACEDLL_UNIQUE}
367 ;------------------------
368 ;DLL is in use. Copy it to a temp file and Rename it on reboot.
370 GetTempFileName $R0 $R5
371 Call :replacedll.file_${REPLACEDLL_UNIQUE}
372 Rename /REBOOTOK $R0 $R4
374 ;------------------------
375 ;Register the DLL on reboot
377 !ifndef REPLACEDLL_NOREGISTER
378 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\RunOnce" \
379 "Register $R4" 'rundll32.exe "$R4",DllRegisterServer'
382 Goto replacedll.done_${REPLACEDLL_UNIQUE}
384 ;------------------------
385 ;DLL does not exist - just extract
387 replacedll.copy_${REPLACEDLL_UNIQUE}:
389 Call :replacedll.file_${REPLACEDLL_UNIQUE}
391 ;------------------------
394 replacedll.noreboot_${REPLACEDLL_UNIQUE}:
395 !ifndef REPLACEDLL_NOREGISTER
399 ;------------------------
402 replacedll.done_${REPLACEDLL_UNIQUE}:
411 ;------------------------
414 Goto replacedll.end_${REPLACEDLL_UNIQUE}
416 ;------------------------
417 ;Called to extract the DLL
419 replacedll.file_${REPLACEDLL_UNIQUE}:
420 File /oname=$R0 "${LOCALFILE}"
423 replacedll.end_${REPLACEDLL_UNIQUE}:
425 ;------------------------
428 SetOverwrite lastused
430 !undef REPLACEDLL_UNIQUE
435 ;--------------------------------
438 ;Things that need to be extracted on first (keep these lines before any File command!)
439 ;Only useful for BZIP2 compression
440 !insertmacro MUI_RESERVEFILE_LANGDLL
442 ;--------------------------------
452 ;--------------------------------
455 ;----------------------
457 Section "AFS Client" secClient
459 SetShellVarContext all
461 ; Check for bad previous installation (if we are doing a new install)
462 Call IsAnyAFSInstalled
464 StrCmp $R0 "0" +1 skipCheck
468 ; Stop any running services or we can't replace the files
469 ; Stop the running processes
471 File /oname=$R0 "${AFS_WININSTALL_DIR}\Killer.exe" ; Might not have the MSVCR71.DLL file to run
472 nsExec::Exec '$R0 afsd_service.exe'
473 nsExec::Exec '$R0 afscreds.exe'
474 Exec "afscreds.exe -z"
475 ; in case we are upgrading an old version that does not support -z
476 nsExec::Exec '$R0 afscreds.exe'
478 ;nsExec::Exec '$R0 krbcc32s.exe'
481 nsExec::Exec "net stop TransarcAFSDaemon"
482 nsExec::Exec "net stop TransarcAFSServer"
484 ; Do client components
485 SetOutPath "$INSTDIR\Client\Program"
486 File "${AFS_CLIENT_BUILDDIR}\afsshare.exe"
487 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\libosi.dll" "$INSTDIR\Client\Program\libosi.dll" "$INSTDIR"
488 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\libafsconf.dll" "$INSTDIR\Client\Program\libafsconf.dll" "$INSTDIR"
489 File "${AFS_CLIENT_BUILDDIR}\klog.exe"
490 File "${AFS_CLIENT_BUILDDIR}\tokens.exe"
491 File "${AFS_CLIENT_BUILDDIR}\unlog.exe"
492 File "${AFS_CLIENT_BUILDDIR}\fs.exe"
493 File "${AFS_CLIENT_BUILDDIR}\aklog.exe"
494 File "${AFS_CLIENT_BUILDDIR}\afscreds.exe"
495 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext.dll" "$INSTDIR\Client\Program\afs_shl_ext.dll" "$INSTDIR"
496 File "${AFS_CLIENT_BUILDDIR}\afsd_service.exe"
497 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afslogon.dll" "$INSTDIR\Client\Program\afslogon.dll" "$INSTDIR"
498 File "${AFS_CLIENT_BUILDDIR}\symlink.exe"
499 File "${AFS_DESTDIR}\bin\kpasswd.exe"
500 File "${AFS_SERVER_BUILDDIR}\pts.exe"
501 File "${AFS_SERVER_BUILDDIR}\bos.exe"
502 File "${AFS_SERVER_BUILDDIR}\kas.exe"
503 File "${AFS_SERVER_BUILDDIR}\vos.exe"
504 File "${AFS_SERVER_BUILDDIR}\udebug.exe"
505 File "${AFS_DESTDIR}\bin\translate_et.exe"
506 File "${AFS_DESTDIR}\etc\rxdebug.exe"
507 File "${AFS_DESTDIR}\etc\backup.exe"
510 File "${AFS_CLIENT_BUILDDIR}\afsshare.pdb"
511 File "${AFS_CLIENT_BUILDDIR}\libosi.pdb"
512 File "${AFS_CLIENT_BUILDDIR}\libafsconf.pdb"
513 File "${AFS_CLIENT_BUILDDIR}\klog.pdb"
514 File "${AFS_CLIENT_BUILDDIR}\tokens.pdb"
515 File "${AFS_CLIENT_BUILDDIR}\unlog.pdb"
516 File "${AFS_CLIENT_BUILDDIR}\fs.pdb"
517 File "${AFS_CLIENT_BUILDDIR}\aklog.pdb"
518 File "${AFS_CLIENT_BUILDDIR}\afscreds.pdb"
519 File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext.pdb"
520 File "${AFS_CLIENT_BUILDDIR}\afsd_service.pdb"
521 File "${AFS_CLIENT_BUILDDIR}\afslogon.pdb"
522 File "${AFS_CLIENT_BUILDDIR}\symlink.pdb"
523 File "${AFS_DESTDIR}\bin\kpasswd.pdb"
524 File "${AFS_DESTDIR}\bin\pts.pdb"
525 File "${AFS_SERVER_BUILDDIR}\bos.pdb"
526 File "${AFS_SERVER_BUILDDIR}\kas.pdb"
527 File "${AFS_SERVER_BUILDDIR}\vos.pdb"
528 File "${AFS_SERVER_BUILDDIR}\udebug.pdb"
529 File "${AFS_DESTDIR}\bin\translate_et.pdb"
530 File "${AFS_DESTDIR}\etc\rxdebug.pdb"
531 File "${AFS_DESTDIR}\etc\backup.pdb"
539 ; Do WINDOWSDIR components
541 ; Do Windows SYSDIR (Control panel)
543 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa.cpl" "$SYSDIR\afs_cpa.cpl" "$INSTDIR"
545 File "${AFS_CLIENT_BUILDDIR}\afs_cpa.pdb"
548 ; Get AFS CellServDB file
549 Call afs.GetCellServDB
550 !ifdef INSTALL_LOOPBACK
551 Call afs.InstallMSLoopback
555 ; Include Kerberos for Windows files in the installer...
556 SetOutPath "$INSTDIR\kfw\bin\"
557 File "${KFW_SOURCE}\bin\*"
558 SetOutPath "$INSTDIR\kfw\doc"
559 File "${KFW_SOURCE}\doc\*"
562 ;Store install folder
563 WriteRegStr HKCU "${AFS_REGKEY_ROOT}\Client" "" $INSTDIR
564 Call AFSCommon.Install
566 ; Write registry entries
567 WriteRegStr HKCR "*\shellex\ContextMenuHandlers\AFS Client Shell Extension" "" "{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}"
568 WriteRegStr HKCR "CLSID\{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}" "" "AFS Client Shell Extension"
569 WriteRegStr HKCR "CLSID\{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}\InprocServer32" "" "$INSTDIR\Client\Program\afs_shl_ext.dll"
570 WriteRegStr HKCR "CLSID\{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}\InprocServer32" "ThreadingModel" "Apartment"
571 WriteRegStr HKCR "FOLDER\shellex\ContextMenuHandlers\AFS Client Shell Extension" "" "{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}"
572 WriteRegStr HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Shell Extensions\Approved" "{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}" "AFS Client Shell Extension"
575 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion"
576 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "VersionString" ${AFS_VERSION}
577 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "Title" "AFS Client"
578 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "Description" "AFS Client"
579 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "PathName" "$INSTDIR\Client"
580 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "Software Type" "File System"
581 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "MajorVersion" ${AFS_MAJORVERSION}
582 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "MinorVersion" ${AFS_MINORVERSION}
583 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "PatchLevel" ${AFS_PATCHLEVEL}
584 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "VersionString" ${AFS_VERSION}
585 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "Title" "AFS Client"
586 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "Description" "AFS Client"
587 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "Software Type" "File System"
588 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "PathName" "$INSTDIR\Client\Program"
589 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "MajorVersion" ${AFS_MAJORVERSION}
590 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "MinorVersion" ${AFS_MINORVERSION}
591 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "PatchLevel" ${AFS_PATCHLEVEL}
593 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "Debug" 1
594 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "Debug" 1
596 ; Delete the DEBUG string
597 DeleteRegValue HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "Debug"
598 DeleteRegValue HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "Debug"
601 ; On Windows 2000 work around KB301673. This is fixed in Windows XP and 2003
602 Call GetWindowsVersion
604 StrCmp $R1 "2000" +1 +2
605 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\NetBT\Parameters" "SmbDeviceEnabled" 0
607 ;Write start menu entries
608 CreateDirectory "$SMPROGRAMS\OpenAFS\Client"
609 CreateShortCut "$SMPROGRAMS\OpenAFS\Uninstall OpenAFS.lnk" "$INSTDIR\Uninstall.exe"
610 CreateShortCut "$SMPROGRAMS\OpenAFS\Client\Authentication.lnk" "$INSTDIR\Client\Program\afscreds.exe" "-A -M -N -Q"
611 CreateShortCut "$SMSTARTUP\AFS Credentials.lnk" "$INSTDIR\Client\Program\afscreds.exe" "-A -M -N -Q"
613 Push "$INSTDIR\Client\Program"
615 Push "$INSTDIR\Common"
619 ; Add kfw to path too
620 Push "$INSTDIR\kfw\bin"
624 ; Create the AFS service
625 SetOutPath "$INSTDIR\Common"
626 File "${AFS_WININSTALL_DIR}\Service.exe"
627 nsExec::Exec "net stop TransarcAFSDaemon"
628 ;IMPORTANT! If we are not refreshing the config files, do NOT remove the service
629 ;Don't re-install because it must be present or we wouldn't have passed the Reg check
631 ReadRegStr $R2 HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "Cell"
632 StrCmp $R2 "" +1 skipremove
633 nsExec::Exec '$INSTDIR\Common\Service.exe u TransarcAFSDaemon'
634 nsExec::Exec '$INSTDIR\Common\Service.exe TransarcAFSDaemon "$INSTDIR\Client\Program\afsd_service.exe" "OpenAFS Client Service"'
636 Delete "$INSTDIR\Common\service.exe"
639 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon" "" ""
640 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "ProviderPath" "$INSTDIR\Client\Program\afslogon.dll"
641 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "AuthentProviderPath" "$INSTDIR\Client\Program\afslogon.dll"
642 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "AuthentProviderPath" "$INSTDIR\Client\Program\afslogon.dll"
643 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "Class" 2
644 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "VerboseLogging" 10
646 ; Must also add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\NetworkProvider\HwOrder
647 ; and HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\NetworkProvider\Order
648 ; to also include the service name.
650 ReadINIStr $R0 $1 "Field 7" "State"
651 ReadINIStr $R1 $1 "Field 9" "State"
652 ; Complicated way to do $R1 = ($R1 *2) + $R0
655 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "LogonOptions" $R1
656 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "LogonScript" "$INSTDIR\Client\Program\afscreds.exe -:%s -x -a -m -n -q"
657 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "Name" "OpenAFSDaemon"
660 ReadINIStr $R0 $1 "Field 2" "State"
661 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "Cell" $R0
662 ReadINIStr $R0 $1 "Field 3" "State"
663 WriteRegDWORD HKLM "SOFTWARE\OpenAFS\Client" "ShowTrayIcon" 1
664 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "SecurityLevel" $R0
665 ReadINIStr $R0 $1 "Field 5" "State"
666 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "FreelanceClient" $R0
667 ReadINIStr $R0 $1 "Field 11" "State"
668 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "UseDNS" $R0
669 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "NetbiosName" "AFS"
670 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "MountRoot" "/afs"
671 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "RxMaxMTU" 1260
672 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "IsGateway" 0
673 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "HideDotFiles" 1
674 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "TruncateNetbios" "on"
676 ; Find Lana By Name appears to be causing grief for many people
677 ; I do not have time to track this down so I am simply going to disable it
678 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "NoFindLanaByName" 1
680 strcpy $REG_SUB_KEY "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon"
681 strcpy $REG_VALUE "DependOnGroup"
682 strcpy $REG_DATA_1 "PNP_TDI"
683 strcpy $REG_DATA_2 ""
684 strcpy $REG_DATA_3 ""
685 Call RegWriteMultiStr
686 strcpy $REG_SUB_KEY "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon"
687 strcpy $REG_VALUE "DependOnService"
688 strcpy $REG_DATA_1 "Tcpip"
689 strcpy $REG_DATA_2 "NETBIOS"
690 strcpy $REG_DATA_3 "RpcSs"
691 Call RegWriteMultiStr
695 WriteUninstaller "$INSTDIR\Uninstall.exe"
699 ;------------------------
701 Section "AFS Server" secServer
703 SetShellVarContext all
705 ; Check for bad previous installation (if we are doing a new install)
706 Call IsAnyAFSInstalled
708 StrCmp $R0 "0" +1 skipCheck
712 ; Stop any running services or we can't replace the files
713 ; Stop the running processes
715 File /oname=$R0 "${AFS_WININSTALL_DIR}\Killer.exe" ; Might not have the MSVCR71.DLL file to run
716 nsExec::Exec '$R0 afscreds.exe'
717 Exec "afscreds.exe -z"
718 ; in case we are upgrading an old version that does not support -z
720 nsExec::Exec '$R0 afscreds.exe'
722 ;nsExec::Exec '$R0 krbcc32s.exe'
725 nsExec::Exec "net stop TransarcAFSDaemon"
726 nsExec::Exec "net stop TransarcAFSServer"
728 CreateDirectory "$INSTDIR\Server\usr\afs\etc"
729 CreateDirectory "$INSTDIR\Server\usr\afs\local"
730 CreateDirectory "$INSTDIR\Server\usr\afs\etc\logs"
732 SetOutPath "$INSTDIR\Server\usr\afs\bin"
733 File "${AFS_SERVER_BUILDDIR}\afskill.exe"
734 File "${AFS_SERVER_BUILDDIR}\afssvrcfg.exe"
735 File "${AFS_SERVER_BUILDDIR}\bosctlsvc.exe"
736 File "${AFS_SERVER_BUILDDIR}\bosserver.exe"
737 File "${AFS_SERVER_BUILDDIR}\buserver.exe"
738 File "${AFS_ETC_BUILDDIR}\butc.exe"
739 File "${AFS_SERVER_BUILDDIR}\fileserver.exe"
740 File "${AFS_ETC_BUILDDIR}\fms.exe"
741 File "${AFS_SERVER_BUILDDIR}\kaserver.exe"
742 File "${AFS_SERVER_BUILDDIR}\ptserver.exe"
743 File "${AFS_SERVER_BUILDDIR}\salvager.exe"
744 File "${AFS_SERVER_BUILDDIR}\upclient.exe"
745 File "${AFS_SERVER_BUILDDIR}\upserver.exe"
746 File "${AFS_SERVER_BUILDDIR}\vlserver.exe"
747 File "${AFS_SERVER_BUILDDIR}\volinfo.exe"
748 File "${AFS_SERVER_BUILDDIR}\volserver.exe"
751 File "${AFS_SERVER_BUILDDIR}\afskill.pdb"
752 File "${AFS_SERVER_BUILDDIR}\afssvrcfg.pdb"
753 File "${AFS_SERVER_BUILDDIR}\bosctlsvc.pdb"
754 File "${AFS_SERVER_BUILDDIR}\bosserver.pdb"
755 File "${AFS_SERVER_BUILDDIR}\buserver.pdb"
756 File "${AFS_ETC_BUILDDIR}\butc.pdb"
757 File "${AFS_SERVER_BUILDDIR}\fileserver.pdb"
758 File "${AFS_ETC_BUILDDIR}\fms.pdb"
759 File "${AFS_SERVER_BUILDDIR}\kaserver.pdb"
760 File "${AFS_SERVER_BUILDDIR}\ptserver.pdb"
761 File "${AFS_SERVER_BUILDDIR}\salvager.pdb"
762 File "${AFS_SERVER_BUILDDIR}\upclient.pdb"
763 File "${AFS_SERVER_BUILDDIR}\upserver.pdb"
764 File "${AFS_SERVER_BUILDDIR}\vlserver.pdb"
765 File "${AFS_SERVER_BUILDDIR}\volinfo.pdb"
766 File "${AFS_SERVER_BUILDDIR}\volserver.pdb"
769 ;AFS Server common files
770 SetOutPath "$INSTDIR\Common"
771 File "${AFS_SERVER_BUILDDIR}\afsvosadmin.dll"
772 File "${AFS_SERVER_BUILDDIR}\afsbosadmin.dll"
773 File "${AFS_SERVER_BUILDDIR}\afscfgadmin.dll"
774 File "${AFS_SERVER_BUILDDIR}\afskasadmin.dll"
775 File "${AFS_SERVER_BUILDDIR}\afsptsadmin.dll"
778 File "${AFS_SERVER_BUILDDIR}\afsvosadmin.pdb"
779 File "${AFS_SERVER_BUILDDIR}\afsbosadmin.pdb"
780 File "${AFS_SERVER_BUILDDIR}\afscfgadmin.pdb"
781 File "${AFS_SERVER_BUILDDIR}\afskasadmin.pdb"
782 File "${AFS_SERVER_BUILDDIR}\afsptsadmin.pdb"
784 SetOutPath "$INSTDIR\Common"
788 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver.cpl" "$SYSDIR\afsserver.cpl" "$INSTDIR"
791 File "${AFS_SERVER_BUILDDIR}\afsserver.pdb"
794 ;Store install folder
795 WriteRegStr HKCU "${AFS_REGKEY_ROOT}\AFS Server" "" $INSTDIR
797 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion"
798 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "VersionString" ${AFS_VERSION}
799 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "Title" "AFS Server"
800 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "Description" "AFS Server for Windows"
801 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "PathName" "$INSTDIR\Server"
802 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "Software Type" "File System"
803 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "MajorVersion" ${AFS_MAJORVERSION}
804 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "MinorVersion" ${AFS_MINORVERSION}
805 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "PatchLevel" ${AFS_PATCHLEVEL}
806 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "VersionString" ${AFS_VERSION}
807 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "Title" "AFS Server"
808 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "Description" "AFS Server for Windows"
809 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "Software Type" "File System"
810 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "PathName" "$INSTDIR\Server"
811 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "MajorVersion" ${AFS_MAJORVERSION}
812 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "MinorVersion" ${AFS_MINORVERSION}
813 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "PatchLevel" ${AFS_PATCHLEVEL}
815 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "Debug" 1
816 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "Debug" 1
818 ; Delete the DEBUG string
819 DeleteRegValue HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "Debug"
820 DeleteRegValue HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "Debug"
822 ; Install the service
823 SetOutPath "$INSTDIR\Common"
824 File "${AFS_WININSTALL_DIR}\Service.exe"
826 File "${AFS_WININSTALL_DIR}\Service.pdb"
828 ;Don't want to whack existing settings... Make users un-install and then re-install if they want that
829 ;nsExec::Exec '$INSTDIR\Common\service.exe u TransarcAFSServer'
830 nsExec::Exec '$INSTDIR\Common\service.exe TransarcAFSServer "$INSTDIR\Server\usr\afs\bin\bosctlsvc.exe" "OpenAFS AFS Server"'
831 Delete "$INSTDIR\Common\service.exe"
833 CreateDirectory "$SMPROGRAMS\OpenAFS\Server"
834 CreateShortCut "$SMPROGRAMS\OpenAFS\Server\Server Configuration.lnk" "$INSTDIR\Server\usr\afs\bin\afssvrcfg.exe"
836 ; Make the server config wizard auto-start on bootup
837 WriteRegStr HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce" "AFS Server Wizard" '"$INSTDIR\Server\usr\afs\bin\afssvrcfg.exe" /wizard"'
839 WriteUninstaller "$INSTDIR\Uninstall.exe"
844 ;----------------------------
845 ; OpenAFS Control Center
846 Section "AFS Control Center" secControl
848 SetShellVarContext all
850 SetOutPath "$INSTDIR\Control Center"
851 File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager.exe"
852 File "${AFS_SERVER_BUILDDIR}\TaAfsAdmSvr.exe"
853 File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager.exe"
856 File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager.pdb"
857 File "${AFS_SERVER_BUILDDIR}\TaAfsAdmSvr.pdb"
858 File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager.pdb"
861 ;AFS Server common files
862 Call AFSCommon.Install
864 SetOutPath "$INSTDIR\Common"
866 SetOutPath "$INSTDIR\Common"
869 File "${SYSTEMDIR}\msvcr71d.dll"
870 File "${SYSTEMDIR}\msvcr71d.pdb"
871 File "${SYSTEMDIR}\msvcp71d.dll"
872 File "${SYSTEMDIR}\msvcp71d.pdb"
873 File "${SYSTEMDIR}\mfc71d.dll"
874 File "${SYSTEMDIR}\mfc71d.pdb"
875 File "${SYSTEMDIR}\MFC71CHS.DLL"
876 File "${SYSTEMDIR}\MFC71CHT.DLL"
877 File "${SYSTEMDIR}\MFC71DEU.DLL"
878 File "${SYSTEMDIR}\MFC71ENU.DLL"
879 File "${SYSTEMDIR}\MFC71ESP.DLL"
880 File "${SYSTEMDIR}\MFC71FRA.DLL"
881 File "${SYSTEMDIR}\MFC71ITA.DLL"
882 File "${SYSTEMDIR}\MFC71JPN.DLL"
883 File "${SYSTEMDIR}\MFC71KOR.DLL"
886 File "${SYSTEMDIR}\msvcr70d.dll"
887 File "${SYSTEMDIR}\msvcr70d.pdb"
888 File "${SYSTEMDIR}\msvcp70d.dll"
889 File "${SYSTEMDIR}\msvcp70d.pdb"
890 File "${SYSTEMDIR}\mfc70d.dll"
891 File "${SYSTEMDIR}\mfc70d.pdb"
892 File "${SYSTEMDIR}\MFC70CHS.DLL"
893 File "${SYSTEMDIR}\MFC70CHT.DLL"
894 File "${SYSTEMDIR}\MFC70DEU.DLL"
895 File "${SYSTEMDIR}\MFC70ENU.DLL"
896 File "${SYSTEMDIR}\MFC70ESP.DLL"
897 File "${SYSTEMDIR}\MFC70FRA.DLL"
898 File "${SYSTEMDIR}\MFC70ITA.DLL"
899 File "${SYSTEMDIR}\MFC70JPN.DLL"
900 File "${SYSTEMDIR}\MFC70KOR.DLL"
902 File "${SYSTEMDIR}\mfc42d.dll"
903 File "${SYSTEMDIR}\mfc42d.pdb"
904 File "${SYSTEMDIR}\msvcp60d.dll"
905 File "${SYSTEMDIR}\msvcp60d.pdb"
906 File "${SYSTEMDIR}\msvcrtd.dll"
907 File "${SYSTEMDIR}\msvcrtd.pdb"
912 File "${SYSTEMDIR}\mfc71.dll"
913 File "${SYSTEMDIR}\msvcr71.dll"
914 File "${SYSTEMDIR}\msvcp71.dll"
915 File "${SYSTEMDIR}\MFC71CHS.DLL"
916 File "${SYSTEMDIR}\MFC71CHT.DLL"
917 File "${SYSTEMDIR}\MFC71DEU.DLL"
918 File "${SYSTEMDIR}\MFC71ENU.DLL"
919 File "${SYSTEMDIR}\MFC71ESP.DLL"
920 File "${SYSTEMDIR}\MFC71FRA.DLL"
921 File "${SYSTEMDIR}\MFC71ITA.DLL"
922 File "${SYSTEMDIR}\MFC71JPN.DLL"
923 File "${SYSTEMDIR}\MFC71KOR.DLL"
926 File "${SYSTEMDIR}\mfc70.dll"
927 File "${SYSTEMDIR}\msvcr70.dll"
928 File "${SYSTEMDIR}\msvcp70.dll"
929 File "${SYSTEMDIR}\MFC70CHS.DLL"
930 File "${SYSTEMDIR}\MFC70CHT.DLL"
931 File "${SYSTEMDIR}\MFC70DEU.DLL"
932 File "${SYSTEMDIR}\MFC70ENU.DLL"
933 File "${SYSTEMDIR}\MFC70ESP.DLL"
934 File "${SYSTEMDIR}\MFC70FRA.DLL"
935 File "${SYSTEMDIR}\MFC70ITA.DLL"
936 File "${SYSTEMDIR}\MFC70JPN.DLL"
937 File "${SYSTEMDIR}\MFC70KOR.DLL"
939 File "${SYSTEMDIR}\mfc42.dll"
940 File "${SYSTEMDIR}\msvcp60.dll"
941 File "${SYSTEMDIR}\msvcrt.dll"
945 ;Store install folder
946 WriteRegStr HKCU "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "PathName" $INSTDIR
947 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "VersionString" ${AFS_VERSION}
948 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "MajorVersion" ${AFS_MAJORVERSION}
949 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "MinorVersion" ${AFS_MINORVERSION}
950 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "PatchLevel" ${AFS_PATCHLEVEL}
951 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "VersionString" ${AFS_VERSION}
952 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "MajorVersion" ${AFS_MAJORVERSION}
953 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "MinorVersion" ${AFS_MINORVERSION}
954 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "PatchLevel" ${AFS_PATCHLEVEL}
956 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "Debug" 1
957 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "Debug" 1
959 ; Delete the DEBUG string
960 DeleteRegValue HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "Debug"
961 DeleteRegValue HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "Debug"
964 ;Write start menu entries
965 CreateDirectory "$SMPROGRAMS\OpenAFS\Control Center"
966 CreateShortCut "$SMPROGRAMS\OpenAFS\Control Center\Account Manager.lnk" "$INSTDIR\Control Center\TaAfsAccountManager.exe"
967 CreateShortCut "$SMPROGRAMS\OpenAFS\Control Center\Server Manager.lnk" "$INSTDIR\Control Center\TaAfsServerManager.exe"
969 WriteUninstaller "$INSTDIR\Uninstall.exe"
974 ;----------------------------
975 ; OpenAFS Supplemental Documentation
976 Section "Supplemental Documentation" secDocs
977 SetShellVarContext all
979 StrCmp $LANGUAGE ${LANG_ENGLISH} DoEnglish
980 StrCmp $LANGUAGE ${LANG_GERMAN} DoGerman
981 StrCmp $LANGUAGE ${LANG_SPANISH} DoSpanish
982 StrCmp $LANGUAGE ${LANG_JAPANESE} DoJapanese
983 StrCmp $LANGUAGE ${LANG_KOREAN} DoKorean
984 StrCmp $LANGUAGE ${LANG_PORTUGUESEBR} DoPortugueseBR
985 StrCmp $LANGUAGE ${LANG_SIMPCHINESE} DoSimpChinese
986 StrCmp $LANGUAGE ${LANG_TRADCHINESE} DoTradChinese
990 SetOutPath "$INSTDIR\Documentation\html"
991 File "..\..\doc\install\Documentation\en_US\html\*"
992 SetOutPath "$INSTDIR\Documentation\html\CmdRef"
993 File "..\..\doc\install\Documentation\en_US\html\CmdRef\*"
994 SetOutPath "$INSTDIR\Documentation\html\InstallGd"
995 File "..\..\doc\install\Documentation\en_US\html\InstallGd\*"
996 SetOutPath "$INSTDIR\Documentation\html\ReleaseNotes"
997 File "..\..\doc\install\Documentation\en_US\html\ReleaseNotes\*"
998 SetOutPath "$INSTDIR\Documentation\html\SysAdminGd"
999 File "..\..\doc\install\Documentation\en_US\html\SysAdminGd\*"
1003 SetOutPath "$INSTDIR\Documentation"
1004 File "..\..\doc\install\Documentation\de_DE\README.TXT"
1005 SetOutPath "$INSTDIR\Documentation\html"
1006 File "..\..\doc\install\Documentation\de_DE\html\*"
1007 SetOutPath "$INSTDIR\Documentation\html\CmdRef"
1008 ;File "..\..\doc\install\Documentation\de_DE\html\CmdRef\*"
1009 SetOutPath "$INSTDIR\Documentation\html\InstallGd"
1010 File "..\..\doc\install\Documentation\de_DE\html\InstallGd\*"
1011 ;SetOutPath "$INSTDIR\Documentation\html\ReleaseNotes"
1012 ;File "..\..\doc\install\Documentation\de_DE\html\ReleaseNotes\*"
1013 ;SetOutPath "$INSTDIR\Documentation\html\SysAdminGd"
1014 ;File "..\..\doc\install\Documentation\de_DE\html\SysAdminGd\*"
1018 SetOutPath "$INSTDIR\Documentation"
1019 File "..\..\doc\install\Documentation\es_ES\README.TXT"
1020 SetOutPath "$INSTDIR\Documentation\html"
1021 File "..\..\doc\install\Documentation\es_ES\html\*"
1022 SetOutPath "$INSTDIR\Documentation\html\CmdRef"
1023 ;File "..\..\doc\install\Documentation\es_ES\html\CmdRef\*"
1024 SetOutPath "$INSTDIR\Documentation\html\InstallGd"
1025 ;File "..\..\doc\install\Documentation\es_ES\html\InstallGd\*"
1026 SetOutPath "$INSTDIR\Documentation\html\ReleaseNotes"
1027 ;File "..\..\doc\install\Documentation\es_ES\html\ReleaseNotes\*"
1028 SetOutPath "$INSTDIR\Documentation\html\SysAdminGd"
1029 ;File "..\..\doc\install\Documentation\es_ES\html\SysAdminGd\*"
1033 SetOutPath "$INSTDIR\Documentation"
1034 File "..\..\doc\install\Documentation\ja_JP\README.TXT"
1035 SetOutPath "$INSTDIR\Documentation\html"
1036 File "..\..\doc\install\Documentation\ja_JP\html\*"
1037 SetOutPath "$INSTDIR\Documentation\html\CmdRef"
1038 File "..\..\doc\install\Documentation\ja_JP\html\CmdRef\*"
1039 SetOutPath "$INSTDIR\Documentation\html\InstallGd"
1040 File "..\..\doc\install\Documentation\ja_JP\html\InstallGd\*"
1041 SetOutPath "$INSTDIR\Documentation\html\ReleaseNotes"
1042 ;File "..\..\doc\install\Documentation\ja_JP\html\ReleaseNotes\*"
1043 SetOutPath "$INSTDIR\Documentation\html\SysAdminGd"
1044 ;File "..\..\doc\install\Documentation\ja_JP\html\SysAdminGd\*"
1048 SetOutPath "$INSTDIR\Documentation"
1049 File "..\..\doc\install\Documentation\ko_KR\README.TXT"
1050 SetOutPath "$INSTDIR\Documentation\html"
1051 File "..\..\doc\install\Documentation\ko_KR\html\*"
1052 ;SetOutPath "$INSTDIR\Documentation\html\CmdRef"
1053 ;File "..\..\doc\install\Documentation\ko_KR\html\CmdRef\*"
1054 SetOutPath "$INSTDIR\Documentation\html\InstallGd"
1055 File "..\..\doc\install\Documentation\ko_KR\html\InstallGd\*"
1056 SetOutPath "$INSTDIR\Documentation\html\ReleaseNotes"
1057 File "..\..\doc\install\Documentation\ko_KR\html\ReleaseNotes\*"
1058 SetOutPath "$INSTDIR\Documentation\html\SysAdminGd"
1059 File "..\..\doc\install\Documentation\ko_KR\html\SysAdminGd\*"
1063 SetOutPath "$INSTDIR\Documentation"
1064 File "..\..\doc\install\Documentation\pt_BR\README.TXT"
1065 SetOutPath "$INSTDIR\Documentation\html"
1066 File "..\..\doc\install\Documentation\pt_BR\html\*"
1067 ;SetOutPath "$INSTDIR\Documentation\html\CmdRef"
1068 ;File "..\..\doc\install\Documentation\pt_BR\html\CmdRef\*"
1069 SetOutPath "$INSTDIR\Documentation\html\InstallGd"
1070 File "..\..\doc\install\Documentation\pt_BR\html\InstallGd\*"
1071 SetOutPath "$INSTDIR\Documentation\html\ReleaseNotes"
1072 File "..\..\doc\install\Documentation\pt_BR\html\ReleaseNotes\*"
1073 ;SetOutPath "$INSTDIR\Documentation\html\SysAdminGd"
1074 ;File "..\..\doc\install\Documentation\pt_BR\html\SysAdminGd\*"
1078 SetOutPath "$INSTDIR\Documentation"
1079 File "..\..\doc\install\Documentation\zh_CN\README.TXT"
1080 SetOutPath "$INSTDIR\Documentation\html"
1081 File "..\..\doc\install\Documentation\zh_CN\html\*"
1082 ;SetOutPath "$INSTDIR\Documentation\html\CmdRef"
1083 ;File "..\..\doc\install\Documentation\zh_CN\html\CmdRef\*"
1084 SetOutPath "$INSTDIR\Documentation\html\InstallGd"
1085 File "..\..\doc\install\Documentation\zh_CN\html\InstallGd\*"
1086 SetOutPath "$INSTDIR\Documentation\html\ReleaseNotes"
1087 File "..\..\doc\install\Documentation\zh_CN\html\ReleaseNotes\*"
1088 ;SetOutPath "$INSTDIR\Documentation\html\SysAdminGd"
1089 ;File "..\..\doc\install\Documentation\zh_CN\html\SysAdminGd\*"
1093 SetOutPath "$INSTDIR\Documentation"
1094 File "..\..\doc\install\Documentation\zh_TW\README.TXT"
1095 SetOutPath "$INSTDIR\Documentation\html"
1096 File "..\..\doc\install\Documentation\zh_TW\html\*"
1097 ;SetOutPath "$INSTDIR\Documentation\html\CmdRef"
1098 ;File "..\..\doc\install\Documentation\zh_TW\html\CmdRef\*"
1099 SetOutPath "$INSTDIR\Documentation\html\InstallGd"
1100 File "..\..\doc\install\Documentation\zh_TW\html\InstallGd\*"
1101 SetOutPath "$INSTDIR\Documentation\html\ReleaseNotes"
1102 File "..\..\doc\install\Documentation\zh_TW\html\ReleaseNotes\*"
1103 ;SetOutPath "$INSTDIR\Documentation\html\SysAdminGd"
1104 ;File "..\..\doc\install\Documentation\zh_TW\html\SysAdminGd\*"
1109 ;Store install folder
1110 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation" "" $INSTDIR
1111 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\CurrentVersion" "VersionString" ${AFS_VERSION}
1112 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\CurrentVersion" "MajorVersion" ${AFS_MAJORVERSION}
1113 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\CurrentVersion" "MinorVersion" ${AFS_MINORVERSION}
1114 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\CurrentVersion" "PatchLevel" ${AFS_PATCHLEVEL}
1115 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\${AFS_VERSION}" "VersionString" ${AFS_VERSION}
1116 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\${AFS_VERSION}" "MajorVersion" ${AFS_MAJORVERSION}
1117 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\${AFS_VERSION}" "MinorVersion" ${AFS_MINORVERSION}
1118 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\${AFS_VERSION}" "PatchLevel" ${AFS_PATCHLEVEL}
1120 ; Write start menu shortcut
1121 SetOutPath "$SMPROGRAMS\OpenAFS"
1122 CreateShortCut "$SMPROGRAMS\OpenAFS\Documentation.lnk" "$INSTDIR\Documentation\html\index.htm"
1125 WriteUninstaller "$INSTDIR\Uninstall.exe"
1126 CreateShortCut "$SMPROGRAMS\OpenAFS\Uninstall OpenAFS.lnk" "$INSTDIR\Uninstall.exe"
1127 Call AFSCommon.Install
1131 Section "Software Development Kit (SDK)" secSDK
1133 SetOutPath "$INSTDIR\Client\Program\lib"
1134 File /r "${AFS_CLIENT_LIBDIR}\*.*"
1136 SetOutPath "$INSTDIR\Client\Program\Include"
1137 File /r "${AFS_BUILD_INCDIR}\*.*"
1140 SetOutPath "$INSTDIR\Client\Program\Sample"
1141 File "..\..\afsd\sample\token.c"
1143 ;Store install folder
1144 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS SDK" "" $INSTDIR
1145 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS SDK\CurrentVersion" "VersionString" ${AFS_VERSION}
1146 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\CurrentVersion" "MajorVersion" ${AFS_MAJORVERSION}
1147 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\CurrentVersion" "MinorVersion" ${AFS_MINORVERSION}
1148 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\CurrentVersion" "PatchLevel" ${AFS_PATCHLEVEL}
1149 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS SDK\${AFS_VERSION}" "VersionString" ${AFS_VERSION}
1150 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\${AFS_VERSION}" "MajorVersion" ${AFS_MAJORVERSION}
1151 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\${AFS_VERSION}" "MinorVersion" ${AFS_MINORVERSION}
1152 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\${AFS_VERSION}" "PatchLevel" ${AFS_PATCHLEVEL}
1154 WriteUninstaller "$INSTDIR\Uninstall.exe"
1155 SetOutPath "$SMPROGRAMS\OpenAFS"
1156 CreateShortCut "$SMPROGRAMS\OpenAFS\Uninstall OpenAFS.lnk" "$INSTDIR\Uninstall.exe"
1158 Call AFSCommon.Install
1161 ;Display the Finish header
1162 ;Insert this macro after the sections if you are not using a finish page
1163 ;!insertmacro MUI_SECTIONS_FINISHHEADER
1165 ;--------------------------------
1166 ;Installer Functions
1170 !insertmacro MUI_LANGDLL_DISPLAY
1172 ; Set the default install options
1177 StrCmp $R0 "true" contInstall
1179 MessageBox MB_OK|MB_ICONSTOP|MB_TOPMOST "You must be an administrator of this machine to install this software."
1183 ; Our logic should be like this.
1184 ; 1) If no AFS components are installed, we do a clean install with default options. (Client/Docs)
1185 ; 2) If existing modules are installed, we keep them selected
1186 ; 3) If it is an upgrade, we set the text accordingly, else we mark it as a re-install
1188 Call IsAnyAFSInstalled
1190 StrCmp $R0 "0" DefaultOptions
1192 Call ShouldClientInstall
1195 ; Check if it was an IBM/Transarc version
1196 ReadRegStr $R0 HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon" "DisplayName"
1197 StrCmp $R0 "IBM AFS Client" DoIBM
1198 StrCmp $R0 "Transarc AFS Client" DoIBM
1201 StrCmp $R2 "0" NoClient
1202 StrCmp $R2 "1" ReinstallClient
1203 StrCmp $R2 "2" UpgradeClient
1204 StrCmp $R2 "3" DowngradeClient
1207 ReadRegDWORD $R0 HKLM "Software\TransarcCorporation\AFS Client\CurrentVersion" "MajorVersion"
1208 StrCmp $R0 "3" +1 NotIBM
1213 SectionGetFlags ${secClient} $0
1214 IntOp $0 $0 | ${SF_SELECTED}
1215 SectionSetFlags ${secClient} $0
1216 ;# !insertmacro SelectSection ${secClient}
1219 ;StrCpy $1 ${secClient} ; Gotta remember which section we are at now...
1220 SectionGetFlags ${secClient} $0
1221 IntOp $0 $0 & ${SECTION_OFF}
1222 SectionSetFlags ${secClient} $0
1225 SectionGetFlags ${secClient} $0
1226 IntOp $0 $0 | ${SF_SELECTED}
1227 SectionSetFlags ${secClient} $0
1228 SectionSetText ${secClient} $(UPGRADE_CLIENT)
1231 SectionGetFlags ${secClient} $0
1232 IntOp $0 $0 | ${SF_SELECTED}
1233 SectionSetFlags ${secClient} $0
1234 SectionSetText ${secClient} $(REINSTALL_CLIENT)
1237 SectionGetFlags ${secClient} $0
1238 IntOp $0 $0 | ${SF_SELECTED}
1239 SectionSetFlags ${secClient} $0
1240 SectionSetText ${secClient} $(REINSTALL_CLIENT)
1246 Call ShouldServerInstall
1248 StrCmp $R2 "0" NoServer
1249 StrCmp $R2 "1" ReinstallServer
1250 StrCmp $R2 "2" UpgradeServer
1251 StrCmp $R2 "3" DowngradeServer
1253 SectionGetFlags ${secServer} $0
1254 IntOp $0 $0 | ${SF_SELECTED}
1255 SectionSetFlags ${secServer} $0
1256 ;# !insertmacro UnselectSection ${secServer}
1260 SectionGetFlags ${secServer} $0
1261 IntOp $0 $0 | ${SF_SELECTED}
1262 SectionSetFlags ${secServer} $0
1263 SectionSetText ${secServer} $(UPGRADE_SERVER)
1267 SectionGetFlags ${secServer} $0
1268 IntOp $0 $0 | ${SF_SELECTED}
1269 SectionSetFlags ${secServer} $0
1270 SectionSetText ${secServer} $(REINSTALL_SERVER)
1274 SectionGetFlags ${secServer} $0
1275 IntOp $0 $0 | ${SF_SELECTED}
1276 SectionSetFlags ${secServer} $0
1277 SectionSetText ${secServer} $(REINSTALL_SERVER)
1281 SectionGetFlags ${secServer} $0
1282 IntOp $0 $0 & ${SECTION_OFF}
1283 SectionSetFlags ${secServer} $0
1284 ;# !insertmacro UnselectSection ${secServer}
1288 ; Check control center
1289 Call IsControlInstalled
1291 StrCmp $R2 "0" NoControl
1293 SectionGetFlags ${secControl} $0
1294 IntOp $0 $0 | ${SF_SELECTED}
1295 SectionSetFlags ${secControl} $0
1299 SectionGetFlags ${secControl} $0
1300 IntOp $0 $0 & ${SECTION_OFF}
1301 SectionSetFlags ${secControl} $0
1302 ;# !insertmacro UnselectSection ${secControl}
1305 ; Check Documentation
1306 Call IsDocumentationInstalled
1308 StrCmp $R2 "0" NoDocs
1309 SectionGetFlags ${secDocs} $0
1310 IntOp $0 $0 | ${SF_SELECTED}
1311 SectionSetFlags ${secDocs} $0
1315 SectionGetFlags ${secDocs} $0
1316 IntOp $0 $0 & ${SECTION_OFF}
1317 SectionSetFlags ${secDocs} $0
1320 ; To check the SDK, we simply look to see if the files exist. If they do,
1321 ; the SDK is installed. If not, we don't need to push it on the user.
1322 ; If they are there, we want to make sure they match the installed version.
1324 IfFileExists "$INSTDIR\Client\Program\Include\main.h" +1 NoSDK
1325 SectionGetFlags ${secSDK} $0
1326 IntOp $0 $0 | ${SF_SELECTED}
1327 SectionSetFlags ${secSDK} $0
1331 SectionGetFlags ${secSDK} $0
1332 IntOp $0 $0 & ${SECTION_OFF}
1333 SectionSetFlags ${secSDK} $0
1338 SectionGetFlags ${secClient} $0
1339 IntOp $0 $0 | ${SF_SELECTED}
1340 SectionSetFlags ${secClient} $0
1342 ; Server NOT selected
1343 SectionGetFlags ${secServer} $0
1344 IntOp $0 $0 & ${SECTION_OFF}
1345 SectionSetFlags ${secServer} $0
1347 ; Control Center NOT selected
1348 SectionGetFlags ${secControl} $0
1349 IntOp $0 $0 & ${SECTION_OFF}
1350 SectionSetFlags ${secControl} $0
1351 ;# !insertmacro UnselectSection ${secControl}
1353 ; Documentation selected
1354 SectionGetFlags ${secDocs} $0
1355 IntOp $0 $0 | ${SF_SELECTED}
1356 SectionSetFlags ${secDocs} $0
1357 ;# !insertmacro UnselectSection ${secDocs}
1360 SectionGetFlags ${secSDK} $0
1361 IntOp $0 $0 & ${SECTION_OFF}
1362 SectionSetFlags ${secSDK} $0
1363 ;# !insertmacro UnselectSection ${secSDK}
1372 ; See if we can set a default installation path...
1373 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "PathName"
1374 StrCmp $R0 "" TryServer
1378 ; Work around bug in 1.3.5000, 1.3.5100, 1.3.5200, 1.3.5201, 1.3.5299 installers...
1379 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "MajorVersion"
1380 StrCmp $R0 "1" +1 SkipParent
1381 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "MinorVersion"
1382 StrCmp $R0 "3" +1 SkipParent
1383 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "PatchLevel"
1384 StrCmp $R0 "5000" UpParent
1385 StrCmp $R0 "5100" UpParent
1386 StrCmp $R0 "5200" UpParent
1387 StrCmp $R0 "5201" UpParent
1388 StrCmp $R0 "5299" UpParent
1400 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "PathName"
1401 StrCmp $R0 "" TryControl
1409 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "PathName"
1417 File /oname=$0 CellServPage.ini
1419 File /oname=$1 AFSCell.ini
1420 ;File /oname=$1 ConfigURL.ini
1428 ;--------------------------------
1429 ; These are our cleanup functions
1430 Function .onInstFailed
1435 Function .onInstSuccess
1441 ;--------------------------------
1444 !insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
1445 !insertmacro MUI_DESCRIPTION_TEXT ${secServer} $(DESC_secServer)
1446 !insertmacro MUI_DESCRIPTION_TEXT ${secClient} $(DESC_secClient)
1447 !insertmacro MUI_DESCRIPTION_TEXT ${secControl} $(DESC_secControl)
1448 !insertmacro MUI_DESCRIPTION_TEXT ${secDocs} $(DESC_secDocs)
1449 !insertmacro MUI_DESCRIPTION_TEXT ${secSDK} $(DESC_secSDK)
1450 !insertmacro MUI_FUNCTION_DESCRIPTION_END
1452 ;--------------------------------
1453 ;Uninstaller Section
1456 ; Make sure the user REALLY wants to do this, unless they did a silent uninstall, in which case...let them!
1457 IfSilent StartRemove ; New in v2.0b4
1458 MessageBox MB_YESNO "Are you sure you want to remove OpenAFS from this machine?" IDYES StartRemove
1463 SetShellVarContext all
1464 ; Stop the running processes
1466 File /oname=$R0 "${AFS_WININSTALL_DIR}\Killer.exe"
1467 nsExec::Exec '$R0 afscreds.exe'
1468 Exec "afscreds.exe -z"
1469 ; in case we are upgrading an old version that does not support -z
1471 nsExec::Exec '$R0 afscreds.exe'
1473 nsExec::Exec '$R0 krbcc32s.exe'
1476 ; Delete the AFS service
1478 File /oname=$R0 "${AFS_WININSTALL_DIR}\Service.exe"
1479 nsExec::Exec "net stop TransarcAFSDaemon"
1480 nsExec::Exec "net stop TransarcAFSServer"
1481 nsExec::Exec '$R0 u TransarcAFSDaemon'
1482 ; After we stop the service, but before we delete it, we have to remove the volume data
1483 ; This is because the storage locations are in the registry under the service key.
1484 ; Call un.RemoveAFSVolumes
1485 nsExec::Exec '$R0 u TransarcAFSServer'
1488 Call un.RemoveProvider
1490 Push "$INSTDIR\Client\Program"
1491 Call un.RemoveFromPath
1492 Push "$INSTDIR\Common"
1493 Call un.RemoveFromPath
1495 Push "$INSTDIR\kfw\bin"
1496 Call un.RemoveFromPath
1499 ; Delete documentation
1500 Delete "$INSTDIR\Documentation\README.TXT"
1501 Delete "$INSTDIR\Documentation\html\*"
1502 Delete "$INSTDIR\Documentation\html\CmdRef\*"
1503 Delete "$INSTDIR\Documentation\html\InstallGd\*"
1504 Delete "$INSTDIR\Documentation\html\ReleaseNotes\*"
1505 Delete "$INSTDIR\Documentation\html\SysAdminGd\*"
1507 Delete /REBOOTOK "$INSTDIR\Common\afs_config.exe"
1508 Delete /REBOOTOK "$INSTDIR\Common\afs_shl_ext.dll"
1509 Delete /REBOOTOK "$INSTDIR\Common\afsadminutil.dll"
1510 Delete /REBOOTOK "$INSTDIR\Common\lib\afsauthent.dll"
1511 Delete /REBOOTOK "$INSTDIR\Common\lib\afspthread.dll"
1512 Delete /REBOOTOK "$INSTDIR\Common\lib\afsrpc.dll"
1513 Delete /REBOOTOK "$INSTDIR\Common\afsclientadmin.dll"
1514 Delete /REBOOTOK "$INSTDIR\Common\afsprocmgmt.dll"
1515 Delete /REBOOTOK "$INSTDIR\Common\afsvosadmin.dll"
1516 Delete /REBOOTOK "$INSTDIR\Common\TaAfsAppLib.dll"
1517 Delete /REBOOTOK "$INSTDIR\Common\afsvosadmin.dll"
1518 Delete /REBOOTOK "$INSTDIR\Common\afsbosadmin.dll"
1519 Delete /REBOOTOK "$INSTDIR\Common\afscfgadmin.dll"
1520 Delete /REBOOTOK "$INSTDIR\Common\afskasadmin.dll"
1521 Delete /REBOOTOK "$INSTDIR\Common\afsptsadmin.dll"
1524 Delete /REBOOTOK "$INSTDIR\Common\afs_config.pdb"
1525 Delete /REBOOTOK "$INSTDIR\Common\afs_shl_ext.pdb"
1526 Delete /REBOOTOK "$INSTDIR\Common\afsadminutil.pdb"
1527 Delete /REBOOTOK "$INSTDIR\Common\lib\afsauthent.pdb"
1528 Delete /REBOOTOK "$INSTDIR\Common\lib\afspthread.pdb"
1529 Delete /REBOOTOK "$INSTDIR\Common\lib\afsrpc.pdb"
1530 Delete /REBOOTOK "$INSTDIR\Common\afsclientadmin.pdb"
1531 Delete /REBOOTOK "$INSTDIR\Common\afsprocmgmt.pdb"
1532 Delete /REBOOTOK "$INSTDIR\Common\afsvosadmin.pdb"
1533 Delete /REBOOTOK "$INSTDIR\Common\TaAfsAppLib.pdb"
1534 Delete /REBOOTOK "$INSTDIR\Common\afsvosadmin.pdb"
1535 Delete /REBOOTOK "$INSTDIR\Common\afsbosadmin.pdb"
1536 Delete /REBOOTOK "$INSTDIR\Common\afscfgadmin.pdb"
1537 Delete /REBOOTOK "$INSTDIR\Common\afskasadmin.pdb"
1538 Delete /REBOOTOK "$INSTDIR\Common\afsptsadmin.pdb"
1541 Delete /REBOOTOK "$INSTDIR\bin\msvcr71d.dll"
1542 Delete /REBOOTOK "$INSTDIR\bin\msvcr71d.pdb"
1543 Delete /REBOOTOK "$INSTDIR\bin\msvcp71d.dll"
1544 Delete /REBOOTOK "$INSTDIR\bin\msvcp71d.pdb"
1545 Delete /REBOOTOK "$INSTDIR\bin\mfc71d.dll"
1546 Delete /REBOOTOK "$INSTDIR\bin\mfc71d.pdb"
1549 Delete /REBOOTOK "$INSTDIR\bin\msvcr70d.dll"
1550 Delete /REBOOTOK "$INSTDIR\bin\msvcr70d.pdb"
1551 Delete /REBOOTOK "$INSTDIR\bin\msvcp70d.dll"
1552 Delete /REBOOTOK "$INSTDIR\bin\msvcp70d.pdb"
1553 Delete /REBOOTOK "$INSTDIR\bin\mfc70d.dll"
1554 Delete /REBOOTOK "$INSTDIR\bin\mfc70d.pdb"
1556 Delete /REBOOTOK "$INSTDIR\bin\mfc42d.dll"
1557 Delete /REBOOTOK "$INSTDIR\bin\mfc42d.pdb"
1558 Delete /REBOOTOK "$INSTDIR\bin\msvcp60d.dll"
1559 Delete /REBOOTOK "$INSTDIR\bin\msvcp60d.pdb"
1560 Delete /REBOOTOK "$INSTDIR\bin\msvcrtd.dll"
1561 Delete /REBOOTOK "$INSTDIR\bin\msvcrtd.pdb"
1566 Delete /REBOOTOK "$INSTDIR\bin\mfc71.dll"
1567 Delete /REBOOTOK "$INSTDIR\bin\msvcr71.dll"
1568 Delete /REBOOTOK "$INSTDIR\bin\msvcp71.dll"
1569 Delete /REBOOTOK "$INSTDIR\bin\MFC71CHS.DLL"
1570 Delete /REBOOTOK "$INSTDIR\bin\MFC71CHT.DLL"
1571 Delete /REBOOTOK "$INSTDIR\bin\MFC71DEU.DLL"
1572 Delete /REBOOTOK "$INSTDIR\bin\MFC71ENU.DLL"
1573 Delete /REBOOTOK "$INSTDIR\bin\MFC71ESP.DLL"
1574 Delete /REBOOTOK "$INSTDIR\bin\MFC71FRA.DLL"
1575 Delete /REBOOTOK "$INSTDIR\bin\MFC71ITA.DLL"
1576 Delete /REBOOTOK "$INSTDIR\bin\MFC71JPN.DLL"
1577 Delete /REBOOTOK "$INSTDIR\bin\MFC71KOR.DLL"
1580 Delete /REBOOTOK "$INSTDIR\bin\mfc70.dll"
1581 Delete /REBOOTOK "$INSTDIR\bin\msvcr70.dll"
1582 Delete /REBOOTOK "$INSTDIR\bin\msvcp70.dll"
1583 Delete /REBOOTOK "$INSTDIR\bin\MFC70CHS.DLL"
1584 Delete /REBOOTOK "$INSTDIR\bin\MFC70CHT.DLL"
1585 Delete /REBOOTOK "$INSTDIR\bin\MFC70DEU.DLL"
1586 Delete /REBOOTOK "$INSTDIR\bin\MFC70ENU.DLL"
1587 Delete /REBOOTOK "$INSTDIR\bin\MFC70ESP.DLL"
1588 Delete /REBOOTOK "$INSTDIR\bin\MFC70FRA.DLL"
1589 Delete /REBOOTOK "$INSTDIR\bin\MFC70ITA.DLL"
1590 Delete /REBOOTOK "$INSTDIR\bin\MFC70JPN.DLL"
1591 Delete /REBOOTOK "$INSTDIR\bin\MFC70KOR.DLL"
1593 Delete /REBOOTOK "$INSTDIR\bin\mfc42.dll"
1594 Delete /REBOOTOK "$INSTDIR\bin\msvcp60.dll"
1595 Delete /REBOOTOK "$INSTDIR\bin\msvcrt.dll"
1601 ; IfFileExists "$WINDIR\afsdcell.ini" CellExists SkipDelAsk
1603 MessageBox MB_YESNO "Would you like to keep your configuration files?" IDYES SkipDel
1605 Delete "$WINDIR\afsdcell.ini"
1607 Delete "$WINDIR\afsdsbmt.ini"
1608 ; Only remove krb5.ini if KfW was installed
1610 Delete "$WINDIR\krb5.ini"
1612 Delete "$WINDIR\afsdns.ini"
1613 Delete "$WINDIR\afs_freelance.ini"
1616 Delete "$WINDIR\afsd_init.log"
1617 Delete "$INSTDIR\Uninstall.exe"
1620 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\afskill.exe"
1621 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\afssvrcfg.exe"
1622 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\bosctlsvc.exe"
1623 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\bosserver.exe"
1624 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\buserver.exe"
1625 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\butc.exe"
1626 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\fileserver.exe"
1627 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\fms.exe"
1628 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\kaserver.exe"
1629 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\ptserver.exe"
1630 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\salvager.exe"
1631 Delete "$INSTDIR\Server\usr\afs\bin\ServerUninst.dll"
1632 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\upclient.exe"
1633 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\upserver.exe"
1634 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\vlserver.exe"
1635 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\volinfo.exe"
1636 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\volserver.exe"
1639 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\afskill.pdb"
1640 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\afssvrcfg.pdb"
1641 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\bosctlsvc.pdb"
1642 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\bosserver.pdb"
1643 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\buserver.pdb"
1644 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\butc.pdb"
1645 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\fileserver.pdb"
1646 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\fms.pdb"
1647 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\kaserver.pdb"
1648 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\ptserver.pdb"
1649 Delete "$INSTDIR\Server\usr\afs\bin\salvager.pdb"
1650 Delete "$INSTDIR\Server\usr\afs\bin\ServerUninst.pdb"
1651 Delete "$INSTDIR\Server\usr\afs\bin\upclient.pdb"
1652 Delete "$INSTDIR\Server\usr\afs\bin\upserver.pdb"
1653 Delete "$INSTDIR\Server\usr\afs\bin\vlserver.pdb"
1654 Delete "$INSTDIR\Server\usr\afs\bin\volinfo.pdb"
1655 Delete "$INSTDIR\Server\usr\afs\bin\volserver.pdb"
1658 RMDir /r "$INSTDIR\Server\usr\afs\bin"
1659 ; do not delete the server configuration files
1660 ; or we will lose the volumes and authentication
1662 ;RmDir /r "$INSTDIR\Server\usr\afs\etc\logs"
1663 ;RmDir /r "$INSTDIR\Server\usr\afs\etc"
1664 ;RmDir /r "$INSTDIR\Server\usr\afs\local"
1665 ;RMDIR /r "$INSTDIR\Server\usr\afs\logs"
1667 Delete /REBOOTOK "$SYSDIR\afsserver.cpl"
1668 Delete /REBOOTOK "$SYSDIR\afs_cpa.cpl"
1671 Delete /REBOOTOK "$SYSDIR\afsserver.pdb"
1672 Delete /REBOOTOK "$SYSDIR\afs_cpa.pdb"
1675 RMDir /r "$INSTDIR\Documentation\html\CmdRef"
1676 RMDir /r "$INSTDIR\Documentation\html\InstallGd"
1677 RMDir /r "$INSTDIR\Documentation\html\ReleaseNotes"
1678 RMDir /r "$INSTDIR\Documentation\html\SysAdminGd"
1679 RMDIr /r "$INSTDIR\Documentation\html"
1681 RMDir "$INSTDIR\Documentation"
1682 ; Delete DOC short cut
1683 Delete /REBOOTOK "$INSTDIR\Client\Program\afscreds.exe"
1686 Delete /REBOOTOK "$INSTDIR\Client\Program\afscreds.pdb"
1689 Delete /REBOOTOK "$INSTDIR\Client\Program\*"
1690 Delete /REBOOTOK "$INSTDIR\Client\Program\Include\*"
1691 Delete /REBOOTOK "$INSTDIR\Client\Program\Include\afs\*"
1692 Delete /REBOOTOK "$INSTDIR\Client\Program\Include\rx\*"
1693 Delete /REBOOTOK "$INSTDIR\Client\Program\Sample\*"
1694 RMDir "$INSTDIR\Client\Program\Sample"
1695 RMDir "$INSTDIR\Client\Program\Include\afs"
1696 RMDir "$INSTDIR\Client\Program\Include\rx"
1697 RMDir "$INSTDIR\Client\Program\Include"
1698 RMDir "$INSTDIR\Client\Program"
1699 RMDir "$INSTDIR\Client"
1703 Delete /REBOOTOK "$INSTDIR\bin\msvcr71d.dll"
1704 Delete /REBOOTOK "$INSTDIR\bin\msvcr71d.pdb"
1705 Delete /REBOOTOK "$INSTDIR\bin\msvcp71d.dll"
1706 Delete /REBOOTOK "$INSTDIR\bin\msvcp71d.pdb"
1707 Delete /REBOOTOK "$INSTDIR\bin\mfc71d.dll"
1708 Delete /REBOOTOK "$INSTDIR\bin\mfc71d.pdb"
1711 Delete /REBOOTOK "$INSTDIR\bin\msvcr70d.dll"
1712 Delete /REBOOTOK "$INSTDIR\bin\msvcr70d.pdb"
1713 Delete /REBOOTOK "$INSTDIR\bin\msvcp70d.dll"
1714 Delete /REBOOTOK "$INSTDIR\bin\msvcp70d.pdb"
1715 Delete /REBOOTOK "$INSTDIR\bin\mfc70d.dll"
1716 Delete /REBOOTOK "$INSTDIR\bin\mfc70d.pdb"
1718 Delete /REBOOTOK "$INSTDIR\bin\mfc42d.dll"
1719 Delete /REBOOTOK "$INSTDIR\bin\mfc42d.pdb"
1720 Delete /REBOOTOK "$INSTDIR\bin\msvcp60d.dll"
1721 Delete /REBOOTOK "$INSTDIR\bin\msvcp60d.pdb"
1722 Delete /REBOOTOK "$INSTDIR\bin\msvcrtd.dll"
1723 Delete /REBOOTOK "$INSTDIR\bin\msvcrtd.pdb"
1728 Delete /REBOOTOK "$INSTDIR\bin\mfc71.dll"
1729 Delete /REBOOTOK "$INSTDIR\bin\msvcr71.dll"
1730 Delete /REBOOTOK "$INSTDIR\bin\msvcp71.dll"
1731 Delete /REBOOTOK "$INSTDIR\bin\MFC71CHS.DLL"
1732 Delete /REBOOTOK "$INSTDIR\bin\MFC71CHT.DLL"
1733 Delete /REBOOTOK "$INSTDIR\bin\MFC71DEU.DLL"
1734 Delete /REBOOTOK "$INSTDIR\bin\MFC71ENU.DLL"
1735 Delete /REBOOTOK "$INSTDIR\bin\MFC71ESP.DLL"
1736 Delete /REBOOTOK "$INSTDIR\bin\MFC71FRA.DLL"
1737 Delete /REBOOTOK "$INSTDIR\bin\MFC71ITA.DLL"
1738 Delete /REBOOTOK "$INSTDIR\bin\MFC71JPN.DLL"
1739 Delete /REBOOTOK "$INSTDIR\bin\MFC71KOR.DLL"
1742 Delete /REBOOTOK "$INSTDIR\bin\mfc70.dll"
1743 Delete /REBOOTOK "$INSTDIR\bin\msvcr70.dll"
1744 Delete /REBOOTOK "$INSTDIR\bin\msvcp70.dll"
1745 Delete /REBOOTOK "$INSTDIR\bin\MFC70CHS.DLL"
1746 Delete /REBOOTOK "$INSTDIR\bin\MFC70CHT.DLL"
1747 Delete /REBOOTOK "$INSTDIR\bin\MFC70DEU.DLL"
1748 Delete /REBOOTOK "$INSTDIR\bin\MFC70ENU.DLL"
1749 Delete /REBOOTOK "$INSTDIR\bin\MFC70ESP.DLL"
1750 Delete /REBOOTOK "$INSTDIR\bin\MFC70FRA.DLL"
1751 Delete /REBOOTOK "$INSTDIR\bin\MFC70ITA.DLL"
1752 Delete /REBOOTOK "$INSTDIR\bin\MFC70JPN.DLL"
1753 Delete /REBOOTOK "$INSTDIR\bin\MFC70KOR.DLL"
1755 Delete /REBOOTOK "$INSTDIR\bin\mfc42.dll"
1756 Delete /REBOOTOK "$INSTDIR\bin\msvcp60.dll"
1757 Delete /REBOOTOK "$INSTDIR\bin\msvcrt.dll"
1762 Delete /REBOOTOK "$INSTDIR\Common\*"
1763 RMDir "$INSTDIR\Common"
1767 Delete /REBOOTOK "$INSTDIR\kfw\bin\*"
1768 RMDIR /r "$INSTDIR\kfw\bin"
1769 Delete /REBOOTOK "$INSTDIR\kfw\doc\*"
1770 RMDIR /r "$INSTDIR\kfw\doc"
1771 RMDIR /r "$INSTDIR\kfw"
1774 Delete "$SMPROGRAMS\OpenAFS\Documentation.lnk"
1776 ; Remove control center
1777 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsAccountManager.exe"
1778 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsAdmSvr.exe"
1779 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsServerManager.exe"
1780 Delete /REBOOTOK "$INSTDIR\Control Center\CCUninst.dll"
1782 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsAccountManager.pdb"
1783 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsAdmSvr.pdb"
1784 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsServerManager.pdb"
1786 RMDir "$INSTDIR\Control Center"
1788 Delete "$SMPROGRAMS\OpenAFS\Uninstall OpenAFS.lnk"
1789 Delete "$SMPROGRAMS\OpenAFS\Client\Authentication.lnk"
1790 Delete "$SMPROGRAMS\OpenAFS\Control Center\Account Manager.lnk"
1791 Delete "$SMPROGRAMS\OpenAFS\Control Center\Server Manager.lnk"
1792 RMDIR "$SMPROGRAMS\OpenAFS\Control Center"
1793 RMDir /r "$SMPROGRAMS\OpenAFS\Client"
1794 RMDir /r "$SMPROGRAMS\OpenAFS"
1795 Delete "$SMSTARTUP\AFS Credentials.lnk"
1797 ReadRegStr $R0 HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon" "CachePath"
1799 Delete "$R0\AFSCache"
1800 Delete "C:\AFSCache"
1802 DeleteRegKey HKCR "*\shellex\ContextMenuHandlers\AFS Client Shell Extension"
1803 DeleteRegKey HKCR "CLSID\{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}\InprocServer32"
1804 DeleteRegKey HKCR "CLSID\{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}"
1805 DeleteRegKey HKCR "FOLDER\shellex\ContextMenuHandlers\AFS Client Shell Extension"
1806 DeleteRegValue HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Shell Extensions\Approved" "{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}"
1808 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion"
1809 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Client"
1810 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\CurrentVersion"
1811 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation"
1812 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion"
1813 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Control Center"
1814 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion"
1815 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Server"
1816 DeleteRegKey /ifempty HKLM "${AFS_REGKEY_ROOT}"
1817 DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS"
1818 DeleteRegValue HKLM "SYSTEM\CurrentControlSet\Services\NetBT\Parameters" "SmbDeviceEnabled"
1824 ;--------------------------------
1825 ;Uninstaller Functions
1829 ;Get language from registry
1830 ReadRegStr $LANGUAGE HKCU "Software\OpenAFS\AFS" "Installer Language"
1834 Function un.onUninstSuccess
1836 MessageBox MB_OK "Please reboot your machine to complete uninstallation of the software"
1840 ;------------------------------
1841 ; Get the CellServDB file from the Internet
1843 Function afs.GetCellServDB
1845 ;Check if we should download CellServDB
1846 ReadINIStr $R0 $0 "Field 4" "State"
1847 StrCmp $R0 "1" DoDownload
1849 ;Do nothing if we're keeping the existing file
1850 ReadINIStr $R0 $0 "Field 2" "State"
1853 ReadINIStr $R0 $0 "Field 6" "State"
1854 StrCmp $R0 "1" CheckOther
1856 ReadINIStr $R0 $0 "Field 3" "State"
1857 StrCmp $R0 "1" UsePackaged
1859 ; If none of these, grab file from other location
1863 ReadINIStr $R0 $0 "Field 5" "State"
1864 NSISdl::download $R0 "$WINDIR\afsdcell.ini"
1865 Pop $R0 ;Get the return value
1866 StrCmp $R0 "success" +2
1867 MessageBox MB_OK|MB_ICONSTOP "Download failed: $R0"
1871 SetOutPath "$WINDIR"
1876 ReadINIStr $R0 $0 "Field 7" "State"
1878 CopyFiles $R0 "$WINDIR\afsdcell.ini"
1884 Function AddProvider
1887 ReadRegStr $R0 HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\HWOrder" "ProviderOrder"
1889 StrCpy $R0 "TransarcAFSDaemon"
1893 StrCmp $R0 "" +1 DoOther
1894 ReadRegStr $R1 HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\HWOrder" "ProviderOrder"
1895 StrCpy $R0 "$R1,TransarcAFSDaemon"
1896 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\HWOrder" "ProviderOrder" $R0
1898 ReadRegStr $R0 HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\Order" "ProviderOrder"
1900 StrCpy $R0 "TransarcAFSDaemon"
1904 StrCmp $R0 "" +1 End
1905 ReadRegStr $R1 HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\Order" "ProviderOrder"
1906 StrCpy $R0 "$R1,TransarcAFSDaemon"
1907 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\Order" "ProviderOrder" $R0
1913 Function un.RemoveProvider
1915 StrCpy $R0 "TransarcAFSDaemon"
1917 StrCpy $R0 "SYSTEM\CurrentControlSet\Control\NetworkProvider\HWOrder"
1918 Call un.RemoveFromProvider
1919 StrCpy $R0 "TransarcAFSDaemon"
1921 StrCpy $R0 "SYSTEM\CurrentControlSet\Control\NetworkProvider\Order"
1922 Call un.RemoveFromProvider
1926 Function un.RemoveFromProvider
1935 ReadRegStr $1 HKLM "$R0" "ProviderOrder"
1936 StrCpy $5 $1 1 -1 # copy last char
1937 StrCmp $5 "," +2 # if last char != ,
1938 StrCpy $1 "$1," # append ,
1941 Call un.StrStr ; Find `$0,` in $1
1942 Pop $2 ; pos of our dir
1943 StrCmp $2 "" unRemoveFromPath_done
1944 ; else, it is in path
1949 StrCpy $5 $1 -$4 # $5 is now the part before the path to remove
1950 StrCpy $6 $2 "" $3 # $6 is now the part after the path to remove
1953 StrCpy $5 $3 1 -1 # copy last char
1954 StrCmp $5 "," 0 +2 # if last char == ,
1955 StrCpy $3 $3 -1 # remove last char
1957 WriteRegStr HKLM "$R0" "ProviderOrder" $3
1959 unRemoveFromPath_done:
1969 Function CheckPathForAFS
1974 ReadRegStr $1 HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "PATH"
1983 IfFileExists "$3\afsd_service.exe" Error
1984 StrCpy $1 $0 32768 1
1986 IntCmp $2 0 Done Done loop
1989 MessageBox MB_ICONSTOP|MB_OK|MB_TOPMOST "This installer is unable to upgrade the previous version of AFS. Please uninstall the current AFS version before continuing."
1990 Abort "Unable to install OpenAFS"
1998 Function AddToUniquePath
2002 ReadRegStr $R0 HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "PATH"
2006 StrCmp $R0 "" +1 Done
2012 ;-------------------------------
2013 ;Do the page to get the CellServDB
2015 Function AFSPageGetCellServDB
2016 ; Skip this page if we are not installing the client
2017 SectionGetFlags ${secClient} $R0
2018 IntOp $R0 $R0 & ${SF_SELECTED}
2021 ; Set the install options here
2024 WriteINIStr $0 "Field 2" "Flags" "DISABLED"
2025 WriteINIStr $0 "Field 3" "State" "1"
2026 WriteINISTR $0 "Field 4" "State" "0"
2027 WriteINIStr $0 "Field 6" "State" "0"
2029 ; If there is an existing afsdcell.ini file, allow the user to choose it and make it default
2030 IfFileExists "$WINDIR\afsdcell.ini" +1 notpresent
2031 WriteINIStr $0 "Field 2" "Flags" "ENABLED"
2032 WriteINIStr $0 "Field 2" "State" "1"
2033 WriteINIStr $0 "Field 3" "State" "0"
2037 !insertmacro MUI_HEADER_TEXT "CellServDB Configuration" "Please choose a method for installing the CellServDB file:"
2038 InstallOptions::dialog $0
2040 StrCmp $R1 "cancel" exit
2041 StrCmp $R1 "back" done
2042 StrCmp $R1 "success" done
2046 ; Check that if a file is set, a valid filename is entered...
2047 ReadINIStr $R0 $0 "Field 6" "State"
2048 StrCmp $R0 "1" CheckFileName
2050 ;Check if a URL is specified, one *IS* specified
2051 ReadINIStr $R0 $0 "Field 4" "State"
2052 StrCmp $R0 "1" CheckURL Skip
2055 ReadINIStr $R0 $0 "Field 5" "State"
2056 StrCmp $R0 "" +1 Skip
2057 MessageBox MB_OK|MB_ICONSTOP $(URLError)
2058 WriteINIStr $0 "Field 4" "State" "0"
2062 ReadINIStr $R0 $0 "Field 7" "State"
2063 IfFileExists $R0 Skip
2065 MessageBox MB_OK|MB_ICONSTOP $(CellError)
2066 WriteINIStr $0 "Field 6" "State" "0"
2074 Function AFSPageGetCellName
2076 ; Skip this page if we are not installing the client
2077 SectionGetFlags ${secClient} $R0
2078 IntOp $R0 $R0 & ${SF_SELECTED}
2082 ; If this is a server install, we do NOT want to recommend the Freelance client
2083 ; And we do not need to ask for the cell name.
2084 SectionGetFlags ${secServer} $R1
2085 IntOp $R1 $R1 & ${SF_SELECTED}
2086 StrCmp $R1 "1" +1 NotServer
2087 WriteINIStr $1 "Field 6" "Text" "Enable AFS Freelance client (Not Recommended for servers)"
2088 WriteINIStr $1 "Field 5" "State" "0"
2089 WriteINIStr $1 "Field 1" "Flags" "DISABLED"
2090 WriteINIStr $1 "Field 2" "Flags" "DISABLED"
2093 WriteINIStr $1 "Field 6" "Text" "Enable AFS Freelance client (Recommended)"
2094 WriteINIStr $1 "Field 5" "State" "1"
2095 WriteINIStr $1 "Field 1" "Flags" ""
2096 WriteINIStr $1 "Field 2" "Flags" ""
2098 ; Get the current cell name, if any
2099 ReadRegStr $R1 HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "Cell"
2101 WriteINIStr $1 "Field 2" "State" $R1
2102 !insertmacro MUI_HEADER_TEXT "Client Cell Name Configuration" "Please enter the name for your default cell:"
2103 InstallOptions::dialog $1
2105 StrCmp $R1 "cancel" exit
2106 StrCmp $R1 "back" done
2107 StrCmp $R1 "success" done
2110 ReadINIStr $R0 $1 "Field 2" "State"
2111 StrCmp $R0 "" +1 good
2113 MessageBox MB_OK|MB_ICONSTOP $(CellNameError)
2119 ; Common install routines for each module
2120 Function AFSCommon.Install
2122 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "DisplayName" "OpenAFS for Windows"
2123 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "UninstallString" "$INSTDIR\uninstall.exe"
2125 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "DisplayVersion" "${AFS_VERSION}"
2127 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "DisplayVersion" "${AFS_VERSION} Checked/Debug"
2129 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "URLInfoAbout" "http://www.openafs.org/"
2134 ;-------------------
2135 ; Get the currently installed version and place it on the stack
2137 Function GetInstalledVersion
2142 ReadRegStr $R0 HKLM "Software\TransarcCorporation\$R2\CurrentVersion" "VersionString"
2143 StrCmp $R0 "" NotTransarc done
2147 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\$R2\CurrentVersion" "VersionString"
2156 ; Functions to get each component of the version number
2157 Function GetInstalledVersionMajor
2162 ReadRegDWORD $R0 HKLM "Software\TransarcCorporation\$R2\CurrentVersion" "MajorVersion"
2163 StrCmp $R0 "" NotTransarc done
2167 ReadRegDWORD $R0 HKLM "${AFS_REGKEY_ROOT}\$R2\CurrentVersion" "MajorVersion"
2176 Function GetInstalledVersionMinor
2181 ReadRegDWORD $R0 HKLM "Software\TransarcCorporation\$R2\CurrentVersion" "MinorVersion"
2182 StrCmp $R0 "" NotTransarc done
2186 ReadRegDWORD $R0 HKLM "${AFS_REGKEY_ROOT}\$R2\CurrentVersion" "MinorVersion"
2195 Function GetInstalledVersionPatch
2200 ReadRegDWORD $R0 HKLM "Software\TransarcCorporation\$R2\CurrentVersion" "PatchLevel"
2201 StrCmp $R0 "" NotTransarc done
2205 ReadRegDWORD $R0 HKLM "${AFS_REGKEY_ROOT}\$R2\CurrentVersion" "PatchLevel"
2216 ;-------------------------------
2217 ; Check if the client should be checked for default install
2218 Function ShouldClientInstall
2220 StrCpy $R2 "AFS Client"
2221 Call GetInstalledVersion
2224 StrCmp $R0 "" NotInstalled
2225 ; Now we see if it's an older or newer version
2227 Call GetInstalledVersionMajor
2229 IntCmpU $R0 ${AFS_MAJORVERSION} +1 Upgrade Downgrade
2231 Call GetInstalledVersionMinor
2233 IntCmpU $R0 ${AFS_MINORVERSION} +1 Upgrade Downgrade
2235 Call GetInstalledVersionPatch
2237 IntCmpU $R0 ${AFS_PATCHLEVEL} Reinstall Upgrade Downgrade
2260 ;-------------------------------
2261 ; Check how the server options should be set
2262 Function ShouldServerInstall
2264 StrCpy $R2 "AFS Server"
2265 Call GetInstalledVersion
2268 StrCmp $R0 "" NotInstalled
2269 ; Now we see if it's an older or newer version
2271 Call GetInstalledVersionMajor
2273 IntCmpU $R0 ${AFS_MAJORVERSION} +1 Upgrade Downgrade
2275 Call GetInstalledVersionMinor
2277 IntCmpU $R0 ${AFS_MINORVERSION} +1 Upgrade Downgrade
2279 Call GetInstalledVersionPatch
2281 IntCmpU $R0 ${AFS_PATCHLEVEL} Reinstall Upgrade Downgrade
2306 ; See if AFS Server is installed
2307 ; Returns: "1" if it is, 0 if it is not (on the stack)
2308 Function IsServerInstalled
2310 StrCpy $R2 "AFS Server"
2311 Call GetInstalledVersion
2314 StrCmp $R0 "" NotInstalled
2327 ; See if AFS Client is installed
2328 ; Returns: "1" if it is, 0 if it is not (on the stack)
2329 Function IsClientInstalled
2331 StrCpy $R2 "AFS Client"
2332 Call GetInstalledVersion
2335 StrCmp $R0 "" NotInstalled
2349 ; See if AFS Documentation is installed
2350 ; Returns: "1" if it is, 0 if it is not (on the stack)
2351 Function IsDocumentationInstalled
2353 StrCpy $R2 "AFS Supplemental Documentation"
2354 Call GetInstalledVersion
2357 StrCmp $R0 "" NotInstalled
2370 ; See if Control Center is installed
2371 ; Returns: "1" if it is, 0 if it is not (on the stack)
2372 Function IsControlInstalled
2374 StrCpy $R2 "AFS Control Center"
2375 Call GetInstalledVersion
2378 StrCmp $R0 "" NotInstalled
2393 ; output, top of stack (replaces, with e.g. whatever)
2394 ; modifies no other variables.
2396 Function GetParameters
2400 StrCpy $R0 $CMDLINE 1
2404 StrCpy $R1 ' ' ; we're scanning for a space instead of a quote
2406 StrCpy $R0 $CMDLINE 1 $R2
2407 StrCmp $R0 $R1 loop2
2413 StrCpy $R0 $CMDLINE 1 $R2
2414 StrCmp $R0 " " loop2
2415 StrCpy $R0 $CMDLINE "" $R2
2422 ;Check to see if any AFS component is installed
2423 ;Returns: Value on stack: "1" if it is, "0" if it is not
2424 Function IsAnyAFSInstalled
2429 Call IsClientInstalled
2431 Call IsServerInstalled
2433 Call IsControlInstalled
2435 Call IsDocumentationInstalled
2437 ; Now we must see if ANY of the $Rn values are 1
2438 StrCmp $R0 "1" SomethingInstalled
2439 StrCmp $R1 "1" SomethingInstalled
2440 StrCmp $R2 "1" SomethingInstalled
2441 StrCmp $R3 "1" SomethingInstalled
2455 ;Install English Language Files
2456 Function AFSLangFiles
2458 SetOutPath "$INSTDIR\Common"
2459 File "${AFS_CLIENT_BUILDDIR}\afs_config.exe"
2460 File "${AFS_SERVER_BUILDDIR}\afsadminutil.dll"
2461 !insertmacro ReplaceDLL "${AFS_DESTDIR}\lib\afsauthent.dll" "$INSTDIR\Common\afsauthent.dll" "$INSTDIR"
2462 !insertmacro ReplaceDLL "${AFS_DESTDIR}\lib\afspthread.dll" "$INSTDIR\Common\afspthread.dll" "$INSTDIR"
2463 !insertmacro ReplaceDLL "${AFS_DESTDIR}\lib\afsrpc.dll" "$INSTDIR\Common\afsrpc.dll" "$INSTDIR"
2464 File "${AFS_SERVER_BUILDDIR}\afsclientadmin.dll"
2465 File "${AFS_SERVER_BUILDDIR}\afsprocmgmt.dll"
2466 File "${AFS_SERVER_BUILDDIR}\afsvosadmin.dll"
2467 File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib.dll"
2468 File "${AFS_SERVER_BUILDDIR}\afsvosadmin.dll"
2469 File "${AFS_SERVER_BUILDDIR}\afsbosadmin.dll"
2470 File "${AFS_SERVER_BUILDDIR}\afscfgadmin.dll"
2471 File "${AFS_SERVER_BUILDDIR}\afskasadmin.dll"
2472 File "${AFS_SERVER_BUILDDIR}\afsptsadmin.dll"
2476 File "${SYSTEMDIR}\msvcr71d.dll"
2477 File "${SYSTEMDIR}\msvcr71d.pdb"
2478 File "${SYSTEMDIR}\msvcp71d.dll"
2479 File "${SYSTEMDIR}\msvcp71d.pdb"
2480 File "${SYSTEMDIR}\mfc71d.dll"
2481 File "${SYSTEMDIR}\mfc71d.pdb"
2482 File "${SYSTEMDIR}\MFC71CHS.DLL"
2483 File "${SYSTEMDIR}\MFC71CHT.DLL"
2484 File "${SYSTEMDIR}\MFC71DEU.DLL"
2485 File "${SYSTEMDIR}\MFC71ENU.DLL"
2486 File "${SYSTEMDIR}\MFC71ESP.DLL"
2487 File "${SYSTEMDIR}\MFC71FRA.DLL"
2488 File "${SYSTEMDIR}\MFC71ITA.DLL"
2489 File "${SYSTEMDIR}\MFC71JPN.DLL"
2490 File "${SYSTEMDIR}\MFC71KOR.DLL"
2493 File "${SYSTEMDIR}\msvcr70d.dll"
2494 File "${SYSTEMDIR}\msvcr70d.pdb"
2495 File "${SYSTEMDIR}\msvcp70d.dll"
2496 File "${SYSTEMDIR}\msvcp70d.pdb"
2497 File "${SYSTEMDIR}\mfc70d.dll"
2498 File "${SYSTEMDIR}\mfc70d.pdb"
2499 File "${SYSTEMDIR}\MFC70CHS.DLL"
2500 File "${SYSTEMDIR}\MFC70CHT.DLL"
2501 File "${SYSTEMDIR}\MFC70DEU.DLL"
2502 File "${SYSTEMDIR}\MFC70ENU.DLL"
2503 File "${SYSTEMDIR}\MFC70ESP.DLL"
2504 File "${SYSTEMDIR}\MFC70FRA.DLL"
2505 File "${SYSTEMDIR}\MFC70ITA.DLL"
2506 File "${SYSTEMDIR}\MFC70JPN.DLL"
2507 File "${SYSTEMDIR}\MFC70KOR.DLL"
2509 File "${SYSTEMDIR}\mfc42d.dll"
2510 File "${SYSTEMDIR}\mfc42d.pdb"
2511 File "${SYSTEMDIR}\msvcp60d.dll"
2512 File "${SYSTEMDIR}\msvcp60d.pdb"
2513 File "${SYSTEMDIR}\msvcrtd.dll"
2514 File "${SYSTEMDIR}\msvcrtd.pdb"
2519 File "${SYSTEMDIR}\mfc71.dll"
2520 File "${SYSTEMDIR}\msvcr71.dll"
2521 File "${SYSTEMDIR}\msvcp71.dll"
2522 File "${SYSTEMDIR}\MFC71CHS.DLL"
2523 File "${SYSTEMDIR}\MFC71CHT.DLL"
2524 File "${SYSTEMDIR}\MFC71DEU.DLL"
2525 File "${SYSTEMDIR}\MFC71ENU.DLL"
2526 File "${SYSTEMDIR}\MFC71ESP.DLL"
2527 File "${SYSTEMDIR}\MFC71FRA.DLL"
2528 File "${SYSTEMDIR}\MFC71ITA.DLL"
2529 File "${SYSTEMDIR}\MFC71JPN.DLL"
2530 File "${SYSTEMDIR}\MFC71KOR.DLL"
2533 File "${SYSTEMDIR}\mfc70.dll"
2534 File "${SYSTEMDIR}\msvcr70.dll"
2535 File "${SYSTEMDIR}\msvcp70.dll"
2536 File "${SYSTEMDIR}\MFC70CHS.DLL"
2537 File "${SYSTEMDIR}\MFC70CHT.DLL"
2538 File "${SYSTEMDIR}\MFC70DEU.DLL"
2539 File "${SYSTEMDIR}\MFC70ENU.DLL"
2540 File "${SYSTEMDIR}\MFC70ESP.DLL"
2541 File "${SYSTEMDIR}\MFC70FRA.DLL"
2542 File "${SYSTEMDIR}\MFC70ITA.DLL"
2543 File "${SYSTEMDIR}\MFC70JPN.DLL"
2544 File "${SYSTEMDIR}\MFC70KOR.DLL"
2546 File "${SYSTEMDIR}\mfc42.dll"
2547 File "${SYSTEMDIR}\msvcp60.dll"
2548 File "${SYSTEMDIR}\msvcrt.dll"
2554 File "${AFS_CLIENT_BUILDDIR}\afs_config.pdb"
2555 File "${AFS_SERVER_BUILDDIR}\afsadminutil.pdb"
2556 File "${AFS_DESTDIR}\lib\afsauthent.pdb"
2557 File "${AFS_DESTDIR}\lib\afspthread.pdb"
2558 File "${AFS_DESTDIR}\lib\afsrpc.pdb"
2559 File "${AFS_SERVER_BUILDDIR}\afsclientadmin.pdb"
2560 File "${AFS_SERVER_BUILDDIR}\afsprocmgmt.pdb"
2561 File "${AFS_SERVER_BUILDDIR}\afsvosadmin.pdb"
2562 File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib.pdb"
2563 File "${AFS_SERVER_BUILDDIR}\afsvosadmin.pdb"
2564 File "${AFS_SERVER_BUILDDIR}\afsbosadmin.pdb"
2565 File "${AFS_SERVER_BUILDDIR}\afscfgadmin.pdb"
2566 File "${AFS_SERVER_BUILDDIR}\afskasadmin.pdb"
2567 File "${AFS_SERVER_BUILDDIR}\afsptsadmin.pdb"
2570 StrCmp $LANGUAGE ${LANG_ENGLISH} DoEnglish
2571 StrCmp $LANGUAGE ${LANG_GERMAN} DoGerman
2572 StrCmp $LANGUAGE ${LANG_SPANISH} DoSpanish
2573 StrCmp $LANGUAGE ${LANG_JAPANESE} DoJapanese
2574 StrCmp $LANGUAGE ${LANG_KOREAN} DoKorean
2575 StrCmp $LANGUAGE ${LANG_PORTUGUESEBR} DoPortugueseBR
2576 StrCmp $LANGUAGE ${LANG_SIMPCHINESE} DoSimpChinese
2577 StrCmp $LANGUAGE ${LANG_TRADCHINESE} DoTradChinese
2581 SetOutPath "$INSTDIR\Documentation"
2582 File "..\..\doc\install\Documentation\en_US\README.TXT"
2584 SetOutPath "$INSTDIR\Client\Program"
2585 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afscreds_1033.dll" "$INSTDIR\Client\Program\afscreds_1033.dll" "$INSTDIR"
2586 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1033.dll" "$INSTDIR\Client\Program\afs_shl_ext_1033.dll" "$INSTDIR"
2588 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1033.pdb"
2589 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1033.pdb"
2592 SetOutPath "$INSTDIR\Common"
2593 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_config_1033.dll" "$INSTDIR\Common\afs_config_1033.dll" "$INSTDIR"
2594 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa_1033.dll" "$INSTDIR\Common\afs_cpa_1033.dll" "$INSTDIR"
2595 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afseventmsg_1033.dll" "$INSTDIR\Common\afseventmsg_1033.dll" "$INSTDIR"
2596 ;!insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1033.dll" "$INSTDIR\Common\afs_setup_utils_1033.dll" "$INSTDIR"
2597 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver_1033.dll" "$INSTDIR\Common\afsserver_1033.dll" "$INSTDIR"
2598 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afssvrcfg_1033.dll" "$INSTDIR\Common\afssvrcfg_1033.dll" "$INSTDIR"
2599 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1033.dll" "$INSTDIR\Common\TaAfsAccountManager_1033.dll" "$INSTDIR"
2600 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1033.dll" "$INSTDIR\Common\TaAfsApplLib_1033.dll" "$INSTDIR"
2601 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1033.dll" "$INSTDIR\Common\TaAfsServerManager_1033.dll" "$INSTDIR"
2602 File "..\..\doc\help\en_US\afs-cc.CNT"
2603 File "..\..\doc\help\en_US\afs-cc.hlp"
2604 File "..\..\doc\help\en_US\afs-light.CNT"
2605 File "..\..\doc\help\en_US\afs-light.hlp"
2606 File "..\..\doc\help\en_US\afs-nt.CNT"
2607 File "..\..\doc\help\en_US\afs-nt.HLP"
2608 File "..\..\doc\help\en_US\taafscfg.CNT"
2609 File "..\..\doc\help\en_US\taafscfg.hlp"
2610 File "..\..\doc\help\en_US\taafssvrmgr.CNT"
2611 File "..\..\doc\help\en_US\taafssvrmgr.hlp"
2612 File "..\..\doc\help\en_US\taafsusrmgr.CNT"
2613 File "..\..\doc\help\en_US\taafsusrmgr.hlp"
2616 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1033.pdb"
2617 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1033.pdb"
2618 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1033.pdb"
2619 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1033.pdb"
2620 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1033.pdb"
2621 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1033.pdb"
2622 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1033.pdb"
2623 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1033.pdb"
2629 SetOutPath "$INSTDIR\Documentation"
2630 File "..\..\doc\install\Documentation\de_DE\README.TXT"
2632 SetOutPath "$INSTDIR\Client\Program"
2633 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afscreds_1032.dll" "$INSTDIR\Client\Program\afscreds_1032.dll" "$INSTDIR"
2634 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1032.dll" "$INSTDIR\Client\Program\afs_shl_ext_1032.dll" "$INSTDIR"
2636 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1032.pdb"
2637 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1032.pdb"
2640 SetOutPath "$INSTDIR\Common"
2641 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_config_1032.dll" "$INSTDIR\Common\afs_config_1032.dll" "$INSTDIR"
2642 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa_1032.dll" "$INSTDIR\Common\afs_cpa_1032.dll" "$INSTDIR"
2643 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afseventmsg_1032.dll" "$INSTDIR\Common\afseventmsg_1032.dll" "$INSTDIR"
2644 ;!insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1032.dll" "$INSTDIR\Common\afs_setup_utils_1032.dll" "$INSTDIR"
2645 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver_1032.dll" "$INSTDIR\Common\afsserver_1032.dll" "$INSTDIR"
2646 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afssvrcfg_1032.dll" "$INSTDIR\Common\afssvrcfg_1032.dll" "$INSTDIR"
2647 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1032.dll" "$INSTDIR\Common\TaAfsAccountManager_1032.dll" "$INSTDIR"
2648 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1032.dll" "$INSTDIR\Common\TaAfsAppLib_1032.dll" "$INSTDIR"
2649 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1032.dll" "$INSTDIR\Common\TaAfsServerManager_1032.dll" "$INSTDIR"
2650 File "..\..\doc\help\de_DE\afs-cc.CNT"
2651 File "..\..\doc\help\de_DE\afs-cc.hlp"
2652 File "..\..\doc\help\de_DE\afs-light.CNT"
2653 File "..\..\doc\help\de_DE\afs-light.hlp"
2654 File "..\..\doc\help\de_DE\afs-nt.CNT"
2655 File "..\..\doc\help\de_DE\afs-nt.HLP"
2656 File "..\..\doc\help\de_DE\taafscfg.CNT"
2657 File "..\..\doc\help\de_DE\taafscfg.hlp"
2658 File "..\..\doc\help\de_DE\taafssvrmgr.CNT"
2659 File "..\..\doc\help\de_DE\taafssvrmgr.hlp"
2660 File "..\..\doc\help\de_DE\taafsusrmgr.CNT"
2661 File "..\..\doc\help\de_DE\taafsusrmgr.hlp"
2664 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1032.pdb"
2665 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1032.pdb"
2666 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1032.pdb"
2667 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1032.pdb"
2668 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1032.pdb"
2669 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1032.pdb"
2670 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1032.pdb"
2671 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1032.pdb"
2677 SetOutPath "$INSTDIR\Documentation"
2678 File "..\..\doc\install\Documentation\es_ES\README.TXT"
2680 SetOutPath "$INSTDIR\Client\Program"
2681 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afscreds_1034.dll" "$INSTDIR\Client\Program\afscreds_1034.dll" "$INSTDIR"
2682 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1034.dll" "$INSTDIR\Client\Program\afs_shl_ext_1034.dll" "$INSTDIR"
2684 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1034.pdb"
2685 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1034.pdb"
2688 SetOutPath "$INSTDIR\Common"
2689 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_config_1034.dll" "$INSTDIR\Common\afs_config_1034.dll" "$INSTDIR"
2690 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa_1034.dll" "$INSTDIR\Common\afs_cpa_1034.dll" "$INSTDIR"
2691 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afseventmsg_1034.dll" "$INSTDIR\Common\afseventmsg_1034.dll" "$INSTDIR"
2692 ;!insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1034.dll" "$INSTDIR\Common\afs_setup_utils_1034.dll" "$INSTDIR"
2693 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver_1034.dll" "$INSTDIR\Common\afsserver_1034.dll" "$INSTDIR"
2694 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afssvrcfg_1034.dll" "$INSTDIR\Common\afssvrcfg_1034.dll" "$INSTDIR"
2695 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1034.dll" "$INSTDIR\Common\TaAfsAccountManager_1034.dll" "$INSTDIR"
2696 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1034.dll" "$INSTDIR\Common\TaAfsAppLib_1034.dll" "$INSTDIR"
2697 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1034.dll" "$INSTDIR\Common\TaAfsServerManager_1034.dll" "$INSTDIR"
2698 File "..\..\doc\help\es_ES\afs-cc.CNT"
2699 File "..\..\doc\help\es_ES\afs-cc.hlp"
2700 File "..\..\doc\help\es_ES\afs-light.CNT"
2701 File "..\..\doc\help\es_ES\afs-light.hlp"
2702 File "..\..\doc\help\es_ES\afs-nt.CNT"
2703 File "..\..\doc\help\es_ES\afs-nt.HLP"
2704 File "..\..\doc\help\es_ES\taafscfg.CNT"
2705 File "..\..\doc\help\es_ES\taafscfg.hlp"
2706 File "..\..\doc\help\es_ES\taafssvrmgr.CNT"
2707 File "..\..\doc\help\es_ES\taafssvrmgr.hlp"
2708 File "..\..\doc\help\es_ES\taafsusrmgr.CNT"
2709 File "..\..\doc\help\es_ES\taafsusrmgr.hlp"
2712 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1034.pdb"
2713 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1034.pdb"
2714 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1034.pdb"
2715 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1034.pdb"
2716 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1034.pdb"
2717 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1034.pdb"
2718 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1034.pdb"
2719 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1034.pdb"
2725 SetOutPath "$INSTDIR\Documentation"
2726 File "..\..\doc\install\Documentation\ja_JP\README.TXT"
2728 SetOutPath "$INSTDIR\Client\Program"
2729 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afscreds_1041.dll" "$INSTDIR\Client\Program\afscreds_1041.dll" "$INSTDIR"
2730 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1041.dll" "$INSTDIR\Client\Program\afs_shl_ext_1041.dll" "$INSTDIR"
2732 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1041.pdb"
2733 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1041.pdb"
2736 SetOutPath "$INSTDIR\Common"
2737 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_config_1041.dll" "$INSTDIR\Common\afs_config_1041.dll" "$INSTDIR"
2738 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa_1041.dll" "$INSTDIR\Common\afs_cpa_1041.dll" "$INSTDIR"
2739 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afseventmsg_1041.dll" "$INSTDIR\Common\afseventmsg_1041.dll" "$INSTDIR"
2740 ;!insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1041.dll" "$INSTDIR\Common\afs_setup_utils_1041.dll" "$INSTDIR"
2741 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver_1041.dll" "$INSTDIR\Common\afsserver_1041.dll" "$INSTDIR"
2742 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afssvrcfg_1041.dll" "$INSTDIR\Common\afssvrcfg_1041.dll" "$INSTDIR"
2743 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1041.dll" "$INSTDIR\Common\TaAfsAccountManager_1041.dll" "$INSTDIR"
2744 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1041.dll" "$INSTDIR\Common\TaAfsAppLib_1041.dll" "$INSTDIR"
2745 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1041.dll" "$INSTDIR\Common\TaAfsServerManager_1041.dll" "$INSTDIR"
2746 File "..\..\doc\help\ja_JP\afs-cc.CNT"
2747 File "..\..\doc\help\ja_JP\afs-cc.hlp"
2748 File "..\..\doc\help\ja_JP\afs-light.CNT"
2749 File "..\..\doc\help\ja_JP\afs-light.hlp"
2750 File "..\..\doc\help\ja_JP\afs-nt.CNT"
2751 File "..\..\doc\help\ja_JP\afs-nt.HLP"
2752 File "..\..\doc\help\ja_JP\taafscfg.CNT"
2753 File "..\..\doc\help\ja_JP\taafscfg.hlp"
2754 File "..\..\doc\help\ja_JP\taafssvrmgr.CNT"
2755 File "..\..\doc\help\ja_JP\taafssvrmgr.hlp"
2756 File "..\..\doc\help\ja_JP\taafsusrmgr.CNT"
2757 File "..\..\doc\help\ja_JP\taafsusrmgr.hlp"
2760 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1041.pdb"
2761 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1041.pdb"
2762 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1041.pdb"
2763 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1041.pdb"
2764 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1041.pdb"
2765 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1041.pdb"
2766 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1041.pdb"
2767 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1041.pdb"
2773 SetOutPath "$INSTDIR\Documentation"
2774 File "..\..\doc\install\Documentation\ko_KR\README.TXT"
2776 SetOutPath "$INSTDIR\Client\Program"
2777 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afscreds_1042.dll" "$INSTDIR\Client\Program\afscreds_1042.dll" "$INSTDIR"
2778 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1042.dll" "$INSTDIR\Client\Program\afs_shl_ext_1042.dll" "$INSTDIR"
2780 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1042.pdb"
2781 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1042.pdb"
2784 SetOutPath "$INSTDIR\Common"
2785 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_config_1042.dll" "$INSTDIR\Common\afs_config_1042.dll" "$INSTDIR"
2786 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa_1042.dll" "$INSTDIR\Common\afs_cpa_1042.dll" "$INSTDIR"
2787 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afseventmsg_1042.dll" "$INSTDIR\Common\afseventmsg_1042.dll" "$INSTDIR"
2788 ;!insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1042.dll" "$INSTDIR\Common\afs_setup_utils_1042.dll" "$INSTDIR"
2789 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver_1042.dll" "$INSTDIR\Common\afsserver_1042.dll" "$INSTDIR"
2790 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afssvrcfg_1042.dll" "$INSTDIR\Common\afssvrcfg_1042.dll" "$INSTDIR"
2791 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1042.dll" "$INSTDIR\Common\TaAfsAccountManager_1042.dll" "$INSTDIR"
2792 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1042.dll" "$INSTDIR\Common\TaAfsAppLib_1042.dll" "$INSTDIR"
2793 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1042.dll" "$INSTDIR\Common\TaAfsServerManager_1042.dll" "$INSTDIR"
2794 File "..\..\doc\help\ko_KR\afs-cc.CNT"
2795 File "..\..\doc\help\ko_KR\afs-cc.hlp"
2796 File "..\..\doc\help\ko_KR\afs-light.CNT"
2797 File "..\..\doc\help\ko_KR\afs-light.hlp"
2798 File "..\..\doc\help\ko_KR\afs-nt.CNT"
2799 File "..\..\doc\help\ko_KR\afs-nt.HLP"
2800 File "..\..\doc\help\ko_KR\taafscfg.CNT"
2801 File "..\..\doc\help\ko_KR\taafscfg.hlp"
2802 File "..\..\doc\help\ko_KR\taafssvrmgr.CNT"
2803 File "..\..\doc\help\ko_KR\taafssvrmgr.hlp"
2804 File "..\..\doc\help\ko_KR\taafsusrmgr.CNT"
2805 File "..\..\doc\help\ko_KR\taafsusrmgr.hlp"
2808 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1042.pdb"
2809 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1042.pdb"
2810 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1042.pdb"
2811 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1042.pdb"
2812 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1042.pdb"
2813 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1042.pdb"
2814 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1042.pdb"
2815 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1042.pdb"
2822 SetOutPath "$INSTDIR\Documentation"
2823 File "..\..\doc\install\Documentation\pt_BR\README.TXT"
2825 SetOutPath "$INSTDIR\Client\Program"
2826 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afscreds_1046.dll" "$INSTDIR\Client\Program\afscreds_1046.dll" "$INSTDIR"
2827 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1046.dll" "$INSTDIR\Client\Program\afs_shl_ext_1046.dll" "$INSTDIR"
2829 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1046.pdb"
2830 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1046.pdb"
2833 SetOutPath "$INSTDIR\Common"
2834 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_config_1046.dll" "$INSTDIR\Common\afs_config_1046.dll" "$INSTDIR"
2835 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa_1046.dll" "$INSTDIR\Common\afs_cpa_1046.dll" "$INSTDIR"
2836 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afseventmsg_1046.dll" "$INSTDIR\Common\afseventmsg_1046.dll" "$INSTDIR"
2837 ;!insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1046.dll" "$INSTDIR\Common\afs_setup_utils_1046.dll" "$INSTDIR"
2838 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver_1046.dll" "$INSTDIR\Common\afsserver_1046.dll" "$INSTDIR"
2839 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afssvrcfg_1046.dll" "$INSTDIR\Common\afssvrcfg_1046.dll" "$INSTDIR"
2840 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1046.dll" "$INSTDIR\Common\TaAfsAccountManager_1046.dll" "$INSTDIR"
2841 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1046.dll" "$INSTDIR\Common\TaAfsAppLib_1046.dll" "$INSTDIR"
2842 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1046.dll" "$INSTDIR\Common\TaAfsServerManager_1046.dll" "$INSTDIR"
2843 File "..\..\doc\help\pt_BR\afs-cc.CNT"
2844 File "..\..\doc\help\pt_BR\afs-cc.hlp"
2845 File "..\..\doc\help\pt_BR\afs-light.CNT"
2846 File "..\..\doc\help\pt_BR\afs-light.hlp"
2847 File "..\..\doc\help\pt_BR\afs-nt.CNT"
2848 File "..\..\doc\help\pt_BR\afs-nt.HLP"
2849 File "..\..\doc\help\pt_BR\taafscfg.CNT"
2850 File "..\..\doc\help\pt_BR\taafscfg.hlp"
2851 File "..\..\doc\help\pt_BR\taafssvrmgr.CNT"
2852 File "..\..\doc\help\pt_BR\taafssvrmgr.hlp"
2853 File "..\..\doc\help\pt_BR\taafsusrmgr.CNT"
2854 File "..\..\doc\help\pt_BR\taafsusrmgr.hlp"
2857 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1046.pdb"
2858 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1046.pdb"
2859 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1046.pdb"
2860 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1046.pdb"
2861 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1046.pdb"
2862 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1046.pdb"
2863 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1046.pdb"
2864 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1046.pdb"
2870 SetOutPath "$INSTDIR\Documentation"
2871 File "..\..\doc\install\Documentation\zh_CN\README.TXT"
2873 SetOutPath "$INSTDIR\Client\Program"
2874 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afscreds_2052.dll" "$INSTDIR\Client\Program\afscreds_2052.dll" "$INSTDIR"
2875 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_2052.dll" "$INSTDIR\Client\Program\afs_shl_ext_2052.dll" "$INSTDIR"
2877 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_2052.pdb"
2878 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_2052.pdb"
2881 SetOutPath "$INSTDIR\Common"
2882 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_config_2052.dll" "$INSTDIR\Common\afs_config_2052.dll" "$INSTDIR"
2883 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa_2052.dll" "$INSTDIR\Common\afs_cpa_2052.dll" "$INSTDIR"
2884 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afseventmsg_2052.dll" "$INSTDIR\Common\afseventmsg_2052.dll" "$INSTDIR"
2885 ;!insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afs_setup_utils_2052.dll" "$INSTDIR\Common\afs_setup_utils_2052.dll" "$INSTDIR"
2886 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver_2052.dll" "$INSTDIR\Common\afsserver_2052.dll" "$INSTDIR"
2887 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afssvrcfg_2052.dll" "$INSTDIR\Common\afssvrcfg_2052.dll" "$INSTDIR"
2888 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_2052.dll" "$INSTDIR\Common\TaAfsAccountManager_2052.dll" "$INSTDIR"
2889 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_2052.dll" "$INSTDIR\Common\TaAfsAppLib_2052.dll" "$INSTDIR"
2890 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_2052.dll" "$INSTDIR\Common\TaAfsServerManager_2052.dll" "$INSTDIR"
2891 File "..\..\doc\help\zh_CN\afs-cc.CNT"
2892 File "..\..\doc\help\zh_CN\afs-cc.hlp"
2893 File "..\..\doc\help\zh_CN\afs-light.CNT"
2894 File "..\..\doc\help\zh_CN\afs-light.hlp"
2895 File "..\..\doc\help\zh_CN\afs-nt.CNT"
2896 File "..\..\doc\help\zh_CN\afs-nt.HLP"
2897 File "..\..\doc\help\zh_CN\taafscfg.CNT"
2898 File "..\..\doc\help\zh_CN\taafscfg.hlp"
2899 File "..\..\doc\help\zh_CN\taafssvrmgr.CNT"
2900 File "..\..\doc\help\zh_CN\taafssvrmgr.hlp"
2901 File "..\..\doc\help\zh_CN\taafsusrmgr.CNT"
2902 File "..\..\doc\help\zh_CN\taafsusrmgr.hlp"
2905 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_2052.pdb"
2906 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_2052.pdb"
2907 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_2052.pdb"
2908 ;File "${AFS_SERVER_BUILDDIR}\afsserver_2052.pdb"
2909 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_2052.pdb"
2910 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_2052.pdb"
2911 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_2052.pdb"
2912 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_2052.pdb"
2918 SetOutPath "$INSTDIR\Documentation"
2919 File "..\..\doc\install\Documentation\zh_TW\README.TXT"
2921 SetOutPath "$INSTDIR\Client\Program"
2922 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afscreds_1028.dll" "$INSTDIR\Client\Program\_1028.dll" "$INSTDIR"
2923 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1028.dll" "$INSTDIR\Client\Program\afs_shl_ext_1028.dll" "$INSTDIR"
2925 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1028.pdb"
2926 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1028.pdb"
2929 SetOutPath "$INSTDIR\Common"
2930 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_config_1028.dll" "$INSTDIR\Common\afs_config_1028.dll" "$INSTDIR"
2931 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa_1028.dll" "$INSTDIR\Common\afs_cpa_1028.dll" "$INSTDIR"
2932 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afseventmsg_1028.dll" "$INSTDIR\Common\afseventmsg_1028.dll" "$INSTDIR"
2933 ;!insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1028.dll" "$INSTDIR\Common\afs_setup_utils_1028.dll" "$INSTDIR"
2934 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver_1028.dll" "$INSTDIR\Common\afsserver_1028.dll" "$INSTDIR"
2935 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afssvrcfg_1028.dll" "$INSTDIR\Common\afssvrcfg_1028.dll" "$INSTDIR"
2936 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1028.dll" "$INSTDIR\Common\TaAfsAccountManager_1028.dll" "$INSTDIR"
2937 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1028.dll" "$INSTDIR\Common\TaAfsAppLib_1028.dll" "$INSTDIR"
2938 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1028.dll" "$INSTDIR\Common\TaAfsServerManager_1028.dll" "$INSTDIR"
2939 File "..\..\doc\help\zh_TW\afs-cc.CNT"
2940 File "..\..\doc\help\zh_TW\afs-cc.hlp"
2941 File "..\..\doc\help\zh_TW\afs-light.CNT"
2942 File "..\..\doc\help\zh_TW\afs-light.hlp"
2943 File "..\..\doc\help\zh_TW\afs-nt.CNT"
2944 File "..\..\doc\help\zh_TW\afs-nt.HLP"
2945 File "..\..\doc\help\zh_TW\taafscfg.CNT"
2946 File "..\..\doc\help\zh_TW\taafscfg.hlp"
2947 File "..\..\doc\help\zh_TW\taafssvrmgr.CNT"
2948 File "..\..\doc\help\zh_TW\taafssvrmgr.hlp"
2949 File "..\..\doc\help\zh_TW\taafsusrmgr.CNT"
2950 File "..\..\doc\help\zh_TW\taafsusrmgr.hlp"
2953 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1028.pdb"
2954 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1028.pdb"
2955 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1028.pdb"
2956 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1028.pdb"
2957 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1028.pdb"
2958 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1028.pdb"
2959 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1028.pdb"
2960 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1028.pdb"
2969 ;====================================================
2970 ; AddToPath - Adds the given dir to the search path.
2971 ; Input - head of the stack
2972 ; Note - Win9x systems requires reboot
2973 ;====================================================
2980 # don't add if the path doesn't exist
2981 IfFileExists $0 "" AddToPath_done
2988 StrCmp $2 "" "" AddToPath_done
2993 StrCmp $2 "" "" AddToPath_done
2994 GetFullPathName /SHORT $3 $0
2999 StrCmp $2 "" "" AddToPath_done
3004 StrCmp $2 "" "" AddToPath_done
3008 StrCmp $1 1 AddToPath_NT
3011 FileOpen $1 "$1\autoexec.bat" a
3014 IntCmp $2 26 0 +2 +2 # DOS EOF
3015 FileSeek $1 -1 END # write over EOF
3016 FileWrite $1 "$\r$\nSET PATH=%PATH%;$3$\r$\n"
3022 ReadRegStr $1 HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "PATH"
3023 StrCpy $2 $1 1 -1 # copy last char
3024 StrCmp $2 ";" 0 +2 # if last char == ;
3025 StrCpy $1 $1 -1 # remove last char
3026 StrCmp $1 "" AddToPath_NTdoIt
3029 WriteRegExpandStr HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "PATH" $0
3030 SendMessage ${HWND_BROADCAST} ${WM_WININICHANGE} 0 "STR:Environment" /TIMEOUT=5000
3039 ;====================================================
3040 ; RemoveFromPath - Remove a given dir from the path
3041 ; Input: head of the stack
3042 ;====================================================
3043 Function un.RemoveFromPath
3052 IntFmt $6 "%c" 26 # DOS EOF
3056 StrCmp $1 1 unRemoveFromPath_NT
3059 FileOpen $1 "$1\autoexec.bat" r
3062 GetFullPathName /SHORT $0 $0
3063 StrCpy $0 "SET PATH=%PATH%;$0"
3064 Goto unRemoveFromPath_dosLoop
3066 unRemoveFromPath_dosLoop:
3068 StrCpy $5 $3 1 -1 # read last char
3069 StrCmp $5 $6 0 +2 # if DOS EOF
3070 StrCpy $3 $3 -1 # remove DOS EOF so we can compare
3071 StrCmp $3 "$0$\r$\n" unRemoveFromPath_dosLoopRemoveLine
3072 StrCmp $3 "$0$\n" unRemoveFromPath_dosLoopRemoveLine
3073 StrCmp $3 "$0" unRemoveFromPath_dosLoopRemoveLine
3074 StrCmp $3 "" unRemoveFromPath_dosLoopEnd
3076 Goto unRemoveFromPath_dosLoop
3077 unRemoveFromPath_dosLoopRemoveLine:
3079 Goto unRemoveFromPath_dosLoop
3081 unRemoveFromPath_dosLoopEnd:
3085 Delete "$1\autoexec.bat"
3086 CopyFiles /SILENT $4 "$1\autoexec.bat"
3088 Goto unRemoveFromPath_done
3090 unRemoveFromPath_NT:
3091 ReadRegStr $1 HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "PATH"
3092 StrCpy $5 $1 1 -1 # copy last char
3093 StrCmp $5 ";" +2 # if last char != ;
3094 StrCpy $1 "$1;" # append ;
3097 Call un.StrStr ; Find `$0;` in $1
3098 Pop $2 ; pos of our dir
3099 StrCmp $2 "" unRemoveFromPath_done
3100 ; else, it is in path
3105 StrCpy $5 $1 -$4 # $5 is now the part before the path to remove
3106 StrCpy $6 $2 "" $3 # $6 is now the part after the path to remove
3109 StrCpy $5 $3 1 -1 # copy last char
3110 StrCmp $5 ";" 0 +2 # if last char == ;
3111 StrCpy $3 $3 -1 # remove last char
3113 WriteRegExpandStr HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "PATH" $3
3114 SendMessage ${HWND_BROADCAST} ${WM_WININICHANGE} 0 "STR:Environment" /TIMEOUT=5000
3116 unRemoveFromPath_done:
3126 ;====================================================
3127 ; IsNT - Returns 1 if the current system is NT, 0
3129 ; Output: head of the stack
3130 ;====================================================
3134 ReadRegStr $0 HKLM "SOFTWARE\Microsoft\Windows NT\CurrentVersion" CurrentVersion
3135 StrCmp $0 "" 0 IsNT_yes
3147 !insertmacro IsNT ""
3148 !insertmacro IsNT "un."
3150 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
3152 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
3153 ;====================================================
3154 ; StrStr - Finds a given string in another given string.
3155 ; Returns -1 if not found and the pos if found.
3156 ; Input: head of the stack - string to find
3157 ; second in the stack - string to find in
3158 ; Output: head of the stack
3159 ;====================================================
3161 Function ${un}StrStr
3162 Exch $R1 ; st=haystack,old$R1, $R1=needle
3163 Exch ; st=old$R1,haystack
3164 Exch $R2 ; st=old$R1,old$R2, $R2=haystack
3176 StrCpy $R5 $R2 $R3 $R4
3182 StrCpy $R1 $R2 "" $R4
3190 !insertmacro StrStr ""
3191 !insertmacro StrStr "un."
3194 !ifdef ADDSHAREDDLLUSED
3197 ; Increments a shared DLLs reference count.
3198 ; Use by passing one item on the stack (the full path of the DLL).
3201 ; Push $SYSDIR\myDll.dll
3205 Function AddSharedDLL
3208 ReadRegDword $R0 HKLM Software\Microsoft\Windows\CurrentVersion\SharedDLLs $R1
3210 WriteRegDWORD HKLM Software\Microsoft\Windows\CurrentVersion\SharedDLLs $R1 $R0
3216 ; un.RemoveSharedDLL
3218 ; Decrements a shared DLLs reference count, and removes if necessary.
3219 ; Use by passing one item on the stack (the full path of the DLL).
3220 ; Note: for use in the main installer (not the uninstaller), rename the
3221 ; function to RemoveSharedDLL.
3224 ; Push $SYSDIR\myDll.dll
3225 ; Call un.RemoveSharedDLL
3228 Function un.RemoveSharedDLL
3231 ReadRegDword $R0 HKLM Software\Microsoft\Windows\CurrentVersion\SharedDLLs $R1
3232 StrCmp $R0 "" remove
3234 IntCmp $R0 0 rk rk uk
3236 DeleteRegValue HKLM Software\Microsoft\Windows\CurrentVersion\SharedDLLs $R1
3239 WriteRegDWORD HKLM Software\Microsoft\Windows\CurrentVersion\SharedDLLs $R1 $R0
3242 Delete /REBOOTOK $R1
3251 !ifdef INSTALL_LOOPBACK
3252 Function afs.InstallMSLoopback
3254 File /oname=$R0 "loopback_install.dll"
3255 nsExec::Exec "rundll32.exe $R0 doLoopBackEntry quiet"
3256 Call GetWindowsVersion
3258 StrCmp $R1 "2000" +1 +2
3259 nsExec::Exec "rundll32.exe $R0 disableLoopBackEntry"
3267 ; Based on Yazno's function, http://yazno.tripod.com/powerpimpit/
3268 ; Updated by Joost Verburg
3270 ; Returns on top of stack
3272 ; Windows Version (95, 98, ME, NT x.x, 2000, XP, 2003)
3274 ; '' (Unknown Windows Version)
3277 ; Call GetWindowsVersion
3279 ; ; at this point $R0 is "NT 4.0" or whatnot
3281 Function GetWindowsVersion
3288 ReadRegStr $R0 HKLM \
3289 "SOFTWARE\Microsoft\Windows NT\CurrentVersion" CurrentVersion
3291 IfErrors 0 lbl_winnt
3294 ReadRegStr $R0 HKLM \
3295 "SOFTWARE\Microsoft\Windows\CurrentVersion" VersionNumber
3298 StrCmp $R1 '4' 0 lbl_error
3302 StrCmp $R1 '4.0' lbl_win32_95
3303 StrCmp $R1 '4.9' lbl_win32_ME lbl_win32_98
3321 StrCmp $R1 '3' lbl_winnt_x
3322 StrCmp $R1 '4' lbl_winnt_x
3326 StrCmp $R1 '5.0' lbl_winnt_2000
3327 StrCmp $R1 '5.1' lbl_winnt_XP
3328 StrCmp $R1 '5.2' lbl_winnt_2003 lbl_error
3331 StrCpy $R0 "NT $R0" 6
3356 ; Author: Lilla (lilla@earthlink.net) 2003-06-13
3357 ; function IsUserAdmin uses plugin \NSIS\PlusgIns\UserInfo.dll
3358 ; This function is based upon code in \NSIS\Contrib\UserInfo\UserInfo.nsi
3359 ; This function was tested under NSIS 2 beta 4 (latest CVS as of this writing).
3363 ; Pop $R0 ; at this point $R0 is "true" or "false"
3365 Function IsUserAdmin
3374 UserInfo::GetAccountType
3377 StrCmp $R2 "Admin" 0 Continue
3378 ; Observation: I get here when running Win98SE. (Lilla)
3379 ; The functions UserInfo.dll looks for are there on Win98 too,
3380 ; but just don't work. So UserInfo.dll, knowing that admin isn't required
3381 ; on Win98, returns admin anyway. (per kichik)
3382 ; MessageBox MB_OK 'User "$R1" is in the Administrators group'
3387 ; You should still check for an empty string because the functions
3388 ; UserInfo.dll looks for may not be present on Windows 95. (per kichik)
3391 ;MessageBox MB_OK 'User "$R1" is in the "$R2" group'
3395 ; comment/message below is by UserInfo.nsi author:
3396 ; This one means you don't need to care about admin or
3397 ; not admin because Windows 9x doesn't either
3398 ;MessageBox MB_OK "Error! This DLL can't run under Windows 9x!"
3402 ;MessageBox MB_OK 'User= "$R1" AccountType= "$R2" IsUserAdmin= "$R0"'
3410 ; input, top of stack (e.g. C:\Program Files\Poop)
3411 ; output, top of stack (replaces, with e.g. C:\Program Files)
3412 ; modifies no other variables.
3415 ; Push "C:\Program Files\Directory\Whatever"
3418 ; ; at this point $R0 will equal "C:\Program Files\Directory"
3432 IntCmp $R1 $R2 get 0 get
3433 StrCpy $R3 $R0 1 -$R1
3448 ;--------------------------------
3449 ;Handle what must and what must not be installed
3450 Function .onSelChange
3451 ; If they install the server, they MUST install the client
3452 SectionGetFlags ${secServer} $R0
3453 IntOp $R0 $R0 & ${SF_SELECTED}
3454 StrCmp $R0 "1" MakeClientSelected
3456 ; If they install the control center, we'll give them the client.
3457 ; It may not be required, but it's a bit more useful
3458 SectionGetFlags ${secControl} $R0
3459 IntOp $R0 $R0 & ${SF_SELECTED}
3460 StrCmp $R0 "1" MakeClientSelected
3464 SectionGetFlags ${secClient} $R0
3465 IntOp $R0 $R0 | ${SF_SELECTED}
3466 SectionSetFlags ${secClient} $R0
3471 Function RegWriteMultiStr
3472 !define HKEY_CLASSES_ROOT 0x80000000
3473 !define HKEY_CURRENT_USER 0x80000001
3474 !define HKEY_LOCAL_MACHINE 0x80000002
3475 !define HKEY_USERS 0x80000003
3476 !define HKEY_PERFORMANCE_DATA 0x80000004
3477 !define HKEY_PERFORMANCE_TEXT 0x80000050
3478 !define HKEY_PERFORMANCE_NLSTEXT 0x80000060
3479 !define HKEY_CURRENT_CONFIG 0x80000005
3480 !define HKEY_DYN_DATA 0x80000006
3482 !define KEY_QUERY_VALUE 0x0001
3483 !define KEY_SET_VALUE 0x0002
3484 !define KEY_CREATE_SUB_KEY 0x0004
3485 !define KEY_ENUMERATE_SUB_KEYS 0x0008
3486 !define KEY_NOTIFY 0x0010
3487 !define KEY_CREATE_LINK 0x0020
3491 !define REG_EXPAND_SZ 2
3492 !define REG_BINARY 3
3494 !define REG_DWORD_LITTLE_ENDIAN 4
3495 !define REG_DWORD_BIG_ENDIAN 5
3497 !define REG_MULTI_SZ 7
3499 !define RegCreateKey "Advapi32::RegCreateKeyA(i, t, *i) i"
3500 !define RegSetValueEx "Advapi32::RegSetValueExA(i, t, i, i, i, i) i"
3501 !define RegCloseKey "Advapi32::RegCloseKeyA(i) i"
3508 SetPluginUnload alwaysoff
3509 ; Create a buffer for the multi_sz value
3510 System::Call "*(&t${NSIS_MAX_STRLEN}) i.r1"
3511 ; Open/create the registry key
3512 System::Call "${RegCreateKey}(${HKEY_LOCAL_MACHINE}, '$REG_SUB_KEY', .r0) .r9"
3515 MessageBox MB_OK|MB_ICONSTOP "Can't create registry key! ($9)"
3519 ; Fill in the buffer with our strings
3520 StrCpy $2 $1 ; Initial position
3522 StrLen $9 '$REG_DATA_1' ; Length of first string
3523 IntOp $9 $9 + 1 ; Plus null
3524 System::Call "*$2(&t$9 '$REG_DATA_1')" ; Place the string
3525 IntOp $2 $2 + $9 ; Advance to the next position
3527 StrCmp '$REG_DATA_2' "" terminate
3528 StrLen $9 '$REG_DATA_2' ; Length of second string
3529 IntOp $9 $9 + 1 ; Plus null
3530 System::Call "*$2(&t$9 '$REG_DATA_2')" ; Place the string
3531 IntOp $2 $2 + $9 ; Advance to the next position
3533 StrCmp '$REG_DATA_3' "" terminate
3534 StrLen $9 '$REG_DATA_3' ; Length of third string
3535 IntOp $9 $9 + 1 ; Plus null
3536 System::Call "*$2(&t$9 '$REG_DATA_3')" ; Place the string
3537 IntOp $2 $2 + $9 ; Advance to the next position
3540 System::Call "*$2(&t1 '')" ; Place the terminating null
3541 IntOp $2 $2 + 1 ; Advance to the next position
3543 ; Create/write the value
3544 IntOp $2 $2 - $1 ; Total length
3545 System::Call "${RegSetValueEx}(r0, '$REG_VALUE', 0, ${REG_MULTI_SZ}, r1, r2) .r9"
3548 MessageBox MB_OK|MB_ICONSTOP "Can't set key value! ($9)"
3552 ; Close the registry key
3553 System::Call "${RegCloseKey}(r0)"
3557 SetPluginUnload manual