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)2004"
37 VIAddVersionKey "PrivateBuild" "Checked/Debug"
44 ;--------------------------------
49 OutFile "${AFS_DESTDIR}\WinInstall\OpenAFSforWindows.exe"
51 OutFile "${AFS_DESTDIR}\WinInstall\OpenAFSforWindows-DEBUG.exe"
55 !define MUI_ICON "..\..\client_config\afs_config.ico"
56 !define MUI_UNICON "..\..\client_config\afs_config.ico"
57 !define AFS_COMPANY_NAME "OpenAFS"
58 !define AFS_PRODUCT_NAME "OpenAFS"
59 !define AFS_REGKEY_ROOT "Software\TransarcCorporation"
62 ;Folder selection page
63 InstallDir "$PROGRAMFILES\OpenAFS" ; Install to shorter path
65 ;Remember install folder
66 InstallDirRegKey HKCU ${AFS_REGKEY_ROOT} ""
68 ;Remember the installer language
69 !define MUI_LANGDLL_REGISTRY_ROOT "HKCU"
70 !define MUI_LANGDLL_REGISTRY_KEY ${AFS_REGKEY_ROOT}
71 !define MUI_LANGDLL_REGISTRY_VALUENAME "Installer Language"
74 !define AFS_CLIENT_BUILDDIR "${AFS_DESTDIR}\root.client\usr\vice\etc"
75 !define AFS_WININSTALL_DIR "${AFS_DESTDIR}\WinInstall\Config"
76 !define AFS_BUILD_INCDIR "${AFS_DESTDIR}\include"
77 !define AFS_CLIENT_LIBDIR "${AFS_DESTDIR}\lib"
78 !define AFS_SERVER_BUILDDIR "${AFS_DESTDIR}\root.server\usr\afs\bin"
79 !define AFS_ETC_BUILDDIR "${AFS_DESTDIR}\etc"
80 !define SYSTEMDIR "$%SystemRoot%\System32"
82 ;--------------------------------
83 ;Modern UI Configuration
85 ;!define MUI_LICENSEPAGE
86 !define MUI_CUSTOMPAGECOMMANDS
87 !define MUI_WELCOMEPAGE
88 !define MUI_COMPONENTSPAGE
89 !define MUI_COMPONENTSPAGE_SMALLDESC
90 !define MUI_DIRECTORYPAGE
92 !define MUI_ABORTWARNING
93 !define MUI_FINISHPAGE
95 !define MUI_UNINSTALLER
96 !define MUI_UNCONFIRMPAGE
99 !insertmacro MUI_PAGE_WELCOME
100 !insertmacro MUI_PAGE_COMPONENTS
101 !insertmacro MUI_PAGE_DIRECTORY
102 Page custom AFSPageGetCellServDB
103 Page custom AFSPageGetCellName
104 !insertmacro MUI_PAGE_INSTFILES
105 !insertmacro MUI_PAGE_FINISH
107 ;LicenseData "Licenses.rtf"
108 ;--------------------------------
111 !insertmacro MUI_LANGUAGE "English"
112 ;!insertmacro MUI_LANGUAGE "French"
113 !insertmacro MUI_LANGUAGE "German"
114 !insertmacro MUI_LANGUAGE "Spanish"
115 !insertmacro MUI_LANGUAGE "SimpChinese"
116 !insertmacro MUI_LANGUAGE "TradChinese"
117 !insertmacro MUI_LANGUAGE "Japanese"
118 !insertmacro MUI_LANGUAGE "Korean"
119 ;!insertmacro MUI_LANGUAGE "Italian"
120 ;!insertmacro MUI_LANGUAGE "Dutch"
121 ;!insertmacro MUI_LANGUAGE "Danish"
122 ;!insertmacro MUI_LANGUAGE "Greek"
123 ;!insertmacro MUI_LANGUAGE "Russian"
124 !insertmacro MUI_LANGUAGE "PortugueseBR"
125 ;!insertmacro MUI_LANGUAGE "Polish"
126 ;!insertmacro MUI_LANGUAGE "Ukrainian"
127 ;!insertmacro MUI_LANGUAGE "Czech"
128 ;!insertmacro MUI_LANGUAGE "Slovak"
129 ;!insertmacro MUI_LANGUAGE "Croatian"
130 ;!insertmacro MUI_LANGUAGE "Bulgarian"
131 ;!insertmacro MUI_LANGUAGE "Hungarian"
132 ;!insertmacro MUI_LANGUAGE "Thai"
133 ;!insertmacro MUI_LANGUAGE "Romanian"
134 ;!insertmacro MUI_LANGUAGE "Macedonian"
135 ;!insertmacro MUI_LANGUAGE "Turkish"
137 ;--------------------------------
141 LangString DESC_SecCopyUI ${LANG_ENGLISH} "OpenAFS for Windows: English"
142 ;LangString DESC_SecCopyUI ${LANG_FRENCH} "OpenAFS for Windows: French"
143 LangString DESC_SecCopyUI ${LANG_GERMAN} "OpenAFS for Windows: German"
144 LangString DESC_SecCopyUI ${LANG_SPANISH} "OpenAFS for Windows: Spanish"
145 LangString DESC_SecCopyUI ${LANG_SIMPCHINESE} "OpenAFS for Windows: Simplified Chinese"
146 LangString DESC_SecCopyUI ${LANG_TRADCHINESE} "OpenAFS for Windows: Traditional Chinese description"
147 LangString DESC_SecCopyUI ${LANG_JAPANESE} "OpenAFS for Windows: Japanese description"
148 LangString DESC_SecCopyUI ${LANG_KOREAN} "OpenAFS for Windows: Korean description"
149 ;LangString DESC_SecCopyUI ${LANG_ITALIAN} "OpenAFS for Windows: Italian description"
150 ;LangString DESC_SecCopyUI ${LANG_DUTCH} "OpenAFS for Windows: Dutch description"
151 ;LangString DESC_SecCopyUI ${LANG_DANISH} "OpenAFS for Windows: Danish description"
152 ;LangString DESC_SecCopyUI ${LANG_GREEK} "OpenAFS for Windows: Greek description"
153 ;LangString DESC_SecCopyUI ${LANG_RUSSIAN} "OpenAFS for Windows: Russian description"
154 LangString DESC_SecCopyUI ${LANG_PORTUGUESEBR} "OpenAFS for Windows: Portuguese (Brasil) description"
155 ;LangString DESC_SecCopyUI ${LANG_POLISH} "OpenAFS for Windows: Polish description"
156 ;LangString DESC_SecCopyUI ${LANG_UKRAINIAN} "OpenAFS for Windows: Ukrainian description"
157 ;LangString DESC_SecCopyUI ${LANG_CZECH} "OpenAFS for Windows: Czechian description"
158 ;LangString DESC_SecCopyUI ${LANG_SLOVAK} "OpenAFS for Windows: Slovakian description"
159 ;LangString DESC_SecCopyUI ${LANG_CROATIAN} "OpenAFS for Windows: Slovakian description"
160 ;LangString DESC_SecCopyUI ${LANG_BULGARIAN} "OpenAFS for Windows: Bulgarian description"
161 ;LangString DESC_SecCopyUI ${LANG_HUNGARIAN} "OpenAFS for Windows: Hungarian description"
162 ;LangString DESC_SecCopyUI ${LANG_THAI} "OpenAFS for Windows: Thai description"
163 ;LangString DESC_SecCopyUI ${LANG_ROMANIAN} "OpenAFS for Windows: Romanian description"
164 ;LangString DESC_SecCopyUI ${LANG_MACEDONIAN} "OpenAFS for Windows: Macedonian description"
165 ;LangString DESC_SecCopyUI ${LANG_TURKISH} "OpenAFS for Windows: Turkish description"
167 LangString DESC_secClient ${LANG_ENGLISH} "OpenAFS Client: Allows you to access AFS from your Windows PC."
168 LangString DESC_secClient ${LANG_GERMAN} "OpenAFS Client: Allows you to access AFS from your Windows PC."
169 LangString DESC_secClient ${LANG_SPANISH} "OpenAFS Client: Allows you to access AFS from your Windows PC."
170 LangString DESC_secClient ${LANG_SIMPCHINESE} "OpenAFS Client: Allows you to access AFS from your Windows PC."
171 LangString DESC_secClient ${LANG_TRADCHINESE} "OpenAFS Client: Allows you to access AFS from your Windows PC."
172 LangString DESC_secClient ${LANG_JAPANESE} "OpenAFS Client: Allows you to access AFS from your Windows PC."
173 LangString DESC_secClient ${LANG_KOREAN} "OpenAFS Client: Allows you to access AFS from your Windows PC."
174 LangString DESC_secClient ${LANG_PORTUGUESEBR} "OpenAFS Client: Allows you to access AFS from your Windows PC."
176 LangString DESC_secServer ${LANG_ENGLISH} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
177 LangString DESC_secServer ${LANG_GERMAN} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
178 LangString DESC_secServer ${LANG_SPANISH} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
179 LangString DESC_secServer ${LANG_SIMPCHINESE} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
180 LangString DESC_secServer ${LANG_TRADCHINESE} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
181 LangString DESC_secServer ${LANG_JAPANESE} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
182 LangString DESC_secServer ${LANG_KOREAN} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
183 LangString DESC_secServer ${LANG_PORTUGUESEBR} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
185 LangString DESC_secControl ${LANG_ENGLISH} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
186 LangString DESC_secControl ${LANG_GERMAN} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
187 LangString DESC_secControl ${LANG_SPANISH} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
188 LangString DESC_secControl ${LANG_SIMPCHINESE} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
189 LangString DESC_secControl ${LANG_TRADCHINESE} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
190 LangString DESC_secControl ${LANG_JAPANESE} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
191 LangString DESC_secControl ${LANG_KOREAN} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
192 LangString DESC_secControl ${LANG_PORTUGUESEBR} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
194 LangString DESC_secDocs ${LANG_ENGLISH} "Supplemental Documentation: Additional documentation for using OpenAFS."
195 LangString DESC_secDocs ${LANG_GERMAN} "Supplemental Documentation: Additional documentation for using OpenAFS."
196 LangString DESC_secDocs ${LANG_SPANISH} "Supplemental Documentation: Additional documentation for using OpenAFS."
197 LangString DESC_secDocs ${LANG_SIMPCHINESE} "Supplemental Documentation: Additional documentation for using OpenAFS."
198 LangString DESC_secDocs ${LANG_TRADCHINESE} "Supplemental Documentation: Additional documentation for using OpenAFS."
199 LangString DESC_secDocs ${LANG_JAPANESE} "Supplemental Documentation: Additional documentation for using OpenAFS."
200 LangString DESC_secDocs ${LANG_KOREAN} "Supplemental Documentation: Additional documentation for using OpenAFS."
201 LangString DESC_secDocs ${LANG_PORTUGUESEBR} "Supplemental Documentation: Additional documentation for using OpenAFS."
203 LangString DESC_secSDK ${LANG_ENGLISH} "SDK: Header files and libraries for developing software with OpenAFS."
204 LangString DESC_secSDK ${LANG_GERMAN} "SDK: Header files and libraries for developing software with OpenAFS."
205 LangString DESC_secSDK ${LANG_SPANISH} "SDK: Header files and libraries for developing software with OpenAFS."
206 LangString DESC_secSDK ${LANG_SIMPCHINESE} "SDK: Header files and libraries for developing software with OpenAFS."
207 LangString DESC_secSDK ${LANG_TRADCHINESE} "SDK: Header files and libraries for developing software with OpenAFS."
208 LangString DESC_secSDK ${LANG_JAPANESE} "SDK: Header files and libraries for developing software with OpenAFS."
209 LangString DESC_secSDK ${LANG_KOREAN} "SDK: Header files and libraries for developing software with OpenAFS."
210 LangString DESC_secSDK ${LANG_PORTUGUESEBR} "SDK: Header files and libraries for developing software with OpenAFS."
212 ; Popup error messages
213 LangString CellError ${LANG_ENGLISH} "You must specify a valid CellServDB file to copy during install"
214 LangString CellError ${LANG_GERMAN} "You must specify a valid CellServDB file to copy during the install"
215 LangString CellError ${LANG_SPANISH} "You must specify a valid CellServDB file to copy during the install"
216 LangString CellError ${LANG_SIMPCHINESE} "You must specify a valid CellServDB file to copy during the install"
217 LangString CellError ${LANG_TRADCHINESE} "You must specify a valid CellServDB file to copy during the install"
218 LangString CellError ${LANG_JAPANESE} "You must specify a valid CellServDB file to copy during the install"
219 LangString CellError ${LANG_KOREAN} "You must specify a valid CellServDB file to copy during the install"
220 LangString CellError ${LANG_PORTUGUESEBR} "You must specify a valid CellServDB file to copy during the install"
222 LangString CellNameError ${LANG_ENGLISH} "You must specify a cell name for your client to use."
223 LangString CellNameError ${LANG_GERMAN} "You must specify a cell name for your client to use."
224 LangString CellNameError ${LANG_SPANISH} "You must specify a cell name for your client to use."
225 LangString CellNameError ${LANG_SIMPCHINESE} "You must specify a cell name for your client to use."
226 LangString CellNameError ${LANG_TRADCHINESE} "You must specify a cell name for your client to use."
227 LangString CellNameError ${LANG_JAPANESE} "You must specify a cell name for your client to use."
228 LangString CellNameError ${LANG_KOREAN} "You must specify a cell name for your client to use."
229 LangString CellNameError ${LANG_PORTUGUESEBR} "You must specify a cell name for your client to use."
231 LangString URLError ${LANG_ENGLISH} "You must specify a URL if you choose the option to download the CellServDB."
232 LangString URLError ${LANG_GERMAN} "You must specify a URL if you choose the option to download the CellServDB."
233 LangString URLError ${LANG_SPANISH} "You must specify a URL if you choose the option to download the CellServDB."
234 LangString URLError ${LANG_SIMPCHINESE} "You must specify a URL if you choose the option to download the CellServDB."
235 LangString URLError ${LANG_TRADCHINESE} "You must specify a URL if you choose the option to download the CellServDB."
236 LangString URLError ${LANG_JAPANESE} "You must specify a URL if you choose the option to download the CellServDB."
237 LangString URLError ${LANG_KOREAN} "You must specify a URL if you choose the option to download the CellServDB."
238 LangString URLError ${LANG_PORTUGUESEBR} "You must specify a URL if you choose the option to download the CellServDB."
241 ; Upgrade/re-install strings
242 LangString UPGRADE_CLIENT ${LANG_ENGLISH} "Upgrade AFS Client"
243 LangString UPGRADE_CLIENT ${LANG_GERMAN} "Upgrade AFS Client"
244 LangString UPGRADE_CLIENT ${LANG_SPANISH} "Upgrade AFS Client"
245 LangString UPGRADE_CLIENT ${LANG_SIMPCHINESE} "Upgrade AFS Client"
246 LangString UPGRADE_CLIENT ${LANG_TRADCHINESE} "Upgrade AFS Client"
247 LangString UPGRADE_CLIENT ${LANG_JAPANESE} "Upgrade AFS Client"
248 LangString UPGRADE_CLIENT ${LANG_KOREAN} "Upgrade AFS Client"
249 LangString UPGRADE_CLIENT ${LANG_PORTUGUESEBR} "Upgrade AFS Client"
251 LangString REINSTALL_CLIENT ${LANG_ENGLISH} "Re-install AFS Client"
252 LangString REINSTALL_CLIENT ${LANG_GERMAN} "Re-install AFS Client"
253 LangString REINSTALL_CLIENT ${LANG_SPANISH} "Re-install AFS Client"
254 LangString REINSTALL_CLIENT ${LANG_SIMPCHINESE} "Re-install AFS Client"
255 LangString REINSTALL_CLIENT ${LANG_TRADCHINESE} "Re-install AFS Client"
256 LangString REINSTALL_CLIENT ${LANG_JAPANESE} "Re-install AFS Client"
257 LangString REINSTALL_CLIENT ${LANG_KOREAN} "Re-install AFS Client"
258 LangString REINSTALL_CLIENT ${LANG_PORTUGUESEBR} "Re-install AFS Client"
260 LangString UPGRADE_SERVER ${LANG_ENGLISH} "Upgrade AFS Server"
261 LangString UPGRADE_SERVER ${LANG_GERMAN} "Upgrade AFS Server"
262 LangString UPGRADE_SERVER ${LANG_SPANISH} "Upgrade AFS Server"
263 LangString UPGRADE_SERVER ${LANG_SIMPCHINESE} "Upgrade AFS Server"
264 LangString UPGRADE_SERVER ${LANG_TRADCHINESE} "Upgrade AFS Server"
265 LangString UPGRADE_SERVER ${LANG_JAPANESE} "Upgrade AFS Server"
266 LangString UPGRADE_SERVER ${LANG_KOREAN} "Upgrade AFS Server"
267 LangString UPGRADE_SERVER ${LANG_PORTUGUESEBR} "Upgrade AFS Server"
269 LangString REINSTALL_SERVER ${LANG_ENGLISH} "Re-install AFS Server"
270 LangString REINSTALL_SERVER ${LANG_GERMAN} "Re-install AFS Server"
271 LangString REINSTALL_SERVER ${LANG_SPANISH} "Re-install AFS Server"
272 LangString REINSTALL_SERVER ${LANG_SIMPCHINESE} "Re-install AFS Server"
273 LangString REINSTALL_SERVER ${LANG_TRADCHINESE} "Re-install AFS Server"
274 LangString REINSTALL_SERVER ${LANG_JAPANESE} "Re-install AFS Server"
275 LangString REINSTALL_SERVER ${LANG_KOREAN} "Re-install AFS Server"
276 LangString REINSTALL_SERVER ${LANG_PORTUGUESEBR} "Re-install AFS Server"
278 ReserveFile "CellServPage.ini"
279 ReserveFile "AFSCell.ini"
280 !insertmacro MUI_RESERVEFILE_INSTALLOPTIONS ;InstallOptions plug-in
281 !insertmacro MUI_RESERVEFILE_LANGDLL ;Language selection dialog
282 ;--------------------------------
285 !include "ServiceLib.nsh"
287 ; Macro - Upgrade DLL File
288 ; Written by Joost Verburg
289 ; ------------------------
292 ; LOCALFILE - Location of the new DLL file (on the compiler system)
293 ; DESTFILE - Location of the DLL file that should be upgraded
294 ; (on the user's system)
295 ; TEMPBASEDIR - Directory on the user's system to store a temporary file
296 ; when the system has to be rebooted.
297 ; For Win9x support, this should be on the same volume as the
299 ; The Windows temp directory could be located on any volume,
300 ; so you cannot use this directory.
302 ; Define UPGRADEDLL_NOREGISTER if you want to upgrade a DLL that does not
303 ; have to be registered.
305 ; Note: If you want to support Win9x, you can only use
306 ; short filenames (8.3).
309 ; !insertmacro UpgradeDLL "dllname.dll" "$SYSDIR\dllname.dll" "$SYSDIR"
312 !macro UpgradeDLL LOCALFILE DESTFILE TEMPBASEDIR
321 ;------------------------
322 ;Unique number for labels
324 !define UPGRADEDLL_UNIQUE ${__LINE__}
326 ;------------------------
327 ;Copy the parameters used on run-time to a variable
328 ;This allows the usage of variables as paramter
330 StrCpy $R4 "${DESTFILE}"
331 StrCpy $R5 "${TEMPBASEDIR}"
333 ;------------------------
334 ;Check file and version
336 IfFileExists $R4 0 upgradedll.copy_${UPGRADEDLL_UNIQUE}
339 GetDLLVersionLocal "${LOCALFILE}" $R0 $R1
340 GetDLLVersion $R4 $R2 $R3
341 IfErrors upgradedll.upgrade_${UPGRADEDLL_UNIQUE}
343 IntCmpU $R0 $R2 0 upgradedll.done_${UPGRADEDLL_UNIQUE} \
344 upgradedll.upgrade_${UPGRADEDLL_UNIQUE}
345 IntCmpU $R1 $R3 upgradedll.done_${UPGRADEDLL_UNIQUE} \
346 upgradedll.done_${UPGRADEDLL_UNIQUE} \
347 upgradedll.upgrade_${UPGRADEDLL_UNIQUE}
349 ;------------------------
350 ;Let's upgrade the DLL!
354 upgradedll.upgrade_${UPGRADEDLL_UNIQUE}:
355 !ifndef UPGRADEDLL_NOREGISTER
360 ;------------------------
361 ;Try to copy the DLL directly
365 Call :upgradedll.file_${UPGRADEDLL_UNIQUE}
366 IfErrors 0 upgradedll.noreboot_${UPGRADEDLL_UNIQUE}
368 ;------------------------
369 ;DLL is in use. Copy it to a temp file and Rename it on reboot.
371 GetTempFileName $R0 $R5
372 Call :upgradedll.file_${UPGRADEDLL_UNIQUE}
373 Rename /REBOOTOK $R0 $R4
375 ;------------------------
376 ;Register the DLL on reboot
378 !ifndef UPGRADEDLL_NOREGISTER
379 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\RunOnce" \
380 "Register $R4" 'rundll32.exe "$R4",DllRegisterServer'
383 Goto upgradedll.done_${UPGRADEDLL_UNIQUE}
385 ;------------------------
386 ;DLL does not exist - just extract
388 upgradedll.copy_${UPGRADEDLL_UNIQUE}:
390 Call :upgradedll.file_${UPGRADEDLL_UNIQUE}
392 ;------------------------
395 upgradedll.noreboot_${UPGRADEDLL_UNIQUE}:
396 !ifndef UPGRADEDLL_NOREGISTER
400 ;------------------------
403 upgradedll.done_${UPGRADEDLL_UNIQUE}:
412 ;------------------------
415 Goto upgradedll.end_${UPGRADEDLL_UNIQUE}
417 ;------------------------
418 ;Called to extract the DLL
420 upgradedll.file_${UPGRADEDLL_UNIQUE}:
421 File /oname=$R0 "${LOCALFILE}"
424 upgradedll.end_${UPGRADEDLL_UNIQUE}:
426 ;------------------------
429 SetOverwrite lastused
431 !undef UPGRADEDLL_UNIQUE
436 ;--------------------------------
439 ;Things that need to be extracted on first (keep these lines before any File command!)
440 ;Only useful for BZIP2 compression
441 !insertmacro MUI_RESERVEFILE_LANGDLL
443 ;--------------------------------
453 ;--------------------------------
456 ;----------------------
458 Section "AFS Client" secClient
460 SetShellVarContext all
462 ; Check for bad previous installation (if we are doing a new install)
463 Call IsAnyAFSInstalled
465 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 afscreds.exe'
473 Exec "afscreds.exe -z"
474 ; 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 !insertmacro SERVICE "stop" "TransarcAFSDaemon" ""
482 !insertmacro SERVICE "stop" "TransarcAFSServer" ""
484 ; Do client components
485 SetOutPath "$INSTDIR\Client\Program"
486 File "${AFS_CLIENT_BUILDDIR}\afsshare.exe"
487 !define UPGRADEDLL_NOREGISTER
488 !insertmacro UpgradeDLL "${AFS_CLIENT_BUILDDIR}\libosi.dll" "$INSTDIR\Client\Program\libosi.dll" "$INSTDIR"
489 !insertmacro UpgradeDLL "${AFS_CLIENT_BUILDDIR}\libafsconf.dll" "$INSTDIR\Client\Program\libafsconf.dll" "$INSTDIR"
490 File "${AFS_CLIENT_BUILDDIR}\klog.exe"
491 File "${AFS_CLIENT_BUILDDIR}\tokens.exe"
492 File "${AFS_CLIENT_BUILDDIR}\unlog.exe"
493 File "${AFS_CLIENT_BUILDDIR}\fs.exe"
494 File "${AFS_CLIENT_BUILDDIR}\afscreds.exe"
495 !insertmacro UpgradeDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext.dll" "$INSTDIR\Client\Program\afs_shl_ext.dll" "$INSTDIR"
496 File "${AFS_BUILD_INCDIR}\afs\auth.h"
497 File "${AFS_CLIENT_BUILDDIR}\afsd_service.exe"
498 !insertmacro UpgradeDLL "${AFS_CLIENT_BUILDDIR}\afslogon.dll" "$INSTDIR\Client\Program\afslogon.dll" "$INSTDIR"
499 File "${AFS_CLIENT_BUILDDIR}\symlink.exe"
500 File "${AFS_DESTDIR}\bin\kpasswd.exe"
501 File "${AFS_SERVER_BUILDDIR}\pts.exe"
502 File "${AFS_SERVER_BUILDDIR}\bos.exe"
503 File "${AFS_SERVER_BUILDDIR}\kas.exe"
504 File "${AFS_SERVER_BUILDDIR}\vos.exe"
505 File "${AFS_SERVER_BUILDDIR}\udebug.exe"
506 File "${AFS_DESTDIR}\bin\translate_et.exe"
507 File "${AFS_DESTDIR}\etc\rxdebug.exe"
508 File "${AFS_DESTDIR}\etc\backup.exe"
511 File "${AFS_CLIENT_BUILDDIR}\afsshare.pdb"
512 File "${AFS_CLIENT_BUILDDIR}\libosi.pdb"
513 File "${AFS_CLIENT_BUILDDIR}\libafsconf.pdb"
514 File "${AFS_CLIENT_BUILDDIR}\klog.pdb"
515 File "${AFS_CLIENT_BUILDDIR}\tokens.pdb"
516 File "${AFS_CLIENT_BUILDDIR}\unlog.pdb"
517 File "${AFS_CLIENT_BUILDDIR}\fs.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_SERVER_BUILDDIR}\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 File "${AFS_CLIENT_BUILDDIR}\afs_cpa.cpl"
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 !insertmacro SERVICE "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 !insertmacro SERVICE "delete" "TransarcAFSDaemon" ""
634 nsExec::Exec '$INSTDIR\Common\Service.exe TransarcAFSDaemon "$INSTDIR\Client\Program\afsd_service.exe" "OpenAFS Client Service"'
635 ;insertmacro SERVICE "create" "TransarcAFSDaemon" "path=$INSTDIR\Client\Program\afsd_service.exe;autostart=1;interact=1;machine=;user=;password="
637 Delete "$INSTDIR\Common\service.exe"
640 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon" "" ""
641 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "ProviderPath" "$INSTDIR\Client\Program\afslogon.dll"
642 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "AuthentProviderPath" "$INSTDIR\Client\Program\afslogon.dll"
643 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "AuthentProviderPath" "$INSTDIR\Client\Program\afslogon.dll"
644 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "Class" 2
645 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"
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 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "NoFindLanaByName" 1
679 strcpy $REG_SUB_KEY "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider"
680 strcpy $REG_VALUE "DependOnGroup"
681 strcpy $REG_DATA_1 "PNP_TDI"
682 strcpy $REG_DATA_2 ""
683 strcpy $REG_DATA_3 ""
684 Call RegWriteMultiStr
685 strcpy $REG_SUB_KEY "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider"
686 strcpy $REG_VALUE "DependOnService"
687 strcpy $REG_DATA_1 "Tcpip"
688 strcpy $REG_DATA_2 "NETBIOS"
689 strcpy $REG_DATA_3 "RpcSs"
690 Call RegWriteMultiStr
694 WriteUninstaller "$INSTDIR\Uninstall.exe"
698 ;------------------------
700 Section "AFS Server" secServer
702 SetShellVarContext all
703 ; Stop any running services or we can't replace the files
704 ; Stop the running processes
706 File /oname=$R0 "${AFS_WININSTALL_DIR}\Killer.exe" ; Might not have the MSVCR71.DLL file to run
707 nsExec::Exec '$R0 afscreds.exe'
708 Exec "afscreds.exe -z"
709 ; in case we are upgrading an old version that does not support -z
711 nsExec::Exec '$R0 afscreds.exe'
713 ;nsExec::Exec '$R0 krbcc32s.exe'
716 nsExec::Exec "net stop TransarcAFSDaemon"
717 nsExec::Exec "net stop TransarcAFSServer"
719 CreateDirectory "$INSTDIR\Server\usr\afs\etc"
720 CreateDirectory "$INSTDIR\Server\usr\afs\local"
721 CreateDirectory "$INSTDIR\Server\usr\afs\etc\logs"
723 SetOutPath "$INSTDIR\Server\usr\afs\bin"
724 File "${AFS_SERVER_BUILDDIR}\afskill.exe"
725 File "${AFS_SERVER_BUILDDIR}\afssvrcfg.exe"
726 File "${AFS_SERVER_BUILDDIR}\bosctlsvc.exe"
727 File "${AFS_SERVER_BUILDDIR}\bosserver.exe"
728 File "${AFS_SERVER_BUILDDIR}\buserver.exe"
729 File "${AFS_ETC_BUILDDIR}\butc.exe"
730 File "${AFS_SERVER_BUILDDIR}\fileserver.exe"
731 File "${AFS_ETC_BUILDDIR}\fms.exe"
732 File "${AFS_SERVER_BUILDDIR}\kaserver.exe"
733 File "${AFS_SERVER_BUILDDIR}\ptserver.exe"
734 File "${AFS_SERVER_BUILDDIR}\salvager.exe"
735 File "${AFS_SERVER_BUILDDIR}\upclient.exe"
736 File "${AFS_SERVER_BUILDDIR}\upserver.exe"
737 File "${AFS_SERVER_BUILDDIR}\vlserver.exe"
738 File "${AFS_SERVER_BUILDDIR}\volinfo.exe"
739 File "${AFS_SERVER_BUILDDIR}\volserver.exe"
742 File "${AFS_SERVER_BUILDDIR}\afskill.pdb"
743 File "${AFS_SERVER_BUILDDIR}\afssvrcfg.pdb"
744 File "${AFS_SERVER_BUILDDIR}\bosctlsvc.pdb"
745 File "${AFS_SERVER_BUILDDIR}\bosserver.pdb"
746 File "${AFS_SERVER_BUILDDIR}\buserver.pdb"
747 File "${AFS_ETC_BUILDDIR}\butc.pdb"
748 File "${AFS_SERVER_BUILDDIR}\fileserver.pdb"
749 File "${AFS_ETC_BUILDDIR}\fms.pdb"
750 File "${AFS_SERVER_BUILDDIR}\kaserver.pdb"
751 File "${AFS_SERVER_BUILDDIR}\ptserver.pdb"
752 File "${AFS_SERVER_BUILDDIR}\salvager.pdb"
753 File "${AFS_SERVER_BUILDDIR}\upclient.pdb"
754 File "${AFS_SERVER_BUILDDIR}\upserver.pdb"
755 File "${AFS_SERVER_BUILDDIR}\vlserver.pdb"
756 File "${AFS_SERVER_BUILDDIR}\volinfo.pdb"
757 File "${AFS_SERVER_BUILDDIR}\volserver.pdb"
760 ;AFS Server common files
761 SetOutPath "$INSTDIR\Common"
762 File "${AFS_SERVER_BUILDDIR}\afsvosadmin.dll"
763 File "${AFS_SERVER_BUILDDIR}\afsbosadmin.dll"
764 File "${AFS_SERVER_BUILDDIR}\afscfgadmin.dll"
765 File "${AFS_SERVER_BUILDDIR}\afskasadmin.dll"
766 File "${AFS_SERVER_BUILDDIR}\afsptsadmin.dll"
769 File "${AFS_SERVER_BUILDDIR}\afsvosadmin.pdb"
770 File "${AFS_SERVER_BUILDDIR}\afsbosadmin.pdb"
771 File "${AFS_SERVER_BUILDDIR}\afscfgadmin.pdb"
772 File "${AFS_SERVER_BUILDDIR}\afskasadmin.pdb"
773 File "${AFS_SERVER_BUILDDIR}\afsptsadmin.pdb"
775 SetOutPath "$INSTDIR\Common"
779 File "${AFS_SERVER_BUILDDIR}\afsserver.cpl"
782 File "${AFS_SERVER_BUILDDIR}\afsserver.pdb"
785 ;Store install folder
786 WriteRegStr HKCU "${AFS_REGKEY_ROOT}\AFS Server" "" $INSTDIR
788 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion"
789 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "VersionString" ${AFS_VERSION}
790 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "Title" "AFS Server"
791 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "Description" "AFS Server for Windows"
792 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "PathName" "$INSTDIR\Server"
793 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "Software Type" "File System"
794 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "MajorVersion" ${AFS_MAJORVERSION}
795 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "MinorVersion" ${AFS_MINORVERSION}
796 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "PatchLevel" ${AFS_PATCHLEVEL}
797 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "VersionString" ${AFS_VERSION}
798 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "Title" "AFS Server"
799 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "Description" "AFS Server for Windows"
800 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "Software Type" "File System"
801 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "PathName" "$INSTDIR\Server"
802 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "MajorVersion" ${AFS_MAJORVERSION}
803 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "MinorVersion" ${AFS_MINORVERSION}
804 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "PatchLevel" ${AFS_PATCHLEVEL}
806 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "Debug" 1
807 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "Debug" 1
809 ; Delete the DEBUG string
810 DeleteRegValue HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "Debug"
811 DeleteRegValue HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "Debug"
813 ; Install the service
814 SetOutPath "$INSTDIR\Common"
815 File "${AFS_WININSTALL_DIR}\Service.exe"
817 File "${AFS_WININSTALL_DIR}\Service.pdb"
819 ;Don't want to whack existing settings... Make users un-install and then re-install if they want that
820 !insertmacro SERVICE "delete" "TransarcAFSServer" ""
821 ;insertmacro SERVICE "create" "TransarcAFSServer" "path=$INSTDIR\Server\usr\afs\bin\bosctlsvc.exe;autostart=1"
822 nsExec::Exec '$INSTDIR\Common\service.exe TransarcAFSServer "$INSTDIR\Server\usr\afs\bin\bosctlsvc.exe" "OpenAFS AFS Server"'
823 Delete "$INSTDIR\Common\service.exe"
825 CreateDirectory "$SMPROGRAMS\OpenAFS\Server"
826 CreateShortCut "$SMPROGRAMS\OpenAFS\Server\Server Configuration.lnk" "$INSTDIR\Server\usr\afs\bin\afssvrcfg.exe"
828 ; Make the server config wizard auto-start on bootup
829 WriteRegStr HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce" "AFS Server Wizard" '"$INSTDIR\Server\usr\afs\bin\afssvrcfg.exe" /wizard"'
831 WriteUninstaller "$INSTDIR\Uninstall.exe"
836 ;----------------------------
837 ; OpenAFS Control Center
838 Section "AFS Control Center" secControl
840 SetShellVarContext all
842 SetOutPath "$INSTDIR\Control Center"
843 File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager.exe"
844 File "${AFS_SERVER_BUILDDIR}\TaAfsAdmSvr.exe"
845 File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager.exe"
848 File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager.pdb"
849 File "${AFS_SERVER_BUILDDIR}\TaAfsAdmSvr.pdb"
850 File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager.pdb"
853 ;AFS Server common files
854 Call AFSCommon.Install
856 SetOutPath "$INSTDIR\Common"
858 SetOutPath "$INSTDIR\Common"
861 File "${SYSTEMDIR}\msvcr71d.dll"
862 File "${SYSTEMDIR}\msvcr71d.pdb"
863 File "${SYSTEMDIR}\msvcp71d.dll"
864 File "${SYSTEMDIR}\msvcp71d.pdb"
865 File "${SYSTEMDIR}\mfc71d.dll"
866 File "${SYSTEMDIR}\mfc71d.pdb"
867 File "${SYSTEMDIR}\MFC71CHS.DLL"
868 File "${SYSTEMDIR}\MFC71CHT.DLL"
869 File "${SYSTEMDIR}\MFC71DEU.DLL"
870 File "${SYSTEMDIR}\MFC71ENU.DLL"
871 File "${SYSTEMDIR}\MFC71ESP.DLL"
872 File "${SYSTEMDIR}\MFC71FRA.DLL"
873 File "${SYSTEMDIR}\MFC71ITA.DLL"
874 File "${SYSTEMDIR}\MFC71JPN.DLL"
875 File "${SYSTEMDIR}\MFC71KOR.DLL"
878 File "${SYSTEMDIR}\msvcr70d.dll"
879 File "${SYSTEMDIR}\msvcr70d.pdb"
880 File "${SYSTEMDIR}\msvcp70d.dll"
881 File "${SYSTEMDIR}\msvcp70d.pdb"
882 File "${SYSTEMDIR}\mfc70d.dll"
883 File "${SYSTEMDIR}\mfc70d.pdb"
884 File "${SYSTEMDIR}\MFC70CHS.DLL"
885 File "${SYSTEMDIR}\MFC70CHT.DLL"
886 File "${SYSTEMDIR}\MFC70DEU.DLL"
887 File "${SYSTEMDIR}\MFC70ENU.DLL"
888 File "${SYSTEMDIR}\MFC70ESP.DLL"
889 File "${SYSTEMDIR}\MFC70FRA.DLL"
890 File "${SYSTEMDIR}\MFC70ITA.DLL"
891 File "${SYSTEMDIR}\MFC70JPN.DLL"
892 File "${SYSTEMDIR}\MFC70KOR.DLL"
894 File "${SYSTEMDIR}\mfc42d.dll"
895 File "${SYSTEMDIR}\mfc42d.pdb"
896 File "${SYSTEMDIR}\msvcp60d.dll"
897 File "${SYSTEMDIR}\msvcp60d.pdb"
898 File "${SYSTEMDIR}\msvcrtd.dll"
899 File "${SYSTEMDIR}\msvcrtd.pdb"
904 File "${SYSTEMDIR}\mfc71.dll"
905 File "${SYSTEMDIR}\msvcr71.dll"
906 File "${SYSTEMDIR}\msvcp71.dll"
907 File "${SYSTEMDIR}\MFC71CHS.DLL"
908 File "${SYSTEMDIR}\MFC71CHT.DLL"
909 File "${SYSTEMDIR}\MFC71DEU.DLL"
910 File "${SYSTEMDIR}\MFC71ENU.DLL"
911 File "${SYSTEMDIR}\MFC71ESP.DLL"
912 File "${SYSTEMDIR}\MFC71FRA.DLL"
913 File "${SYSTEMDIR}\MFC71ITA.DLL"
914 File "${SYSTEMDIR}\MFC71JPN.DLL"
915 File "${SYSTEMDIR}\MFC71KOR.DLL"
918 File "${SYSTEMDIR}\mfc70.dll"
919 File "${SYSTEMDIR}\msvcr70.dll"
920 File "${SYSTEMDIR}\msvcp70.dll"
921 File "${SYSTEMDIR}\MFC70CHS.DLL"
922 File "${SYSTEMDIR}\MFC70CHT.DLL"
923 File "${SYSTEMDIR}\MFC70DEU.DLL"
924 File "${SYSTEMDIR}\MFC70ENU.DLL"
925 File "${SYSTEMDIR}\MFC70ESP.DLL"
926 File "${SYSTEMDIR}\MFC70FRA.DLL"
927 File "${SYSTEMDIR}\MFC70ITA.DLL"
928 File "${SYSTEMDIR}\MFC70JPN.DLL"
929 File "${SYSTEMDIR}\MFC70KOR.DLL"
931 File "${SYSTEMDIR}\mfc42.dll"
932 File "${SYSTEMDIR}\msvcp60.dll"
933 File "${SYSTEMDIR}\msvcrt.dll"
937 ;Store install folder
938 WriteRegStr HKCU "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "PathName" $INSTDIR
939 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "VersionString" ${AFS_VERSION}
940 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "MajorVersion" ${AFS_MAJORVERSION}
941 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "MinorVersion" ${AFS_MINORVERSION}
942 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "PatchLevel" ${AFS_PATCHLEVEL}
943 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "VersionString" ${AFS_VERSION}
944 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "MajorVersion" ${AFS_MAJORVERSION}
945 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "MinorVersion" ${AFS_MINORVERSION}
946 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "PatchLevel" ${AFS_PATCHLEVEL}
948 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "Debug" 1
949 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "Debug" 1
951 ; Delete the DEBUG string
952 DeleteRegValue HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "Debug"
953 DeleteRegValue HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "Debug"
956 ;Write start menu entries
957 CreateDirectory "$SMPROGRAMS\OpenAFS\Control Center"
958 CreateShortCut "$SMPROGRAMS\OpenAFS\Control Center\Account Manager.lnk" "$INSTDIR\Control Center\TaAfsAccountManager.exe"
959 CreateShortCut "$SMPROGRAMS\OpenAFS\Control Center\Server Manager.lnk" "$INSTDIR\Control Center\TaAfsServerManager.exe"
961 WriteUninstaller "$INSTDIR\Uninstall.exe"
966 ;----------------------------
967 ; OpenAFS Supplemental Documentation
968 Section "Supplemental Documentation" secDocs
969 SetShellVarContext all
971 StrCmp $LANGUAGE ${LANG_ENGLISH} DoEnglish
972 StrCmp $LANGUAGE ${LANG_GERMAN} DoGerman
973 StrCmp $LANGUAGE ${LANG_SPANISH} DoSpanish
974 StrCmp $LANGUAGE ${LANG_JAPANESE} DoJapanese
975 StrCmp $LANGUAGE ${LANG_KOREAN} DoKorean
976 StrCmp $LANGUAGE ${LANG_PORTUGUESEBR} DoPortugueseBR
977 StrCmp $LANGUAGE ${LANG_SIMPCHINESE} DoSimpChinese
978 StrCmp $LANGUAGE ${LANG_TRADCHINESE} DoTradChinese
982 SetOutPath "$INSTDIR\Documentation\html"
983 File "..\..\doc\install\Documentation\en_US\html\*"
984 SetOutPath "$INSTDIR\Documentation\html\CmdRef"
985 File "..\..\doc\install\Documentation\en_US\html\CmdRef\*"
986 SetOutPath "$INSTDIR\Documentation\html\InstallGd"
987 File "..\..\doc\install\Documentation\en_US\html\InstallGd\*"
988 SetOutPath "$INSTDIR\Documentation\html\ReleaseNotes"
989 File "..\..\doc\install\Documentation\en_US\html\ReleaseNotes\*"
990 SetOutPath "$INSTDIR\Documentation\html\SysAdminGd"
991 File "..\..\doc\install\Documentation\en_US\html\SysAdminGd\*"
995 SetOutPath "$INSTDIR\Documentation"
996 File "..\..\doc\install\Documentation\de_DE\README.TXT"
997 SetOutPath "$INSTDIR\Documentation\html"
998 File "..\..\doc\install\Documentation\de_DE\html\*"
999 SetOutPath "$INSTDIR\Documentation\html\CmdRef"
1000 ;File "..\..\doc\install\Documentation\de_DE\html\CmdRef\*"
1001 SetOutPath "$INSTDIR\Documentation\html\InstallGd"
1002 File "..\..\doc\install\Documentation\de_DE\html\InstallGd\*"
1003 ;SetOutPath "$INSTDIR\Documentation\html\ReleaseNotes"
1004 ;File "..\..\doc\install\Documentation\de_DE\html\ReleaseNotes\*"
1005 ;SetOutPath "$INSTDIR\Documentation\html\SysAdminGd"
1006 ;File "..\..\doc\install\Documentation\de_DE\html\SysAdminGd\*"
1010 SetOutPath "$INSTDIR\Documentation"
1011 File "..\..\doc\install\Documentation\es_ES\README.TXT"
1012 SetOutPath "$INSTDIR\Documentation\html"
1013 File "..\..\doc\install\Documentation\es_ES\html\*"
1014 SetOutPath "$INSTDIR\Documentation\html\CmdRef"
1015 ;File "..\..\doc\install\Documentation\es_ES\html\CmdRef\*"
1016 SetOutPath "$INSTDIR\Documentation\html\InstallGd"
1017 ;File "..\..\doc\install\Documentation\es_ES\html\InstallGd\*"
1018 SetOutPath "$INSTDIR\Documentation\html\ReleaseNotes"
1019 ;File "..\..\doc\install\Documentation\es_ES\html\ReleaseNotes\*"
1020 SetOutPath "$INSTDIR\Documentation\html\SysAdminGd"
1021 ;File "..\..\doc\install\Documentation\es_ES\html\SysAdminGd\*"
1025 SetOutPath "$INSTDIR\Documentation"
1026 File "..\..\doc\install\Documentation\ja_JP\README.TXT"
1027 SetOutPath "$INSTDIR\Documentation\html"
1028 File "..\..\doc\install\Documentation\ja_JP\html\*"
1029 SetOutPath "$INSTDIR\Documentation\html\CmdRef"
1030 File "..\..\doc\install\Documentation\ja_JP\html\CmdRef\*"
1031 SetOutPath "$INSTDIR\Documentation\html\InstallGd"
1032 File "..\..\doc\install\Documentation\ja_JP\html\InstallGd\*"
1033 SetOutPath "$INSTDIR\Documentation\html\ReleaseNotes"
1034 ;File "..\..\doc\install\Documentation\ja_JP\html\ReleaseNotes\*"
1035 SetOutPath "$INSTDIR\Documentation\html\SysAdminGd"
1036 ;File "..\..\doc\install\Documentation\ja_JP\html\SysAdminGd\*"
1040 SetOutPath "$INSTDIR\Documentation"
1041 File "..\..\doc\install\Documentation\ko_KR\README.TXT"
1042 SetOutPath "$INSTDIR\Documentation\html"
1043 File "..\..\doc\install\Documentation\ko_KR\html\*"
1044 ;SetOutPath "$INSTDIR\Documentation\html\CmdRef"
1045 ;File "..\..\doc\install\Documentation\ko_KR\html\CmdRef\*"
1046 SetOutPath "$INSTDIR\Documentation\html\InstallGd"
1047 File "..\..\doc\install\Documentation\ko_KR\html\InstallGd\*"
1048 SetOutPath "$INSTDIR\Documentation\html\ReleaseNotes"
1049 File "..\..\doc\install\Documentation\ko_KR\html\ReleaseNotes\*"
1050 SetOutPath "$INSTDIR\Documentation\html\SysAdminGd"
1051 File "..\..\doc\install\Documentation\ko_KR\html\SysAdminGd\*"
1055 SetOutPath "$INSTDIR\Documentation"
1056 File "..\..\doc\install\Documentation\pt_BR\README.TXT"
1057 SetOutPath "$INSTDIR\Documentation\html"
1058 File "..\..\doc\install\Documentation\pt_BR\html\*"
1059 ;SetOutPath "$INSTDIR\Documentation\html\CmdRef"
1060 ;File "..\..\doc\install\Documentation\pt_BR\html\CmdRef\*"
1061 SetOutPath "$INSTDIR\Documentation\html\InstallGd"
1062 File "..\..\doc\install\Documentation\pt_BR\html\InstallGd\*"
1063 SetOutPath "$INSTDIR\Documentation\html\ReleaseNotes"
1064 File "..\..\doc\install\Documentation\pt_BR\html\ReleaseNotes\*"
1065 ;SetOutPath "$INSTDIR\Documentation\html\SysAdminGd"
1066 ;File "..\..\doc\install\Documentation\pt_BR\html\SysAdminGd\*"
1070 SetOutPath "$INSTDIR\Documentation"
1071 File "..\..\doc\install\Documentation\zh_CN\README.TXT"
1072 SetOutPath "$INSTDIR\Documentation\html"
1073 File "..\..\doc\install\Documentation\zh_CN\html\*"
1074 ;SetOutPath "$INSTDIR\Documentation\html\CmdRef"
1075 ;File "..\..\doc\install\Documentation\zh_CN\html\CmdRef\*"
1076 SetOutPath "$INSTDIR\Documentation\html\InstallGd"
1077 File "..\..\doc\install\Documentation\zh_CN\html\InstallGd\*"
1078 SetOutPath "$INSTDIR\Documentation\html\ReleaseNotes"
1079 File "..\..\doc\install\Documentation\zh_CN\html\ReleaseNotes\*"
1080 ;SetOutPath "$INSTDIR\Documentation\html\SysAdminGd"
1081 ;File "..\..\doc\install\Documentation\zh_CN\html\SysAdminGd\*"
1085 SetOutPath "$INSTDIR\Documentation"
1086 File "..\..\doc\install\Documentation\zh_TW\README.TXT"
1087 SetOutPath "$INSTDIR\Documentation\html"
1088 File "..\..\doc\install\Documentation\zh_TW\html\*"
1089 ;SetOutPath "$INSTDIR\Documentation\html\CmdRef"
1090 ;File "..\..\doc\install\Documentation\zh_TW\html\CmdRef\*"
1091 SetOutPath "$INSTDIR\Documentation\html\InstallGd"
1092 File "..\..\doc\install\Documentation\zh_TW\html\InstallGd\*"
1093 SetOutPath "$INSTDIR\Documentation\html\ReleaseNotes"
1094 File "..\..\doc\install\Documentation\zh_TW\html\ReleaseNotes\*"
1095 ;SetOutPath "$INSTDIR\Documentation\html\SysAdminGd"
1096 ;File "..\..\doc\install\Documentation\zh_TW\html\SysAdminGd\*"
1101 ;Store install folder
1102 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation" "" $INSTDIR
1103 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\CurrentVersion" "VersionString" ${AFS_VERSION}
1104 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\CurrentVersion" "MajorVersion" ${AFS_MAJORVERSION}
1105 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\CurrentVersion" "MinorVersion" ${AFS_MINORVERSION}
1106 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\CurrentVersion" "PatchLevel" ${AFS_PATCHLEVEL}
1107 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\${AFS_VERSION}" "VersionString" ${AFS_VERSION}
1108 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\${AFS_VERSION}" "MajorVersion" ${AFS_MAJORVERSION}
1109 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\${AFS_VERSION}" "MinorVersion" ${AFS_MINORVERSION}
1110 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\${AFS_VERSION}" "PatchLevel" ${AFS_PATCHLEVEL}
1112 ; Write start menu shortcut
1113 SetOutPath "$SMPROGRAMS\OpenAFS"
1114 CreateShortCut "$SMPROGRAMS\OpenAFS\Documentation.lnk" "$INSTDIR\Documentation\html\index.htm"
1117 WriteUninstaller "$INSTDIR\Uninstall.exe"
1118 CreateShortCut "$SMPROGRAMS\OpenAFS\Uninstall OpenAFS.lnk" "$INSTDIR\Uninstall.exe"
1119 Call AFSCommon.Install
1123 Section "Software Development Kit (SDK)" secSDK
1125 SetOutPath "$INSTDIR\Client\Program"
1127 File "${AFS_BUILD_INCDIR}\afs\cm_config.h"
1128 File "${AFS_BUILD_INCDIR}\afs\kautils.h"
1129 File "${AFS_CLIENT_LIBDIR}\libafsconf.lib"
1130 File "${AFS_CLIENT_LIBDIR}\afsauthent.lib"
1133 SetOutPath "$INSTDIR\Client\Program\Include"
1134 File "${AFS_BUILD_INCDIR}\lock.h"
1135 File "${AFS_BUILD_INCDIR}\lwp.h"
1136 File "${AFS_BUILD_INCDIR}\preempt.h"
1137 File "${AFS_BUILD_INCDIR}\timer.h"
1138 File "${AFS_BUILD_INCDIR}\des.h"
1139 File "${AFS_BUILD_INCDIR}\des_conf.h"
1140 File "${AFS_BUILD_INCDIR}\mit-cpyright.h"
1141 ;File "${AFS_BUILD_INCDIR}\des-odd.h"
1142 File "${AFS_BUILD_INCDIR}\crypt.h"
1143 File "${AFS_BUILD_INCDIR}\pthread.h"
1144 File "${AFS_BUILD_INCDIR}\dbrpc.h"
1145 File "${AFS_BUILD_INCDIR}\basic.h"
1146 File "${AFS_BUILD_INCDIR}\osidebug.h"
1147 File "${AFS_BUILD_INCDIR}\osiltype.h"
1148 File "${AFS_BUILD_INCDIR}\osistatl.h"
1149 File "${AFS_BUILD_INCDIR}\trylock.h"
1150 File "${AFS_BUILD_INCDIR}\main.h"
1151 File "${AFS_BUILD_INCDIR}\osibasel.h"
1152 File "${AFS_BUILD_INCDIR}\osifd.h"
1153 File "${AFS_BUILD_INCDIR}\osiqueue.h"
1154 File "${AFS_BUILD_INCDIR}\osiutils.h"
1155 File "${AFS_BUILD_INCDIR}\osi.h"
1156 File "${AFS_BUILD_INCDIR}\osidb.h"
1157 File "${AFS_BUILD_INCDIR}\osilog.h"
1158 File "${AFS_BUILD_INCDIR}\osisleep.h"
1159 File "${AFS_BUILD_INCDIR}\perf.h"
1160 File "${AFS_BUILD_INCDIR}\ubik.h"
1161 File "${AFS_BUILD_INCDIR}\ubik_int.h"
1165 SetOutPath "$INSTDIR\Client\Program\Include\afs"
1166 File "${AFS_BUILD_INCDIR}\afs\afs_args.h"
1167 File "${AFS_BUILD_INCDIR}\afs\debug.h"
1168 File "${AFS_BUILD_INCDIR}\afs\param.h"
1169 File "${AFS_BUILD_INCDIR}\afs\afs_sysnames.h"
1170 ;File "${AFS_BUILD_INCDIR}\afs\permit_xprt.h"
1171 File "${AFS_BUILD_INCDIR}\afs\stds.h"
1172 File "${AFS_BUILD_INCDIR}\afs\icl.h"
1173 File "${AFS_BUILD_INCDIR}\afs\procmgmt.h"
1174 File "${AFS_BUILD_INCDIR}\afs\afsutil.h"
1175 File "${AFS_BUILD_INCDIR}\afs\assert.h"
1176 File "${AFS_BUILD_INCDIR}\afs\dirent.h"
1177 File "${AFS_BUILD_INCDIR}\afs\errors.h"
1178 File "${AFS_BUILD_INCDIR}\afs\itc.h"
1179 File "${AFS_BUILD_INCDIR}\afs\vice.h"
1180 File "${AFS_BUILD_INCDIR}\afs\pthread_glock.h"
1181 File "${AFS_BUILD_INCDIR}\afs\errmap_nt.h"
1182 File "${AFS_BUILD_INCDIR}\afs\dirpath.h"
1183 File "${AFS_BUILD_INCDIR}\afs\ktime.h"
1184 File "${AFS_BUILD_INCDIR}\afs\fileutil.h"
1185 File "${AFS_BUILD_INCDIR}\afs\secutil_nt.h"
1186 File "${AFS_BUILD_INCDIR}\afs\com_err.h"
1187 File "${AFS_BUILD_INCDIR}\afs\error_table.h"
1188 ;File "${AFS_BUILD_INCDIR}\afs\mit_sipb-cr.h"
1189 File "${AFS_BUILD_INCDIR}\afs\cmd.h"
1190 File "${AFS_BUILD_INCDIR}\afs\rxgen_consts.h"
1191 File "${AFS_BUILD_INCDIR}\afs\afsint.h"
1192 File "${AFS_BUILD_INCDIR}\afs\afscbint.h"
1193 File "${AFS_BUILD_INCDIR}\afs\audit.h"
1194 File "${AFS_BUILD_INCDIR}\afs\acl.h"
1195 File "${AFS_BUILD_INCDIR}\afs\prs_fs.h"
1196 File "${AFS_BUILD_INCDIR}\afs\afsd.h"
1197 File "${AFS_BUILD_INCDIR}\afs\cm.h"
1198 File "${AFS_BUILD_INCDIR}\afs\cm_buf.h"
1199 File "${AFS_BUILD_INCDIR}\afs\cm_cell.h"
1200 File "${AFS_BUILD_INCDIR}\afs\cm_config.h"
1201 File "${AFS_BUILD_INCDIR}\afs\cm_conn.h"
1202 File "${AFS_BUILD_INCDIR}\afs\cm_ioctl.h"
1203 File "${AFS_BUILD_INCDIR}\afs\cm_scache.h"
1204 File "${AFS_BUILD_INCDIR}\afs\cm_server.h"
1205 File "${AFS_BUILD_INCDIR}\afs\cm_user.h"
1206 File "${AFS_BUILD_INCDIR}\afs\cm_utils.h"
1207 File "${AFS_BUILD_INCDIR}\afs\fs_utils.h"
1208 File "${AFS_BUILD_INCDIR}\afs\krb.h"
1209 File "${AFS_BUILD_INCDIR}\afs\krb_prot.h"
1210 File "${AFS_BUILD_INCDIR}\afs\smb.h"
1211 File "${AFS_BUILD_INCDIR}\afs\smb3.h"
1212 File "${AFS_BUILD_INCDIR}\afs\smb_iocons.h"
1213 File "${AFS_BUILD_INCDIR}\afs\smb_ioctl.h"
1214 File "${AFS_BUILD_INCDIR}\afs\afsrpc.h"
1215 File "${AFS_BUILD_INCDIR}\afs\afssyscalls.h"
1216 File "${AFS_BUILD_INCDIR}\afs\pioctl_nt.h"
1217 File "${AFS_BUILD_INCDIR}\afs\auth.h"
1218 File "${AFS_BUILD_INCDIR}\afs\cellconfig.h"
1219 File "${AFS_BUILD_INCDIR}\afs\keys.h"
1220 File "${AFS_BUILD_INCDIR}\afs\ptserver.h"
1221 File "${AFS_BUILD_INCDIR}\afs\ptint.h"
1222 File "${AFS_BUILD_INCDIR}\afs\pterror.h"
1223 File "${AFS_BUILD_INCDIR}\afs\ptint.h"
1224 File "${AFS_BUILD_INCDIR}\afs\pterror.h"
1225 File "${AFS_BUILD_INCDIR}\afs\ptclient.h"
1226 File "${AFS_BUILD_INCDIR}\afs\prserver.h"
1227 File "${AFS_BUILD_INCDIR}\afs\print.h"
1228 File "${AFS_BUILD_INCDIR}\afs\prerror.h"
1229 File "${AFS_BUILD_INCDIR}\afs\prclient.h"
1230 File "${AFS_BUILD_INCDIR}\afs\kautils.h"
1231 File "${AFS_BUILD_INCDIR}\afs\kauth.h"
1232 File "${AFS_BUILD_INCDIR}\afs\kaport.h"
1233 File "${AFS_BUILD_INCDIR}\afs\vl_opcodes.h"
1234 File "${AFS_BUILD_INCDIR}\afs\vlserver.h"
1235 File "${AFS_BUILD_INCDIR}\afs\vldbint.h"
1236 File "${AFS_BUILD_INCDIR}\afs\usd.h"
1237 File "${AFS_BUILD_INCDIR}\afs\bubasics.h"
1238 File "${AFS_BUILD_INCDIR}\afs\butc.h"
1239 File "${AFS_BUILD_INCDIR}\afs\bumon.h"
1240 File "${AFS_BUILD_INCDIR}\afs\butm.h"
1241 File "${AFS_BUILD_INCDIR}\afs\tcdata.h"
1242 File "${AFS_BUILD_INCDIR}\afs\budb.h"
1243 ;File "${AFS_BUILD_INCDIR}\afs\budb_errors.h"
1244 File "${AFS_BUILD_INCDIR}\afs\budb_client.h"
1245 File "${AFS_BUILD_INCDIR}\afs\dir.h"
1246 File "${AFS_BUILD_INCDIR}\afs\fssync.h"
1247 File "${AFS_BUILD_INCDIR}\afs\ihandle.h"
1248 File "${AFS_BUILD_INCDIR}\afs\nfs.h"
1249 File "${AFS_BUILD_INCDIR}\afs\ntops.h"
1250 File "${AFS_BUILD_INCDIR}\afs\partition.h"
1251 File "${AFS_BUILD_INCDIR}\afs\viceinode.h"
1252 File "${AFS_BUILD_INCDIR}\afs\vnode.h"
1253 File "${AFS_BUILD_INCDIR}\afs\volume.h"
1254 File "${AFS_BUILD_INCDIR}\afs\voldefs.h"
1255 File "${AFS_BUILD_INCDIR}\afs\volser.h"
1256 File "${AFS_BUILD_INCDIR}\afs\volint.h"
1257 File "${AFS_BUILD_INCDIR}\afs\fs_stats.h"
1258 File "${AFS_BUILD_INCDIR}\afs\bosint.h"
1259 File "${AFS_BUILD_INCDIR}\afs\bnode.h"
1262 SetOutPath "$INSTDIR\Client\Program\Include\rx"
1263 File "${AFS_BUILD_INCDIR}\rx\rx.h"
1264 File "${AFS_BUILD_INCDIR}\rx\rx_packet.h"
1265 File "${AFS_BUILD_INCDIR}\rx\rx_user.h"
1266 File "${AFS_BUILD_INCDIR}\rx\rx_event.h"
1267 File "${AFS_BUILD_INCDIR}\rx\rx_queue.h"
1268 File "${AFS_BUILD_INCDIR}\rx\rx_globals.h"
1269 File "${AFS_BUILD_INCDIR}\rx\rx_clock.h"
1270 File "${AFS_BUILD_INCDIR}\rx\rx_misc.h"
1271 File "${AFS_BUILD_INCDIR}\rx\rx_multi.h"
1272 File "${AFS_BUILD_INCDIR}\rx\rx_null.h"
1273 File "${AFS_BUILD_INCDIR}\rx\rx_lwp.h"
1274 File "${AFS_BUILD_INCDIR}\rx\rx_pthread.h"
1275 File "${AFS_BUILD_INCDIR}\rx\rx_xmit_nt.h"
1276 File "${AFS_BUILD_INCDIR}\rx\xdr.h"
1277 File "${AFS_BUILD_INCDIR}\rx\rxkad.h"
1282 SetOutPath "$INSTDIR\Client\Program\Sample"
1283 File "..\..\afsd\sample\token.c"
1285 ;Store install folder
1286 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS SDK" "" $INSTDIR
1287 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS SDK\CurrentVersion" "VersionString" ${AFS_VERSION}
1288 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\CurrentVersion" "MajorVersion" ${AFS_MAJORVERSION}
1289 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\CurrentVersion" "MinorVersion" ${AFS_MINORVERSION}
1290 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\CurrentVersion" "PatchLevel" ${AFS_PATCHLEVEL}
1291 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS SDK\${AFS_VERSION}" "VersionString" ${AFS_VERSION}
1292 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\${AFS_VERSION}" "MajorVersion" ${AFS_MAJORVERSION}
1293 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\${AFS_VERSION}" "MinorVersion" ${AFS_MINORVERSION}
1294 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\${AFS_VERSION}" "PatchLevel" ${AFS_PATCHLEVEL}
1296 WriteUninstaller "$INSTDIR\Uninstall.exe"
1297 SetOutPath "$SMPROGRAMS\OpenAFS"
1298 CreateShortCut "$SMPROGRAMS\OpenAFS\Uninstall OpenAFS.lnk" "$INSTDIR\Uninstall.exe"
1300 Call AFSCommon.Install
1303 ;Display the Finish header
1304 ;Insert this macro after the sections if you are not using a finish page
1305 ;!insertmacro MUI_SECTIONS_FINISHHEADER
1307 ;--------------------------------
1308 ;Installer Functions
1312 !insertmacro MUI_LANGDLL_DISPLAY
1314 ; Set the default install options
1319 StrCmp $R0 "true" contInstall
1321 MessageBox MB_OK|MB_ICONSTOP|MB_TOPMOST "You must be an administrator of this machine to install this software."
1325 ; Our logic should be like this.
1326 ; 1) If no AFS components are installed, we do a clean install with default options. (Client/Docs)
1327 ; 2) If existing modules are installed, we keep them selected
1328 ; 3) If it is an upgrade, we set the text accordingly, else we mark it as a re-install
1330 Call IsAnyAFSInstalled
1332 StrCmp $R0 "0" DefaultOptions
1334 Call ShouldClientInstall
1337 ; Check if it was an IBM/Transarc version
1338 ReadRegStr $R0 HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon" "DisplayName"
1339 StrCmp $R0 "IBM AFS Client" DoIBM
1340 StrCmp $R0 "Transarc AFS Client" DoIBM
1343 StrCmp $R2 "0" NoClient
1344 StrCmp $R2 "1" ReinstallClient
1345 StrCmp $R2 "2" UpgradeClient
1346 StrCmp $R2 "3" DowngradeClient
1349 ReadRegDWORD $R0 HKLM "Software\TransarcCorporation\AFS Client\CurrentVersion" "MajorVersion"
1350 StrCmp $R0 "3" +1 NotIBM
1355 SectionGetFlags ${secClient} $0
1356 IntOp $0 $0 | ${SF_SELECTED}
1357 SectionSetFlags ${secClient} $0
1358 ;# !insertmacro SelectSection ${secClient}
1361 ;StrCpy $1 ${secClient} ; Gotta remember which section we are at now...
1362 SectionGetFlags ${secClient} $0
1363 IntOp $0 $0 & ${SECTION_OFF}
1364 SectionSetFlags ${secClient} $0
1367 SectionGetFlags ${secClient} $0
1368 IntOp $0 $0 | ${SF_SELECTED}
1369 SectionSetFlags ${secClient} $0
1370 SectionSetText ${secClient} $(UPGRADE_CLIENT)
1373 SectionGetFlags ${secClient} $0
1374 IntOp $0 $0 | ${SF_SELECTED}
1375 SectionSetFlags ${secClient} $0
1376 SectionSetText ${secClient} $(REINSTALL_CLIENT)
1379 SectionGetFlags ${secClient} $0
1380 IntOp $0 $0 | ${SF_SELECTED}
1381 SectionSetFlags ${secClient} $0
1382 SectionSetText ${secClient} $(REINSTALL_CLIENT)
1388 Call ShouldServerInstall
1390 StrCmp $R2 "0" NoServer
1391 StrCmp $R2 "1" ReinstallServer
1392 StrCmp $R2 "2" UpgradeServer
1393 StrCmp $R2 "3" DowngradeServer
1395 SectionGetFlags ${secServer} $0
1396 IntOp $0 $0 | ${SF_SELECTED}
1397 SectionSetFlags ${secServer} $0
1398 ;# !insertmacro UnselectSection ${secServer}
1402 SectionGetFlags ${secServer} $0
1403 IntOp $0 $0 | ${SF_SELECTED}
1404 SectionSetFlags ${secServer} $0
1405 SectionSetText ${secServer} $(UPGRADE_SERVER)
1409 SectionGetFlags ${secServer} $0
1410 IntOp $0 $0 | ${SF_SELECTED}
1411 SectionSetFlags ${secServer} $0
1412 SectionSetText ${secServer} $(REINSTALL_SERVER)
1416 SectionGetFlags ${secServer} $0
1417 IntOp $0 $0 | ${SF_SELECTED}
1418 SectionSetFlags ${secServer} $0
1419 SectionSetText ${secServer} $(REINSTALL_SERVER)
1423 SectionGetFlags ${secServer} $0
1424 IntOp $0 $0 & ${SECTION_OFF}
1425 SectionSetFlags ${secServer} $0
1426 ;# !insertmacro UnselectSection ${secServer}
1430 ; Check control center
1431 Call IsControlInstalled
1433 StrCmp $R2 "0" NoControl
1435 SectionGetFlags ${secControl} $0
1436 IntOp $0 $0 | ${SF_SELECTED}
1437 SectionSetFlags ${secControl} $0
1441 SectionGetFlags ${secControl} $0
1442 IntOp $0 $0 & ${SECTION_OFF}
1443 SectionSetFlags ${secControl} $0
1444 ;# !insertmacro UnselectSection ${secControl}
1447 ; Check Documentation
1448 Call IsDocumentationInstalled
1450 StrCmp $R2 "0" NoDocs
1451 SectionGetFlags ${secDocs} $0
1452 IntOp $0 $0 | ${SF_SELECTED}
1453 SectionSetFlags ${secDocs} $0
1457 SectionGetFlags ${secDocs} $0
1458 IntOp $0 $0 & ${SECTION_OFF}
1459 SectionSetFlags ${secDocs} $0
1462 ; To check the SDK, we simply look to see if the files exist. If they do,
1463 ; the SDK is installed. If not, we don't need to push it on the user.
1464 ; If they are there, we want to make sure they match the installed version.
1466 IfFileExists "$INSTDIR\Client\Program\Include\main.h" +1 NoSDK
1467 SectionGetFlags ${secSDK} $0
1468 IntOp $0 $0 | ${SF_SELECTED}
1469 SectionSetFlags ${secSDK} $0
1473 SectionGetFlags ${secSDK} $0
1474 IntOp $0 $0 & ${SECTION_OFF}
1475 SectionSetFlags ${secSDK} $0
1480 SectionGetFlags ${secClient} $0
1481 IntOp $0 $0 | ${SF_SELECTED}
1482 SectionSetFlags ${secClient} $0
1484 ; Server NOT selected
1485 SectionGetFlags ${secServer} $0
1486 IntOp $0 $0 & ${SECTION_OFF}
1487 SectionSetFlags ${secServer} $0
1489 ; Control Center NOT selected
1490 SectionGetFlags ${secControl} $0
1491 IntOp $0 $0 & ${SECTION_OFF}
1492 SectionSetFlags ${secControl} $0
1493 ;# !insertmacro UnselectSection ${secControl}
1495 ; Documentation selected
1496 SectionGetFlags ${secDocs} $0
1497 IntOp $0 $0 | ${SF_SELECTED}
1498 SectionSetFlags ${secDocs} $0
1499 ;# !insertmacro UnselectSection ${secDocs}
1502 SectionGetFlags ${secSDK} $0
1503 IntOp $0 $0 & ${SECTION_OFF}
1504 SectionSetFlags ${secSDK} $0
1505 ;# !insertmacro UnselectSection ${secSDK}
1514 ; See if we can set a default installation path...
1515 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "PathName"
1516 StrCmp $R0 "" TryServer
1520 ; Work around bug in 1.3.5000, 1.3.5100, 1.3.5200, 1.3.5201, 1.3.5299 installers...
1521 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "MajorVersion"
1522 StrCmp $R0 "1" +1 SkipParent
1523 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "MinorVersion"
1524 StrCmp $R0 "3" +1 SkipParent
1525 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "PatchLevel"
1526 StrCmp $R0 "5000" UpParent
1527 StrCmp $R0 "5100" UpParent
1528 StrCmp $R0 "5200" UpParent
1529 StrCmp $R0 "5201" UpParent
1530 StrCmp $R0 "5299" UpParent
1542 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "PathName"
1543 StrCmp $R0 "" TryControl
1551 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "PathName"
1559 File /oname=$0 CellServPage.ini
1561 File /oname=$1 AFSCell.ini
1562 ;File /oname=$1 ConfigURL.ini
1570 ;--------------------------------
1571 ; These are our cleanup functions
1572 Function .onInstFailed
1577 Function .onInstSuccess
1583 ;--------------------------------
1586 !insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
1587 !insertmacro MUI_DESCRIPTION_TEXT ${secServer} $(DESC_secServer)
1588 !insertmacro MUI_DESCRIPTION_TEXT ${secClient} $(DESC_secClient)
1589 !insertmacro MUI_DESCRIPTION_TEXT ${secControl} $(DESC_secControl)
1590 !insertmacro MUI_DESCRIPTION_TEXT ${secDocs} $(DESC_secDocs)
1591 !insertmacro MUI_DESCRIPTION_TEXT ${secSDK} $(DESC_secSDK)
1592 !insertmacro MUI_FUNCTION_DESCRIPTION_END
1594 ;--------------------------------
1595 ;Uninstaller Section
1598 ; Make sure the user REALLY wants to do this, unless they did a silent uninstall, in which case...let them!
1599 IfSilent StartRemove ; New in v2.0b4
1600 MessageBox MB_YESNO "Are you sure you want to remove OpenAFS from this machine?" IDYES StartRemove
1605 SetShellVarContext all
1606 ; Stop the running processes
1608 File /oname=$R0 "${AFS_WININSTALL_DIR}\Killer.exe"
1609 nsExec::Exec '$R0 afscreds.exe'
1610 nsExec::Exec "afscreds.exe -z"
1611 ; in case we are upgrading an old version that does not support -z
1613 nsExec::Exec '$R0 afscreds.exe'
1615 nsExec::Exec '$R0 krbcc32s.exe'
1618 ; Delete the AFS service
1619 ; New method for service manipulation
1622 !insertmacro SERVICE "stop" "TransarcAFSDaemon" ""
1623 !insertmacro SERVICE "stop" "TransarcAFSDaemon" ""
1624 !insertmacro SERVICE "delete" "TransarcAFSDaemon" ""
1625 !insertmacro SERVICE "delete" "TransarcAFSServer" ""
1627 Call un.RemoveProvider
1629 Push "$INSTDIR\Client\Program"
1630 Call un.RemoveFromPath
1631 Push "$INSTDIR\Common"
1632 Call un.RemoveFromPath
1634 Push "$INSTDIR\kfw\bin"
1635 Call un.RemoveFromPath
1638 ; Delete documentation
1639 Delete "$INSTDIR\Documentation\README.TXT"
1640 Delete "$INSTDIR\Documentation\html\*"
1641 Delete "$INSTDIR\Documentation\html\CmdRef\*"
1642 Delete "$INSTDIR\Documentation\html\InstallGd\*"
1643 Delete "$INSTDIR\Documentation\html\ReleaseNotes\*"
1644 Delete "$INSTDIR\Documentation\html\SysAdminGd\*"
1646 Delete /REBOOTOK "$INSTDIR\Common\afs_config.exe"
1647 Delete /REBOOTOK "$INSTDIR\Common\afs_shl_ext.dll"
1648 Delete /REBOOTOK "$INSTDIR\Common\afsadminutil.dll"
1649 Delete /REBOOTOK "$INSTDIR\Common\lib\afsauthent.dll"
1650 Delete /REBOOTOK "$INSTDIR\Common\lib\afspthread.dll"
1651 Delete /REBOOTOK "$INSTDIR\Common\lib\afsrpc.dll"
1652 Delete /REBOOTOK "$INSTDIR\Common\afsclientadmin.dll"
1653 Delete /REBOOTOK "$INSTDIR\Common\afsprocmgmt.dll"
1654 Delete /REBOOTOK "$INSTDIR\Common\afsvosadmin.dll"
1655 Delete /REBOOTOK "$INSTDIR\Common\TaAfsAppLib.dll"
1656 Delete /REBOOTOK "$INSTDIR\Common\afsvosadmin.dll"
1657 Delete /REBOOTOK "$INSTDIR\Common\afsbosadmin.dll"
1658 Delete /REBOOTOK "$INSTDIR\Common\afscfgadmin.dll"
1659 Delete /REBOOTOK "$INSTDIR\Common\afskasadmin.dll"
1660 Delete /REBOOTOK "$INSTDIR\Common\afsptsadmin.dll"
1663 Delete /REBOOTOK "$INSTDIR\Common\afs_config.pdb"
1664 Delete /REBOOTOK "$INSTDIR\Common\afs_shl_ext.pdb"
1665 Delete /REBOOTOK "$INSTDIR\Common\afsadminutil.pdb"
1666 Delete /REBOOTOK "$INSTDIR\Common\lib\afsauthent.pdb"
1667 Delete /REBOOTOK "$INSTDIR\Common\lib\afspthread.pdb"
1668 Delete /REBOOTOK "$INSTDIR\Common\lib\afsrpc.pdb"
1669 Delete /REBOOTOK "$INSTDIR\Common\afsclientadmin.pdb"
1670 Delete /REBOOTOK "$INSTDIR\Common\afsprocmgmt.pdb"
1671 Delete /REBOOTOK "$INSTDIR\Common\afsvosadmin.pdb"
1672 Delete /REBOOTOK "$INSTDIR\Common\TaAfsAppLib.pdb"
1673 Delete /REBOOTOK "$INSTDIR\Common\afsvosadmin.pdb"
1674 Delete /REBOOTOK "$INSTDIR\Common\afsbosadmin.pdb"
1675 Delete /REBOOTOK "$INSTDIR\Common\afscfgadmin.pdb"
1676 Delete /REBOOTOK "$INSTDIR\Common\afskasadmin.pdb"
1677 Delete /REBOOTOK "$INSTDIR\Common\afsptsadmin.pdb"
1680 File "${SYSTEMDIR}\msvcr71d.dll"
1681 File "${SYSTEMDIR}\msvcr71d.pdb"
1682 File "${SYSTEMDIR}\msvcp71d.dll"
1683 File "${SYSTEMDIR}\msvcp71d.pdb"
1684 File "${SYSTEMDIR}\mfc71d.dll"
1685 File "${SYSTEMDIR}\mfc71d.pdb"
1686 File "${SYSTEMDIR}\MFC71CHS.DLL"
1687 File "${SYSTEMDIR}\MFC71CHT.DLL"
1688 File "${SYSTEMDIR}\MFC71DEU.DLL"
1689 File "${SYSTEMDIR}\MFC71ENU.DLL"
1690 File "${SYSTEMDIR}\MFC71ESP.DLL"
1691 File "${SYSTEMDIR}\MFC71FRA.DLL"
1692 File "${SYSTEMDIR}\MFC71ITA.DLL"
1693 File "${SYSTEMDIR}\MFC71JPN.DLL"
1694 File "${SYSTEMDIR}\MFC71KOR.DLL"
1697 File "${SYSTEMDIR}\msvcr70d.dll"
1698 File "${SYSTEMDIR}\msvcr70d.pdb"
1699 File "${SYSTEMDIR}\msvcp70d.dll"
1700 File "${SYSTEMDIR}\msvcp70d.pdb"
1701 File "${SYSTEMDIR}\mfc70d.dll"
1702 File "${SYSTEMDIR}\mfc70d.pdb"
1703 File "${SYSTEMDIR}\MFC70CHS.DLL"
1704 File "${SYSTEMDIR}\MFC70CHT.DLL"
1705 File "${SYSTEMDIR}\MFC70DEU.DLL"
1706 File "${SYSTEMDIR}\MFC70ENU.DLL"
1707 File "${SYSTEMDIR}\MFC70ESP.DLL"
1708 File "${SYSTEMDIR}\MFC70FRA.DLL"
1709 File "${SYSTEMDIR}\MFC70ITA.DLL"
1710 File "${SYSTEMDIR}\MFC70JPN.DLL"
1711 File "${SYSTEMDIR}\MFC70KOR.DLL"
1713 File "${SYSTEMDIR}\mfc42d.dll"
1714 File "${SYSTEMDIR}\mfc42d.pdb"
1715 File "${SYSTEMDIR}\msvcp60d.dll"
1716 File "${SYSTEMDIR}\msvcp60d.pdb"
1717 File "${SYSTEMDIR}\msvcrtd.dll"
1718 File "${SYSTEMDIR}\msvcrtd.pdb"
1723 File "${SYSTEMDIR}\mfc71.dll"
1724 File "${SYSTEMDIR}\msvcr71.dll"
1725 File "${SYSTEMDIR}\msvcp71.dll"
1726 File "${SYSTEMDIR}\MFC71CHS.DLL"
1727 File "${SYSTEMDIR}\MFC71CHT.DLL"
1728 File "${SYSTEMDIR}\MFC71DEU.DLL"
1729 File "${SYSTEMDIR}\MFC71ENU.DLL"
1730 File "${SYSTEMDIR}\MFC71ESP.DLL"
1731 File "${SYSTEMDIR}\MFC71FRA.DLL"
1732 File "${SYSTEMDIR}\MFC71ITA.DLL"
1733 File "${SYSTEMDIR}\MFC71JPN.DLL"
1734 File "${SYSTEMDIR}\MFC71KOR.DLL"
1737 File "${SYSTEMDIR}\mfc70.dll"
1738 File "${SYSTEMDIR}\msvcr70.dll"
1739 File "${SYSTEMDIR}\msvcp70.dll"
1740 File "${SYSTEMDIR}\MFC70CHS.DLL"
1741 File "${SYSTEMDIR}\MFC70CHT.DLL"
1742 File "${SYSTEMDIR}\MFC70DEU.DLL"
1743 File "${SYSTEMDIR}\MFC70ENU.DLL"
1744 File "${SYSTEMDIR}\MFC70ESP.DLL"
1745 File "${SYSTEMDIR}\MFC70FRA.DLL"
1746 File "${SYSTEMDIR}\MFC70ITA.DLL"
1747 File "${SYSTEMDIR}\MFC70JPN.DLL"
1748 File "${SYSTEMDIR}\MFC70KOR.DLL"
1750 File "${SYSTEMDIR}\mfc42.dll"
1751 File "${SYSTEMDIR}\msvcp60.dll"
1752 File "${SYSTEMDIR}\msvcrt.dll"
1758 ; IfFileExists "$WINDIR\afsdcell.ini" CellExists SkipDelAsk
1760 MessageBox MB_YESNO "Would you like to keep your configuration files?" IDYES SkipDel
1762 Delete "$WINDIR\afsdcell.ini"
1764 Delete "$WINDIR\afsdsbmt.ini"
1765 ; Only remove krb5.ini if KfW was installed
1767 Delete "$WINDIR\krb5.ini"
1769 Delete "$WINDIR\afsdns.ini"
1770 Delete "$WINDIR\afs_freelance.ini"
1773 Delete "$WINDIR\afsd_init.log"
1774 Delete "$INSTDIR\Uninstall.exe"
1777 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\afskill.exe"
1778 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\afssvrcfg.exe"
1779 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\bosctlsvc.exe"
1780 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\bosserver.exe"
1781 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\buserver.exe"
1782 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\butc.exe"
1783 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\fileserver.exe"
1784 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\fms.exe"
1785 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\kaserver.exe"
1786 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\ptserver.exe"
1787 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\salvager.exe"
1788 Delete "$INSTDIR\Server\usr\afs\bin\ServerUninst.dll"
1789 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\upclient.exe"
1790 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\upserver.exe"
1791 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\vlserver.exe"
1792 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\volinfo.exe"
1793 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\volserver.exe"
1796 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\afskill.pdb"
1797 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\afssvrcfg.pdb"
1798 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\bosctlsvc.pdb"
1799 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\bosserver.pdb"
1800 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\buserver.pdb"
1801 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\butc.pdb"
1802 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\fileserver.pdb"
1803 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\fms.pdb"
1804 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\kaserver.pdb"
1805 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\ptserver.pdb"
1806 Delete "$INSTDIR\Server\usr\afs\bin\salvager.pdb"
1807 Delete "$INSTDIR\Server\usr\afs\bin\ServerUninst.pdb"
1808 Delete "$INSTDIR\Server\usr\afs\bin\upclient.pdb"
1809 Delete "$INSTDIR\Server\usr\afs\bin\upserver.pdb"
1810 Delete "$INSTDIR\Server\usr\afs\bin\vlserver.pdb"
1811 Delete "$INSTDIR\Server\usr\afs\bin\volinfo.pdb"
1812 Delete "$INSTDIR\Server\usr\afs\bin\volserver.pdb"
1815 RMDir /r "$INSTDIR\Server\usr\afs\bin"
1816 RmDir /r "$INSTDIR\Server\usr\afs\etc\logs"
1817 RmDir /r "$INSTDIR\Server\usr\afs\etc"
1818 RmDir /r "$INSTDIR\Server\usr\afs\local"
1819 RMDIR /r "$INSTDIR\Server\usr\afs\logs"
1821 Delete /REBOOTOK "$SYSDIR\afsserver.cpl"
1822 Delete /REBOOTOK "$SYSDIR\afs_cpa.cpl"
1825 Delete /REBOOTOK "$SYSDIR\afsserver.pdb"
1826 Delete /REBOOTOK "$SYSDIR\afs_cpa.pdb"
1829 RMDir /r "$INSTDIR\Documentation\html\CmdRef"
1830 RMDir /r "$INSTDIR\Documentation\html\InstallGd"
1831 RMDir /r "$INSTDIR\Documentation\html\ReleaseNotes"
1832 RMDir /r "$INSTDIR\Documentation\html\SysAdminGd"
1833 RMDIr /r "$INSTDIR\Documentation\html"
1835 RMDir "$INSTDIR\Documentation"
1836 ; Delete DOC short cut
1837 Delete /REBOOTOK "$INSTDIR\Client\Program\afscreds.exe"
1840 Delete /REBOOTOK "$INSTDIR\Client\Program\afscreds.pdb"
1843 Delete /REBOOTOK "$INSTDIR\Client\Program\*"
1844 Delete /REBOOTOK "$INSTDIR\Client\Program\Include\*"
1845 Delete /REBOOTOK "$INSTDIR\Client\Program\Include\afs\*"
1846 Delete /REBOOTOK "$INSTDIR\Client\Program\Include\rx\*"
1847 Delete /REBOOTOK "$INSTDIR\Client\Program\Sample\*"
1848 RMDir "$INSTDIR\Client\Program\Sample"
1849 RMDir "$INSTDIR\Client\Program\Include\afs"
1850 RMDir "$INSTDIR\Client\Program\Include\rx"
1851 RMDir "$INSTDIR\Client\Program\Include"
1852 RMDir "$INSTDIR\Client\Program"
1853 RMDir "$INSTDIR\Client"
1857 File "${SYSTEMDIR}\msvcr71d.dll"
1858 File "${SYSTEMDIR}\msvcr71d.pdb"
1859 File "${SYSTEMDIR}\msvcp71d.dll"
1860 File "${SYSTEMDIR}\msvcp71d.pdb"
1861 File "${SYSTEMDIR}\mfc71d.dll"
1862 File "${SYSTEMDIR}\mfc71d.pdb"
1863 File "${SYSTEMDIR}\MFC71CHS.DLL"
1864 File "${SYSTEMDIR}\MFC71CHT.DLL"
1865 File "${SYSTEMDIR}\MFC71DEU.DLL"
1866 File "${SYSTEMDIR}\MFC71ENU.DLL"
1867 File "${SYSTEMDIR}\MFC71ESP.DLL"
1868 File "${SYSTEMDIR}\MFC71FRA.DLL"
1869 File "${SYSTEMDIR}\MFC71ITA.DLL"
1870 File "${SYSTEMDIR}\MFC71JPN.DLL"
1871 File "${SYSTEMDIR}\MFC71KOR.DLL"
1874 File "${SYSTEMDIR}\msvcr70d.dll"
1875 File "${SYSTEMDIR}\msvcr70d.pdb"
1876 File "${SYSTEMDIR}\msvcp70d.dll"
1877 File "${SYSTEMDIR}\msvcp70d.pdb"
1878 File "${SYSTEMDIR}\mfc70d.dll"
1879 File "${SYSTEMDIR}\mfc70d.pdb"
1880 File "${SYSTEMDIR}\MFC70CHS.DLL"
1881 File "${SYSTEMDIR}\MFC70CHT.DLL"
1882 File "${SYSTEMDIR}\MFC70DEU.DLL"
1883 File "${SYSTEMDIR}\MFC70ENU.DLL"
1884 File "${SYSTEMDIR}\MFC70ESP.DLL"
1885 File "${SYSTEMDIR}\MFC70FRA.DLL"
1886 File "${SYSTEMDIR}\MFC70ITA.DLL"
1887 File "${SYSTEMDIR}\MFC70JPN.DLL"
1888 File "${SYSTEMDIR}\MFC70KOR.DLL"
1890 File "${SYSTEMDIR}\mfc42d.dll"
1891 File "${SYSTEMDIR}\mfc42d.pdb"
1892 File "${SYSTEMDIR}\msvcp60d.dll"
1893 File "${SYSTEMDIR}\msvcp60d.pdb"
1894 File "${SYSTEMDIR}\msvcrtd.dll"
1895 File "${SYSTEMDIR}\msvcrtd.pdb"
1900 File "${SYSTEMDIR}\mfc71.dll"
1901 File "${SYSTEMDIR}\msvcr71.dll"
1902 File "${SYSTEMDIR}\msvcp71.dll"
1903 File "${SYSTEMDIR}\MFC71CHS.DLL"
1904 File "${SYSTEMDIR}\MFC71CHT.DLL"
1905 File "${SYSTEMDIR}\MFC71DEU.DLL"
1906 File "${SYSTEMDIR}\MFC71ENU.DLL"
1907 File "${SYSTEMDIR}\MFC71ESP.DLL"
1908 File "${SYSTEMDIR}\MFC71FRA.DLL"
1909 File "${SYSTEMDIR}\MFC71ITA.DLL"
1910 File "${SYSTEMDIR}\MFC71JPN.DLL"
1911 File "${SYSTEMDIR}\MFC71KOR.DLL"
1914 File "${SYSTEMDIR}\mfc70.dll"
1915 File "${SYSTEMDIR}\msvcr70.dll"
1916 File "${SYSTEMDIR}\msvcp70.dll"
1917 File "${SYSTEMDIR}\MFC70CHS.DLL"
1918 File "${SYSTEMDIR}\MFC70CHT.DLL"
1919 File "${SYSTEMDIR}\MFC70DEU.DLL"
1920 File "${SYSTEMDIR}\MFC70ENU.DLL"
1921 File "${SYSTEMDIR}\MFC70ESP.DLL"
1922 File "${SYSTEMDIR}\MFC70FRA.DLL"
1923 File "${SYSTEMDIR}\MFC70ITA.DLL"
1924 File "${SYSTEMDIR}\MFC70JPN.DLL"
1925 File "${SYSTEMDIR}\MFC70KOR.DLL"
1927 File "${SYSTEMDIR}\mfc42.dll"
1928 File "${SYSTEMDIR}\msvcp60.dll"
1929 File "${SYSTEMDIR}\msvcrt.dll"
1933 Delete /REBOOTOK "$INSTDIR\Common\*"
1934 RMDir "$INSTDIR\Common"
1938 Delete /REBOOTOK "$INSTDIR\kfw\bin\*"
1939 RMDIR /r "$INSTDIR\kfw\bin"
1940 Delete /REBOOTOK "$INSTDIR\kfw\doc\*"
1941 RMDIR /r "$INSTDIR\kfw\doc"
1942 RMDIR /r "$INSTDIR\kfw"
1945 Delete "$SMPROGRAMS\OpenAFS\Documentation.lnk"
1947 ; Remove control center
1948 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsAccountManager.exe"
1949 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsAdmSvr.exe"
1950 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsServerManager.exe"
1951 Delete /REBOOTOK "$INSTDIR\Control Center\CCUninst.dll"
1953 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsAccountManager.pdb"
1954 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsAdmSvr.pdb"
1955 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsServerManager.pdb"
1957 RMDir "$INSTDIR\Control Center"
1959 Delete "$SMPROGRAMS\OpenAFS\Uninstall OpenAFS.lnk"
1960 Delete "$SMPROGRAMS\OpenAFS\Client\Authentication.lnk"
1961 Delete "$SMPROGRAMS\OpenAFS\Control Center\Account Manager.lnk"
1962 Delete "$SMPROGRAMS\OpenAFS\Control Center\Server Manager.lnk"
1963 RMDIR "$SMPROGRAMS\OpenAFS\Control Center"
1964 RMDir /r "$SMPROGRAMS\OpenAFS\Client"
1965 RMDir /r "$SMPROGRAMS\OpenAFS"
1966 Delete "$SMSTARTUP\AFS Credentials.lnk"
1968 ReadRegStr $R0 HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon" "CachePath"
1970 Delete "$R0\AFSCache"
1971 Delete "C:\AFSCache"
1973 DeleteRegKey HKCR "*\shellex\ContextMenuHandlers\AFS Client Shell Extension"
1974 DeleteRegKey HKCR "CLSID\{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}\InprocServer32"
1975 DeleteRegKey HKCR "CLSID\{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}"
1976 DeleteRegKey HKCR "FOLDER\shellex\ContextMenuHandlers\AFS Client Shell Extension"
1977 DeleteRegValue HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Shell Extensions\Approved" "{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}"
1979 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion"
1980 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Client"
1981 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\CurrentVersion"
1982 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation"
1983 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion"
1984 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Control Center"
1985 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion"
1986 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Server"
1987 DeleteRegKey /ifempty HKLM "${AFS_REGKEY_ROOT}"
1988 DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS"
1989 DeleteRegValue HKLM "SYSTEM\CurrentControlSet\Services\NetBT\Parameters" "SmbDeviceEnabled"
1995 ;--------------------------------
1996 ;Uninstaller Functions
2000 ;Get language from registry
2001 ReadRegStr $LANGUAGE HKCU "Software\OpenAFS\AFS" "Installer Language"
2005 Function un.onUninstSuccess
2007 MessageBox MB_OK "Please reboot your machine to complete uninstallation of the software"
2011 ;------------------------------
2012 ; Get the CellServDB file from the Internet
2014 Function afs.GetCellServDB
2016 ;Check if we should download CellServDB
2017 ReadINIStr $R0 $0 "Field 4" "State"
2018 StrCmp $R0 "1" DoDownload
2020 ;Do nothing if we're keeping the existing file
2021 ReadINIStr $R0 $0 "Field 2" "State"
2024 ReadINIStr $R0 $0 "Field 3" "State"
2025 StrCmp $R0 "1" UsePackaged
2027 ReadINIStr $R0 $0 "Field 6" "State"
2028 StrCmp $R0 "1" CheckOther
2030 ; If none of these, grab file from other location
2034 ReadINIStr $R0 $0 "Field 5" "State"
2035 NSISdl::download $R0 "$WINDIR\afsdcell.ini"
2036 Pop $R0 ;Get the return value
2037 StrCmp $R0 "success" +2
2038 MessageBox MB_OK|MB_ICONSTOP "Download failed: $R0"
2042 SetOutPath "$WINDIR"
2047 ReadINIStr $R0 $0 "Field 7" "State"
2049 CopyFiles $R0 "$WINDIR\afsdcell.ini"
2057 ;-------------------------------
2058 ;Do the page to get the CellServDB
2060 Function AFSPageGetCellServDB
2061 ; Skip this page if we are not installing the client
2062 SectionGetFlags ${secClient} $R0
2063 IntOp $R0 $R0 & ${SF_SELECTED}
2066 ; Set the install options here
2069 WriteINIStr $0 "Field 2" "Flags" "DISABLED"
2070 WriteINIStr $0 "Field 3" "State" "1"
2071 WriteINISTR $0 "Field 4" "State" "0"
2072 WriteINIStr $0 "Field 6" "State" "0"
2074 ; If there is an existing afsdcell.ini file, allow the user to choose it and make it default
2075 IfFileExists "$WINDIR\afsdcell.ini" +1 notpresent
2076 WriteINIStr $0 "Field 2" "Flags" "ENABLED"
2077 WriteINIStr $0 "Field 2" "State" "1"
2078 WriteINIStr $0 "Field 3" "State" "0"
2082 !insertmacro MUI_HEADER_TEXT "CellServDB Configuration" "Please choose a method for installing the CellServDB file:"
2083 InstallOptions::dialog $0
2085 StrCmp $R1 "cancel" exit
2086 StrCmp $R1 "back" done
2087 StrCmp $R1 "success" done
2091 ; Check that if a file is set, a valid filename is entered...
2092 ReadINIStr $R0 $0 "Field 6" "State"
2093 StrCmp $R0 "1" CheckFileName
2095 ;Check if a URL is specified, one *IS* specified
2096 ReadINIStr $R0 $0 "Field 4" "State"
2097 StrCmp $R0 "1" CheckURL Skip
2100 ReadINIStr $R0 $0 "Field 5" "State"
2101 StrCmp $R0 "" +1 Skip
2102 MessageBox MB_OK|MB_ICONSTOP $(URLError)
2103 WriteINIStr $0 "Field 4" "State" "0"
2107 ReadINIStr $R0 $0 "Field 7" "State"
2108 IfFileExists $R0 Skip
2110 MessageBox MB_OK|MB_ICONSTOP $(CellError)
2111 WriteINIStr $0 "Field 6" "State" "0"
2119 Function AFSPageGetCellName
2121 ; Skip this page if we are not installing the client
2122 SectionGetFlags ${secClient} $R0
2123 IntOp $R0 $R0 & ${SF_SELECTED}
2127 ; If this is a server install, we do NOT want to recommend the Freelance client
2128 ; And we do not need to ask for the cell name.
2129 SectionGetFlags ${secServer} $R1
2130 IntOp $R1 $R1 & ${SF_SELECTED}
2131 StrCmp $R1 "1" +1 NotServer
2132 WriteINIStr $1 "Field 6" "Text" "Enable AFS Freelance client (Not Recommended for servers)"
2133 WriteINIStr $1 "Field 5" "State" "0"
2134 WriteINIStr $1 "Field 1" "Flags" "DISABLED"
2135 WriteINIStr $1 "Field 2" "Flags" "DISABLED"
2138 WriteINIStr $1 "Field 6" "Text" "Enable AFS Freelance client (Recommended)"
2139 WriteINIStr $1 "Field 5" "State" "1"
2140 WriteINIStr $1 "Field 1" "Flags" ""
2141 WriteINIStr $1 "Field 2" "Flags" ""
2143 ; Get the current cell name, if any
2144 ReadRegStr $R1 HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "Cell"
2146 WriteINIStr $1 "Field 2" "State" $R1
2147 !insertmacro MUI_HEADER_TEXT "Client Cell Name Configuration" "Please enter the name for your default cell:"
2148 InstallOptions::dialog $1
2150 StrCmp $R1 "cancel" exit
2151 StrCmp $R1 "back" done
2152 StrCmp $R1 "success" done
2155 ReadINIStr $R0 $1 "Field 2" "State"
2156 StrCmp $R0 "" +1 good
2158 MessageBox MB_OK|MB_ICONSTOP $(CellNameError)
2164 ; Common install routines for each module
2165 Function AFSCommon.Install
2167 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "DisplayName" "OpenAFS for Windows"
2168 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "UninstallString" "$INSTDIR\uninstall.exe"
2170 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "DisplayVersion" "${AFS_VERSION}"
2172 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "DisplayVersion" "${AFS_VERSION} Checked/Debug"
2174 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "URLInfoAbout" "http://www.openafs.org/"
2179 ;-------------------
2180 ; Get the currently installed version and place it on the stack
2182 Function GetInstalledVersion
2187 ReadRegStr $R0 HKLM "Software\TransarcCorporation\$R2\CurrentVersion" "VersionString"
2188 StrCmp $R0 "" NotTransarc done
2192 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\$R2\CurrentVersion" "VersionString"
2201 ; Functions to get each component of the version number
2202 Function GetInstalledVersionMajor
2207 ReadRegDWORD $R0 HKLM "Software\TransarcCorporation\$R2\CurrentVersion" "MajorVersion"
2208 StrCmp $R0 "" NotTransarc done
2212 ReadRegDWORD $R0 HKLM "${AFS_REGKEY_ROOT}\$R2\CurrentVersion" "MajorVersion"
2221 Function GetInstalledVersionMinor
2226 ReadRegDWORD $R0 HKLM "Software\TransarcCorporation\$R2\CurrentVersion" "MinorVersion"
2227 StrCmp $R0 "" NotTransarc done
2231 ReadRegDWORD $R0 HKLM "${AFS_REGKEY_ROOT}\$R2\CurrentVersion" "MinorVersion"
2240 Function GetInstalledVersionPatch
2245 ReadRegDWORD $R0 HKLM "Software\TransarcCorporation\$R2\CurrentVersion" "PatchLevel"
2246 StrCmp $R0 "" NotTransarc done
2250 ReadRegDWORD $R0 HKLM "${AFS_REGKEY_ROOT}\$R2\CurrentVersion" "PatchLevel"
2261 ;-------------------------------
2262 ; Check if the client should be checked for default install
2263 Function ShouldClientInstall
2265 StrCpy $R2 "AFS Client"
2266 Call GetInstalledVersion
2269 StrCmp $R0 "" NotInstalled
2270 ; Now we see if it's an older or newer version
2272 Call GetInstalledVersionMajor
2274 IntCmpU $R0 ${AFS_MAJORVERSION} +1 Upgrade Downgrade
2276 Call GetInstalledVersionMinor
2278 IntCmpU $R0 ${AFS_MINORVERSION} +1 Upgrade Downgrade
2280 Call GetInstalledVersionPatch
2282 IntCmpU $R0 ${AFS_PATCHLEVEL} Reinstall Upgrade Downgrade
2305 ;-------------------------------
2306 ; Check how the server options should be set
2307 Function ShouldServerInstall
2309 StrCpy $R2 "AFS Server"
2310 Call GetInstalledVersion
2313 StrCmp $R0 "" NotInstalled
2314 ; Now we see if it's an older or newer version
2316 Call GetInstalledVersionMajor
2318 IntCmpU $R0 ${AFS_MAJORVERSION} +1 Upgrade Downgrade
2320 Call GetInstalledVersionMinor
2322 IntCmpU $R0 ${AFS_MINORVERSION} +1 Upgrade Downgrade
2324 Call GetInstalledVersionPatch
2326 IntCmpU $R0 ${AFS_PATCHLEVEL} Reinstall Upgrade Downgrade
2351 ; See if AFS Server is installed
2352 ; Returns: "1" if it is, 0 if it is not (on the stack)
2353 Function IsServerInstalled
2355 StrCpy $R2 "AFS Server"
2356 Call GetInstalledVersion
2359 StrCmp $R0 "" NotInstalled
2372 ; See if AFS Client is installed
2373 ; Returns: "1" if it is, 0 if it is not (on the stack)
2374 Function IsClientInstalled
2376 StrCpy $R2 "AFS Client"
2377 Call GetInstalledVersion
2380 StrCmp $R0 "" NotInstalled
2394 ; See if AFS Documentation is installed
2395 ; Returns: "1" if it is, 0 if it is not (on the stack)
2396 Function IsDocumentationInstalled
2398 StrCpy $R2 "AFS Supplemental Documentation"
2399 Call GetInstalledVersion
2402 StrCmp $R0 "" NotInstalled
2415 ; See if Control Center is installed
2416 ; Returns: "1" if it is, 0 if it is not (on the stack)
2417 Function IsControlInstalled
2419 StrCpy $R2 "AFS Control Center"
2420 Call GetInstalledVersion
2423 StrCmp $R0 "" NotInstalled
2438 ; output, top of stack (replaces, with e.g. whatever)
2439 ; modifies no other variables.
2441 Function GetParameters
2445 StrCpy $R0 $CMDLINE 1
2449 StrCpy $R1 ' ' ; we're scanning for a space instead of a quote
2451 StrCpy $R0 $CMDLINE 1 $R2
2452 StrCmp $R0 $R1 loop2
2458 StrCpy $R0 $CMDLINE 1 $R2
2459 StrCmp $R0 " " loop2
2460 StrCpy $R0 $CMDLINE "" $R2
2467 ;Check to see if any AFS component is installed
2468 ;Returns: Value on stack: "1" if it is, "0" if it is not
2469 Function IsAnyAFSInstalled
2474 Call IsClientInstalled
2476 Call IsServerInstalled
2478 Call IsControlInstalled
2480 Call IsDocumentationInstalled
2482 ; Now we must see if ANY of the $Rn values are 1
2483 StrCmp $R0 "1" SomethingInstalled
2484 StrCmp $R1 "1" SomethingInstalled
2485 StrCmp $R2 "1" SomethingInstalled
2486 StrCmp $R3 "1" SomethingInstalled
2500 ;Install English Language Files
2501 Function AFSLangFiles
2503 SetOutPath "$INSTDIR\Common"
2504 File "${AFS_CLIENT_BUILDDIR}\afs_config.exe"
2505 File "${AFS_SERVER_BUILDDIR}\afsadminutil.dll"
2506 !insertmacro UpgradeDLL "${AFS_DESTDIR}\lib\afsauthent.dll" "$INSTDIR\Common\afsauthent.dll" "$INSTDIR"
2507 !insertmacro UpgradeDLL "${AFS_DESTDIR}\lib\afspthread.dll" "$INSTDIR\Common\afspthread.dll" "$INSTDIR"
2508 !insertmacro UpgradeDLL "${AFS_DESTDIR}\lib\afsrpc.dll" "$INSTDIR\Common\afsrpc.dll" "$INSTDIR"
2509 File "${AFS_SERVER_BUILDDIR}\afsclientadmin.dll"
2510 File "${AFS_SERVER_BUILDDIR}\afsprocmgmt.dll"
2511 File "${AFS_SERVER_BUILDDIR}\afsvosadmin.dll"
2512 File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib.dll"
2513 File "${AFS_SERVER_BUILDDIR}\afsvosadmin.dll"
2514 File "${AFS_SERVER_BUILDDIR}\afsbosadmin.dll"
2515 File "${AFS_SERVER_BUILDDIR}\afscfgadmin.dll"
2516 File "${AFS_SERVER_BUILDDIR}\afskasadmin.dll"
2517 File "${AFS_SERVER_BUILDDIR}\afsptsadmin.dll"
2521 File "${SYSTEMDIR}\msvcr71d.dll"
2522 File "${SYSTEMDIR}\msvcr71d.pdb"
2523 File "${SYSTEMDIR}\msvcp71d.dll"
2524 File "${SYSTEMDIR}\msvcp71d.pdb"
2525 File "${SYSTEMDIR}\mfc71d.dll"
2526 File "${SYSTEMDIR}\mfc71d.pdb"
2527 File "${SYSTEMDIR}\MFC71CHS.DLL"
2528 File "${SYSTEMDIR}\MFC71CHT.DLL"
2529 File "${SYSTEMDIR}\MFC71DEU.DLL"
2530 File "${SYSTEMDIR}\MFC71ENU.DLL"
2531 File "${SYSTEMDIR}\MFC71ESP.DLL"
2532 File "${SYSTEMDIR}\MFC71FRA.DLL"
2533 File "${SYSTEMDIR}\MFC71ITA.DLL"
2534 File "${SYSTEMDIR}\MFC71JPN.DLL"
2535 File "${SYSTEMDIR}\MFC71KOR.DLL"
2538 File "${SYSTEMDIR}\msvcr70d.dll"
2539 File "${SYSTEMDIR}\msvcr70d.pdb"
2540 File "${SYSTEMDIR}\msvcp70d.dll"
2541 File "${SYSTEMDIR}\msvcp70d.pdb"
2542 File "${SYSTEMDIR}\mfc70d.dll"
2543 File "${SYSTEMDIR}\mfc70d.pdb"
2544 File "${SYSTEMDIR}\MFC70CHS.DLL"
2545 File "${SYSTEMDIR}\MFC70CHT.DLL"
2546 File "${SYSTEMDIR}\MFC70DEU.DLL"
2547 File "${SYSTEMDIR}\MFC70ENU.DLL"
2548 File "${SYSTEMDIR}\MFC70ESP.DLL"
2549 File "${SYSTEMDIR}\MFC70FRA.DLL"
2550 File "${SYSTEMDIR}\MFC70ITA.DLL"
2551 File "${SYSTEMDIR}\MFC70JPN.DLL"
2552 File "${SYSTEMDIR}\MFC70KOR.DLL"
2554 File "${SYSTEMDIR}\mfc42d.dll"
2555 File "${SYSTEMDIR}\mfc42d.pdb"
2556 File "${SYSTEMDIR}\msvcp60d.dll"
2557 File "${SYSTEMDIR}\msvcp60d.pdb"
2558 File "${SYSTEMDIR}\msvcrtd.dll"
2559 File "${SYSTEMDIR}\msvcrtd.pdb"
2564 File "${SYSTEMDIR}\mfc71.dll"
2565 File "${SYSTEMDIR}\msvcr71.dll"
2566 File "${SYSTEMDIR}\msvcp71.dll"
2567 File "${SYSTEMDIR}\MFC71CHS.DLL"
2568 File "${SYSTEMDIR}\MFC71CHT.DLL"
2569 File "${SYSTEMDIR}\MFC71DEU.DLL"
2570 File "${SYSTEMDIR}\MFC71ENU.DLL"
2571 File "${SYSTEMDIR}\MFC71ESP.DLL"
2572 File "${SYSTEMDIR}\MFC71FRA.DLL"
2573 File "${SYSTEMDIR}\MFC71ITA.DLL"
2574 File "${SYSTEMDIR}\MFC71JPN.DLL"
2575 File "${SYSTEMDIR}\MFC71KOR.DLL"
2578 File "${SYSTEMDIR}\mfc70.dll"
2579 File "${SYSTEMDIR}\msvcr70.dll"
2580 File "${SYSTEMDIR}\msvcp70.dll"
2581 File "${SYSTEMDIR}\MFC70CHS.DLL"
2582 File "${SYSTEMDIR}\MFC70CHT.DLL"
2583 File "${SYSTEMDIR}\MFC70DEU.DLL"
2584 File "${SYSTEMDIR}\MFC70ENU.DLL"
2585 File "${SYSTEMDIR}\MFC70ESP.DLL"
2586 File "${SYSTEMDIR}\MFC70FRA.DLL"
2587 File "${SYSTEMDIR}\MFC70ITA.DLL"
2588 File "${SYSTEMDIR}\MFC70JPN.DLL"
2589 File "${SYSTEMDIR}\MFC70KOR.DLL"
2591 File "${SYSTEMDIR}\mfc42.dll"
2592 File "${SYSTEMDIR}\msvcp60.dll"
2593 File "${SYSTEMDIR}\msvcrt.dll"
2599 File "${AFS_CLIENT_BUILDDIR}\afs_config.pdb"
2600 File "${AFS_SERVER_BUILDDIR}\afsadminutil.pdb"
2601 File "${AFS_DESTDIR}\lib\afsauthent.pdb"
2602 File "${AFS_DESTDIR}\lib\afspthread.pdb"
2603 File "${AFS_DESTDIR}\lib\afsrpc.pdb"
2604 File "${AFS_SERVER_BUILDDIR}\afsclientadmin.pdb"
2605 File "${AFS_SERVER_BUILDDIR}\afsprocmgmt.pdb"
2606 File "${AFS_SERVER_BUILDDIR}\afsvosadmin.pdb"
2607 File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib.pdb"
2608 File "${AFS_SERVER_BUILDDIR}\afsvosadmin.pdb"
2609 File "${AFS_SERVER_BUILDDIR}\afsbosadmin.pdb"
2610 File "${AFS_SERVER_BUILDDIR}\afscfgadmin.pdb"
2611 File "${AFS_SERVER_BUILDDIR}\afskasadmin.pdb"
2612 File "${AFS_SERVER_BUILDDIR}\afsptsadmin.pdb"
2615 StrCmp $LANGUAGE ${LANG_ENGLISH} DoEnglish
2616 StrCmp $LANGUAGE ${LANG_GERMAN} DoGerman
2617 StrCmp $LANGUAGE ${LANG_SPANISH} DoSpanish
2618 StrCmp $LANGUAGE ${LANG_JAPANESE} DoJapanese
2619 StrCmp $LANGUAGE ${LANG_KOREAN} DoKorean
2620 StrCmp $LANGUAGE ${LANG_PORTUGUESEBR} DoPortugueseBR
2621 StrCmp $LANGUAGE ${LANG_SIMPCHINESE} DoSimpChinese
2622 StrCmp $LANGUAGE ${LANG_TRADCHINESE} DoTradChinese
2626 SetOutPath "$INSTDIR\Documentation"
2627 File "..\..\doc\install\Documentation\en_US\README.TXT"
2629 SetOutPath "$INSTDIR\Client\Program"
2630 File "${AFS_CLIENT_BUILDDIR}\afscreds_1033.dll"
2631 !insertmacro UpgradeDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1033.dll" "$INSTDIR\Client\Program\afs_shl_ext_1033.dll" "$INSTDIR"
2633 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1033.pdb"
2634 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1033.pdb"
2637 SetOutPath "$INSTDIR\Common"
2638 File "${AFS_CLIENT_BUILDDIR}\afs_config_1033.dll"
2639 File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1033.dll"
2640 File "${AFS_SERVER_BUILDDIR}\afseventmsg_1033.dll"
2641 ;File "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1033.dll"
2642 File "${AFS_SERVER_BUILDDIR}\afsserver_1033.dll"
2643 File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1033.dll"
2644 File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1033.dll"
2645 File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1033.dll"
2646 File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1033.dll"
2647 File "..\..\doc\help\en_US\afs-cc.CNT"
2648 File "..\..\doc\help\en_US\afs-cc.hlp"
2649 File "..\..\doc\help\en_US\afs-light.CNT"
2650 File "..\..\doc\help\en_US\afs-light.hlp"
2651 File "..\..\doc\help\en_US\afs-nt.CNT"
2652 File "..\..\doc\help\en_US\afs-nt.HLP"
2653 File "..\..\doc\help\en_US\taafscfg.CNT"
2654 File "..\..\doc\help\en_US\taafscfg.hlp"
2655 File "..\..\doc\help\en_US\taafssvrmgr.CNT"
2656 File "..\..\doc\help\en_US\taafssvrmgr.hlp"
2657 File "..\..\doc\help\en_US\taafsusrmgr.CNT"
2658 File "..\..\doc\help\en_US\taafsusrmgr.hlp"
2661 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1033.pdb"
2662 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1033.pdb"
2663 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1033.pdb"
2664 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1033.pdb"
2665 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1033.pdb"
2666 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1033.pdb"
2667 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1033.pdb"
2668 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1033.pdb"
2674 SetOutPath "$INSTDIR\Documentation"
2675 File "..\..\doc\install\Documentation\de_DE\README.TXT"
2677 SetOutPath "$INSTDIR\Client\Program"
2678 File "${AFS_CLIENT_BUILDDIR}\afscreds_1032.dll"
2679 !insertmacro UpgradeDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1032.dll" "$INSTDIR\Client\Program\afs_shl_ext_1032.dll" "$INSTDIR"
2681 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1032.pdb"
2682 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1032.pdb"
2685 SetOutPath "$INSTDIR\Common"
2686 File "${AFS_CLIENT_BUILDDIR}\afs_config_1032.dll"
2687 File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1032.dll"
2688 File "${AFS_SERVER_BUILDDIR}\afseventmsg_1032.dll"
2689 ;File "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1032.dll"
2690 File "${AFS_SERVER_BUILDDIR}\afsserver_1032.dll"
2691 File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1032.dll"
2692 File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1032.dll"
2693 File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1032.dll"
2694 File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1032.dll"
2695 File "..\..\doc\help\de_DE\afs-cc.CNT"
2696 File "..\..\doc\help\de_DE\afs-cc.hlp"
2697 File "..\..\doc\help\de_DE\afs-light.CNT"
2698 File "..\..\doc\help\de_DE\afs-light.hlp"
2699 File "..\..\doc\help\de_DE\afs-nt.CNT"
2700 File "..\..\doc\help\de_DE\afs-nt.HLP"
2701 File "..\..\doc\help\de_DE\taafscfg.CNT"
2702 File "..\..\doc\help\de_DE\taafscfg.hlp"
2703 File "..\..\doc\help\de_DE\taafssvrmgr.CNT"
2704 File "..\..\doc\help\de_DE\taafssvrmgr.hlp"
2705 File "..\..\doc\help\de_DE\taafsusrmgr.CNT"
2706 File "..\..\doc\help\de_DE\taafsusrmgr.hlp"
2709 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1032.pdb"
2710 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1032.pdb"
2711 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1032.pdb"
2712 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1032.pdb"
2713 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1032.pdb"
2714 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1032.pdb"
2715 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1032.pdb"
2716 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1032.pdb"
2722 SetOutPath "$INSTDIR\Documentation"
2723 File "..\..\doc\install\Documentation\es_ES\README.TXT"
2725 SetOutPath "$INSTDIR\Client\Program"
2726 File "${AFS_CLIENT_BUILDDIR}\afscreds_1034.dll"
2727 !insertmacro UpgradeDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1034.dll" "$INSTDIR\Client\Program\afs_shl_ext_1034.dll" "$INSTDIR"
2729 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1034.pdb"
2730 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1034.pdb"
2733 SetOutPath "$INSTDIR\Common"
2734 File "${AFS_CLIENT_BUILDDIR}\afs_config_1034.dll"
2735 File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1034.dll"
2736 File "${AFS_SERVER_BUILDDIR}\afseventmsg_1034.dll"
2737 ;File "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1034.dll"
2738 File "${AFS_SERVER_BUILDDIR}\afsserver_1034.dll"
2739 File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1034.dll"
2740 File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1034.dll"
2741 File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1034.dll"
2742 File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1034.dll"
2743 File "..\..\doc\help\es_ES\afs-cc.CNT"
2744 File "..\..\doc\help\es_ES\afs-cc.hlp"
2745 File "..\..\doc\help\es_ES\afs-light.CNT"
2746 File "..\..\doc\help\es_ES\afs-light.hlp"
2747 File "..\..\doc\help\es_ES\afs-nt.CNT"
2748 File "..\..\doc\help\es_ES\afs-nt.HLP"
2749 File "..\..\doc\help\es_ES\taafscfg.CNT"
2750 File "..\..\doc\help\es_ES\taafscfg.hlp"
2751 File "..\..\doc\help\es_ES\taafssvrmgr.CNT"
2752 File "..\..\doc\help\es_ES\taafssvrmgr.hlp"
2753 File "..\..\doc\help\es_ES\taafsusrmgr.CNT"
2754 File "..\..\doc\help\es_ES\taafsusrmgr.hlp"
2757 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1034.pdb"
2758 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1034.pdb"
2759 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1034.pdb"
2760 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1034.pdb"
2761 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1034.pdb"
2762 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1034.pdb"
2763 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1034.pdb"
2764 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1034.pdb"
2770 SetOutPath "$INSTDIR\Documentation"
2771 File "..\..\doc\install\Documentation\ja_JP\README.TXT"
2773 SetOutPath "$INSTDIR\Client\Program"
2774 File "${AFS_CLIENT_BUILDDIR}\afscreds_1041.dll"
2775 !insertmacro UpgradeDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1041.dll" "$INSTDIR\Client\Program\afs_shl_ext_1041.dll" "$INSTDIR"
2777 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1041.pdb"
2778 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1041.pdb"
2781 SetOutPath "$INSTDIR\Common"
2782 File "${AFS_CLIENT_BUILDDIR}\afs_config_1041.dll"
2783 File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1041.dll"
2784 File "${AFS_SERVER_BUILDDIR}\afseventmsg_1041.dll"
2785 ;File "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1041.dll"
2786 File "${AFS_SERVER_BUILDDIR}\afsserver_1041.dll"
2787 File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1041.dll"
2788 File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1041.dll"
2789 File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1041.dll"
2790 File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1041.dll"
2791 File "..\..\doc\help\ja_JP\afs-cc.CNT"
2792 File "..\..\doc\help\ja_JP\afs-cc.hlp"
2793 File "..\..\doc\help\ja_JP\afs-light.CNT"
2794 File "..\..\doc\help\ja_JP\afs-light.hlp"
2795 File "..\..\doc\help\ja_JP\afs-nt.CNT"
2796 File "..\..\doc\help\ja_JP\afs-nt.HLP"
2797 File "..\..\doc\help\ja_JP\taafscfg.CNT"
2798 File "..\..\doc\help\ja_JP\taafscfg.hlp"
2799 File "..\..\doc\help\ja_JP\taafssvrmgr.CNT"
2800 File "..\..\doc\help\ja_JP\taafssvrmgr.hlp"
2801 File "..\..\doc\help\ja_JP\taafsusrmgr.CNT"
2802 File "..\..\doc\help\ja_JP\taafsusrmgr.hlp"
2805 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1041.pdb"
2806 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1041.pdb"
2807 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1041.pdb"
2808 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1041.pdb"
2809 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1041.pdb"
2810 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1041.pdb"
2811 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1041.pdb"
2812 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1041.pdb"
2818 SetOutPath "$INSTDIR\Documentation"
2819 File "..\..\doc\install\Documentation\ko_KR\README.TXT"
2821 SetOutPath "$INSTDIR\Client\Program"
2822 File "${AFS_CLIENT_BUILDDIR}\afscreds_1042.dll"
2823 !insertmacro UpgradeDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1042.dll" "$INSTDIR\Client\Program\afs_shl_ext_1042.dll" "$INSTDIR"
2825 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1042.pdb"
2826 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1042.pdb"
2829 SetOutPath "$INSTDIR\Common"
2830 File "${AFS_CLIENT_BUILDDIR}\afs_config_1042.dll"
2831 File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1042.dll"
2832 File "${AFS_SERVER_BUILDDIR}\afseventmsg_1042.dll"
2833 ;File "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1042.dll"
2834 File "${AFS_SERVER_BUILDDIR}\afsserver_1042.dll"
2835 File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1042.dll"
2836 File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1042.dll"
2837 File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1042.dll"
2838 File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1042.dll"
2839 File "..\..\doc\help\ko_KR\afs-cc.CNT"
2840 File "..\..\doc\help\ko_KR\afs-cc.hlp"
2841 File "..\..\doc\help\ko_KR\afs-light.CNT"
2842 File "..\..\doc\help\ko_KR\afs-light.hlp"
2843 File "..\..\doc\help\ko_KR\afs-nt.CNT"
2844 File "..\..\doc\help\ko_KR\afs-nt.HLP"
2845 File "..\..\doc\help\ko_KR\taafscfg.CNT"
2846 File "..\..\doc\help\ko_KR\taafscfg.hlp"
2847 File "..\..\doc\help\ko_KR\taafssvrmgr.CNT"
2848 File "..\..\doc\help\ko_KR\taafssvrmgr.hlp"
2849 File "..\..\doc\help\ko_KR\taafsusrmgr.CNT"
2850 File "..\..\doc\help\ko_KR\taafsusrmgr.hlp"
2853 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1042.pdb"
2854 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1042.pdb"
2855 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1042.pdb"
2856 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1042.pdb"
2857 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1042.pdb"
2858 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1042.pdb"
2859 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1042.pdb"
2860 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1042.pdb"
2867 SetOutPath "$INSTDIR\Documentation"
2868 File "..\..\doc\install\Documentation\pt_BR\README.TXT"
2870 SetOutPath "$INSTDIR\Client\Program"
2871 File "${AFS_CLIENT_BUILDDIR}\afscreds_1046.dll"
2872 !insertmacro UpgradeDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1046.dll" "$INSTDIR\Client\Program\afs_shl_ext_1046.dll" "$INSTDIR"
2874 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1046.pdb"
2875 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1046.pdb"
2878 SetOutPath "$INSTDIR\Common"
2879 File "${AFS_CLIENT_BUILDDIR}\afs_config_1046.dll"
2880 File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1046.dll"
2881 File "${AFS_SERVER_BUILDDIR}\afseventmsg_1046.dll"
2882 ;File "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1046.dll"
2883 File "${AFS_SERVER_BUILDDIR}\afsserver_1046.dll"
2884 File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1046.dll"
2885 File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1046.dll"
2886 File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1046.dll"
2887 File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1046.dll"
2888 File "..\..\doc\help\pt_BR\afs-cc.CNT"
2889 File "..\..\doc\help\pt_BR\afs-cc.hlp"
2890 File "..\..\doc\help\pt_BR\afs-light.CNT"
2891 File "..\..\doc\help\pt_BR\afs-light.hlp"
2892 File "..\..\doc\help\pt_BR\afs-nt.CNT"
2893 File "..\..\doc\help\pt_BR\afs-nt.HLP"
2894 File "..\..\doc\help\pt_BR\taafscfg.CNT"
2895 File "..\..\doc\help\pt_BR\taafscfg.hlp"
2896 File "..\..\doc\help\pt_BR\taafssvrmgr.CNT"
2897 File "..\..\doc\help\pt_BR\taafssvrmgr.hlp"
2898 File "..\..\doc\help\pt_BR\taafsusrmgr.CNT"
2899 File "..\..\doc\help\pt_BR\taafsusrmgr.hlp"
2902 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1046.pdb"
2903 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1046.pdb"
2904 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1046.pdb"
2905 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1046.pdb"
2906 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1046.pdb"
2907 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1046.pdb"
2908 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1046.pdb"
2909 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1046.pdb"
2915 SetOutPath "$INSTDIR\Documentation"
2916 File "..\..\doc\install\Documentation\zh_CN\README.TXT"
2918 SetOutPath "$INSTDIR\Client\Program"
2919 File "${AFS_CLIENT_BUILDDIR}\afscreds_2052.dll"
2920 !insertmacro UpgradeDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_2052.dll" "$INSTDIR\Client\Program\afs_shl_ext_2052.dll" "$INSTDIR"
2922 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_2052.pdb"
2923 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_2052.pdb"
2926 SetOutPath "$INSTDIR\Common"
2927 File "${AFS_CLIENT_BUILDDIR}\afs_config_2052.dll"
2928 File "${AFS_CLIENT_BUILDDIR}\afs_cpa_2052.dll"
2929 File "${AFS_SERVER_BUILDDIR}\afseventmsg_2052.dll"
2930 ;File "${AFS_SERVER_BUILDDIR}\afs_setup_utils_2052.dll"
2931 File "${AFS_SERVER_BUILDDIR}\afsserver_2052.dll"
2932 File "${AFS_SERVER_BUILDDIR}\afssvrcfg_2052.dll"
2933 File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_2052.dll"
2934 File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_2052.dll"
2935 File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_2052.dll"
2936 File "..\..\doc\help\zh_CN\afs-cc.CNT"
2937 File "..\..\doc\help\zh_CN\afs-cc.hlp"
2938 File "..\..\doc\help\zh_CN\afs-light.CNT"
2939 File "..\..\doc\help\zh_CN\afs-light.hlp"
2940 File "..\..\doc\help\zh_CN\afs-nt.CNT"
2941 File "..\..\doc\help\zh_CN\afs-nt.HLP"
2942 File "..\..\doc\help\zh_CN\taafscfg.CNT"
2943 File "..\..\doc\help\zh_CN\taafscfg.hlp"
2944 File "..\..\doc\help\zh_CN\taafssvrmgr.CNT"
2945 File "..\..\doc\help\zh_CN\taafssvrmgr.hlp"
2946 File "..\..\doc\help\zh_CN\taafsusrmgr.CNT"
2947 File "..\..\doc\help\zh_CN\taafsusrmgr.hlp"
2950 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_2052.pdb"
2951 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_2052.pdb"
2952 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_2052.pdb"
2953 ;File "${AFS_SERVER_BUILDDIR}\afsserver_2052.pdb"
2954 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_2052.pdb"
2955 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_2052.pdb"
2956 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_2052.pdb"
2957 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_2052.pdb"
2963 SetOutPath "$INSTDIR\Documentation"
2964 File "..\..\doc\install\Documentation\zh_TW\README.TXT"
2966 SetOutPath "$INSTDIR\Client\Program"
2967 File "${AFS_CLIENT_BUILDDIR}\afscreds_1028.dll"
2968 !insertmacro UpgradeDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1028.dll" "$INSTDIR\Client\Program\afs_shl_ext_1028.dll" "$INSTDIR"
2970 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1028.pdb"
2971 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1028.pdb"
2974 SetOutPath "$INSTDIR\Common"
2975 File "${AFS_CLIENT_BUILDDIR}\afs_config_1028.dll"
2976 File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1028.dll"
2977 File "${AFS_SERVER_BUILDDIR}\afseventmsg_1028.dll"
2978 ;File "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1028.dll"
2979 File "${AFS_SERVER_BUILDDIR}\afsserver_1028.dll"
2980 File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1028.dll"
2981 File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1028.dll"
2982 File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1028.dll"
2983 File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1028.dll"
2984 File "..\..\doc\help\zh_TW\afs-cc.CNT"
2985 File "..\..\doc\help\zh_TW\afs-cc.hlp"
2986 File "..\..\doc\help\zh_TW\afs-light.CNT"
2987 File "..\..\doc\help\zh_TW\afs-light.hlp"
2988 File "..\..\doc\help\zh_TW\afs-nt.CNT"
2989 File "..\..\doc\help\zh_TW\afs-nt.HLP"
2990 File "..\..\doc\help\zh_TW\taafscfg.CNT"
2991 File "..\..\doc\help\zh_TW\taafscfg.hlp"
2992 File "..\..\doc\help\zh_TW\taafssvrmgr.CNT"
2993 File "..\..\doc\help\zh_TW\taafssvrmgr.hlp"
2994 File "..\..\doc\help\zh_TW\taafsusrmgr.CNT"
2995 File "..\..\doc\help\zh_TW\taafsusrmgr.hlp"
2998 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1028.pdb"
2999 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1028.pdb"
3000 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1028.pdb"
3001 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1028.pdb"
3002 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1028.pdb"
3003 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1028.pdb"
3004 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1028.pdb"
3005 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1028.pdb"
3014 ;====================================================
3015 ; AddToPath - Adds the given dir to the search path.
3016 ; Input - head of the stack
3017 ; Note - Win9x systems requires reboot
3018 ;====================================================
3025 # don't add if the path doesn't exist
3026 IfFileExists $0 "" AddToPath_done
3033 StrCmp $2 "" "" AddToPath_done
3038 StrCmp $2 "" "" AddToPath_done
3039 GetFullPathName /SHORT $3 $0
3044 StrCmp $2 "" "" AddToPath_done
3049 StrCmp $2 "" "" AddToPath_done
3053 StrCmp $1 1 AddToPath_NT
3056 FileOpen $1 "$1\autoexec.bat" a
3059 IntCmp $2 26 0 +2 +2 # DOS EOF
3060 FileSeek $1 -1 END # write over EOF
3061 FileWrite $1 "$\r$\nSET PATH=%PATH%;$3$\r$\n"
3067 ReadRegStr $1 HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "PATH"
3068 StrCpy $2 $1 1 -1 # copy last char
3069 StrCmp $2 ";" 0 +2 # if last char == ;
3070 StrCpy $1 $1 -1 # remove last char
3071 StrCmp $1 "" AddToPath_NTdoIt
3074 WriteRegExpandStr HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "PATH" $0
3075 SendMessage ${HWND_BROADCAST} ${WM_WININICHANGE} 0 "STR:Environment" /TIMEOUT=5000
3084 ;====================================================
3085 ; RemoveFromPath - Remove a given dir from the path
3086 ; Input: head of the stack
3087 ;====================================================
3088 Function un.RemoveFromPath
3097 IntFmt $6 "%c" 26 # DOS EOF
3101 StrCmp $1 1 unRemoveFromPath_NT
3104 FileOpen $1 "$1\autoexec.bat" r
3107 GetFullPathName /SHORT $0 $0
3108 StrCpy $0 "SET PATH=%PATH%;$0"
3109 Goto unRemoveFromPath_dosLoop
3111 unRemoveFromPath_dosLoop:
3113 StrCpy $5 $3 1 -1 # read last char
3114 StrCmp $5 $6 0 +2 # if DOS EOF
3115 StrCpy $3 $3 -1 # remove DOS EOF so we can compare
3116 StrCmp $3 "$0$\r$\n" unRemoveFromPath_dosLoopRemoveLine
3117 StrCmp $3 "$0$\n" unRemoveFromPath_dosLoopRemoveLine
3118 StrCmp $3 "$0" unRemoveFromPath_dosLoopRemoveLine
3119 StrCmp $3 "" unRemoveFromPath_dosLoopEnd
3121 Goto unRemoveFromPath_dosLoop
3122 unRemoveFromPath_dosLoopRemoveLine:
3124 Goto unRemoveFromPath_dosLoop
3126 unRemoveFromPath_dosLoopEnd:
3130 Delete "$1\autoexec.bat"
3131 CopyFiles /SILENT $4 "$1\autoexec.bat"
3133 Goto unRemoveFromPath_done
3135 unRemoveFromPath_NT:
3136 ReadRegStr $1 HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "PATH"
3137 StrCpy $5 $1 1 -1 # copy last char
3138 StrCmp $5 ";" +2 # if last char != ;
3139 StrCpy $1 "$1;" # append ;
3142 Call un.StrStr ; Find `$0;` in $1
3143 Pop $2 ; pos of our dir
3144 StrCmp $2 "" unRemoveFromPath_done
3145 ; else, it is in path
3150 StrCpy $5 $1 -$4 # $5 is now the part before the path to remove
3151 StrCpy $6 $2 "" $3 # $6 is now the part after the path to remove
3154 StrCpy $5 $3 1 -1 # copy last char
3155 StrCmp $5 ";" 0 +2 # if last char == ;
3156 StrCpy $3 $3 -1 # remove last char
3158 WriteRegExpandStr HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "PATH" $3
3159 SendMessage ${HWND_BROADCAST} ${WM_WININICHANGE} 0 "STR:Environment" /TIMEOUT=5000
3161 unRemoveFromPath_done:
3171 ;====================================================
3172 ; IsNT - Returns 1 if the current system is NT, 0
3174 ; Output: head of the stack
3175 ;====================================================
3179 ReadRegStr $0 HKLM "SOFTWARE\Microsoft\Windows NT\CurrentVersion" CurrentVersion
3180 StrCmp $0 "" 0 IsNT_yes
3192 !insertmacro IsNT ""
3193 !insertmacro IsNT "un."
3195 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
3197 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
3198 ;====================================================
3199 ; StrStr - Finds a given string in another given string.
3200 ; Returns -1 if not found and the pos if found.
3201 ; Input: head of the stack - string to find
3202 ; second in the stack - string to find in
3203 ; Output: head of the stack
3204 ;====================================================
3206 Function ${un}StrStr
3207 Exch $R1 ; st=haystack,old$R1, $R1=needle
3208 Exch ; st=old$R1,haystack
3209 Exch $R2 ; st=old$R1,old$R2, $R2=haystack
3221 StrCpy $R5 $R2 $R3 $R4
3227 StrCpy $R1 $R2 "" $R4
3235 !insertmacro StrStr ""
3236 !insertmacro StrStr "un."
3239 !ifdef ADDSHAREDDLLUSED
3242 ; Increments a shared DLLs reference count.
3243 ; Use by passing one item on the stack (the full path of the DLL).
3246 ; Push $SYSDIR\myDll.dll
3250 Function AddSharedDLL
3253 ReadRegDword $R0 HKLM Software\Microsoft\Windows\CurrentVersion\SharedDLLs $R1
3255 WriteRegDWORD HKLM Software\Microsoft\Windows\CurrentVersion\SharedDLLs $R1 $R0
3261 ; un.RemoveSharedDLL
3263 ; Decrements a shared DLLs reference count, and removes if necessary.
3264 ; Use by passing one item on the stack (the full path of the DLL).
3265 ; Note: for use in the main installer (not the uninstaller), rename the
3266 ; function to RemoveSharedDLL.
3269 ; Push $SYSDIR\myDll.dll
3270 ; Call un.RemoveSharedDLL
3273 Function un.RemoveSharedDLL
3276 ReadRegDword $R0 HKLM Software\Microsoft\Windows\CurrentVersion\SharedDLLs $R1
3277 StrCmp $R0 "" remove
3279 IntCmp $R0 0 rk rk uk
3281 DeleteRegValue HKLM Software\Microsoft\Windows\CurrentVersion\SharedDLLs $R1
3284 WriteRegDWORD HKLM Software\Microsoft\Windows\CurrentVersion\SharedDLLs $R1 $R0
3287 Delete /REBOOTOK $R1
3296 !ifdef INSTALL_LOOPBACK
3297 Function afs.InstallMSLoopback
3299 File /oname=$R0 "loopback_install.dll"
3300 nsExec::Exec "rundll32.exe $R0 doLoopBackEntry quiet"
3301 Call GetWindowsVersion
3303 StrCmp $R1 "2000" +1 +2
3304 nsExec::Exec "rundll32.exe $R0 disableLoopBackEntry"
3312 ; Based on Yazno's function, http://yazno.tripod.com/powerpimpit/
3313 ; Updated by Joost Verburg
3315 ; Returns on top of stack
3317 ; Windows Version (95, 98, ME, NT x.x, 2000, XP, 2003)
3319 ; '' (Unknown Windows Version)
3322 ; Call GetWindowsVersion
3324 ; ; at this point $R0 is "NT 4.0" or whatnot
3326 Function GetWindowsVersion
3333 ReadRegStr $R0 HKLM \
3334 "SOFTWARE\Microsoft\Windows NT\CurrentVersion" CurrentVersion
3336 IfErrors 0 lbl_winnt
3339 ReadRegStr $R0 HKLM \
3340 "SOFTWARE\Microsoft\Windows\CurrentVersion" VersionNumber
3343 StrCmp $R1 '4' 0 lbl_error
3347 StrCmp $R1 '4.0' lbl_win32_95
3348 StrCmp $R1 '4.9' lbl_win32_ME lbl_win32_98
3366 StrCmp $R1 '3' lbl_winnt_x
3367 StrCmp $R1 '4' lbl_winnt_x
3371 StrCmp $R1 '5.0' lbl_winnt_2000
3372 StrCmp $R1 '5.1' lbl_winnt_XP
3373 StrCmp $R1 '5.2' lbl_winnt_2003 lbl_error
3376 StrCpy $R0 "NT $R0" 6
3401 ; Author: Lilla (lilla@earthlink.net) 2003-06-13
3402 ; function IsUserAdmin uses plugin \NSIS\PlusgIns\UserInfo.dll
3403 ; This function is based upon code in \NSIS\Contrib\UserInfo\UserInfo.nsi
3404 ; This function was tested under NSIS 2 beta 4 (latest CVS as of this writing).
3408 ; Pop $R0 ; at this point $R0 is "true" or "false"
3410 Function IsUserAdmin
3419 UserInfo::GetAccountType
3422 StrCmp $R2 "Admin" 0 Continue
3423 ; Observation: I get here when running Win98SE. (Lilla)
3424 ; The functions UserInfo.dll looks for are there on Win98 too,
3425 ; but just don't work. So UserInfo.dll, knowing that admin isn't required
3426 ; on Win98, returns admin anyway. (per kichik)
3427 ; MessageBox MB_OK 'User "$R1" is in the Administrators group'
3432 ; You should still check for an empty string because the functions
3433 ; UserInfo.dll looks for may not be present on Windows 95. (per kichik)
3436 ;MessageBox MB_OK 'User "$R1" is in the "$R2" group'
3440 ; comment/message below is by UserInfo.nsi author:
3441 ; This one means you don't need to care about admin or
3442 ; not admin because Windows 9x doesn't either
3443 ;MessageBox MB_OK "Error! This DLL can't run under Windows 9x!"
3447 ;MessageBox MB_OK 'User= "$R1" AccountType= "$R2" IsUserAdmin= "$R0"'
3455 ; input, top of stack (e.g. C:\Program Files\Poop)
3456 ; output, top of stack (replaces, with e.g. C:\Program Files)
3457 ; modifies no other variables.
3460 ; Push "C:\Program Files\Directory\Whatever"
3463 ; ; at this point $R0 will equal "C:\Program Files\Directory"
3477 IntCmp $R1 $R2 get 0 get
3478 StrCpy $R3 $R0 1 -$R1
3493 ;--------------------------------
3494 ;Handle what must and what must not be installed
3495 Function .onSelChange
3496 ; If they install the server, they MUST install the client
3497 SectionGetFlags ${secServer} $R0
3498 IntOp $R0 $R0 & ${SF_SELECTED}
3499 StrCmp $R0 "1" MakeClientSelected
3501 ; If they install the control center, we'll give them the client.
3502 ; It may not be required, but it's a bit more useful
3503 SectionGetFlags ${secControl} $R0
3504 IntOp $R0 $R0 & ${SF_SELECTED}
3505 StrCmp $R0 "1" MakeClientSelected
3509 SectionGetFlags ${secClient} $R0
3510 IntOp $R0 $R0 | ${SF_SELECTED}
3511 SectionSetFlags ${secClient} $R0
3516 Function RegWriteMultiStr
3517 !define HKEY_CLASSES_ROOT 0x80000000
3518 !define HKEY_CURRENT_USER 0x80000001
3519 !define HKEY_LOCAL_MACHINE 0x80000002
3520 !define HKEY_USERS 0x80000003
3521 !define HKEY_PERFORMANCE_DATA 0x80000004
3522 !define HKEY_PERFORMANCE_TEXT 0x80000050
3523 !define HKEY_PERFORMANCE_NLSTEXT 0x80000060
3524 !define HKEY_CURRENT_CONFIG 0x80000005
3525 !define HKEY_DYN_DATA 0x80000006
3527 !define KEY_QUERY_VALUE 0x0001
3528 !define KEY_SET_VALUE 0x0002
3529 !define KEY_CREATE_SUB_KEY 0x0004
3530 !define KEY_ENUMERATE_SUB_KEYS 0x0008
3531 !define KEY_NOTIFY 0x0010
3532 !define KEY_CREATE_LINK 0x0020
3536 !define REG_EXPAND_SZ 2
3537 !define REG_BINARY 3
3539 !define REG_DWORD_LITTLE_ENDIAN 4
3540 !define REG_DWORD_BIG_ENDIAN 5
3542 !define REG_MULTI_SZ 7
3544 !define RegCreateKey "Advapi32::RegCreateKeyA(i, t, *i) i"
3545 !define RegSetValueEx "Advapi32::RegSetValueExA(i, t, i, i, i, i) i"
3546 !define RegCloseKey "Advapi32::RegCloseKeyA(i) i"
3553 SetPluginUnload alwaysoff
3554 ; Create a buffer for the multi_sz value
3555 System::Call "*(&t${NSIS_MAX_STRLEN}) i.r1"
3556 ; Open/create the registry key
3557 System::Call "${RegCreateKey}(${HKEY_LOCAL_MACHINE}, '$REG_SUB_KEY', .r0) .r9"
3560 MessageBox MB_OK|MB_ICONSTOP "Can't create registry key! ($9)"
3564 ; Fill in the buffer with our strings
3565 StrCpy $2 $1 ; Initial position
3567 StrLen $9 '$REG_DATA_1' ; Length of first string
3568 IntOp $9 $9 + 1 ; Plus null
3569 System::Call "*$2(&t$9 '$REG_DATA_1')" ; Place the string
3570 IntOp $2 $2 + $9 ; Advance to the next position
3572 StrCmp '$REG_DATA_2' "" terminate
3573 StrLen $9 '$REG_DATA_2' ; Length of second string
3574 IntOp $9 $9 + 1 ; Plus null
3575 System::Call "*$2(&t$9 '$REG_DATA_2')" ; Place the string
3576 IntOp $2 $2 + $9 ; Advance to the next position
3578 StrCmp '$REG_DATA_3' "" terminate
3579 StrLen $9 '$REG_DATA_3' ; Length of third string
3580 IntOp $9 $9 + 1 ; Plus null
3581 System::Call "*$2(&t$9 '$REG_DATA_3')" ; Place the string
3582 IntOp $2 $2 + $9 ; Advance to the next position
3585 System::Call "*$2(&t1 '')" ; Place the terminating null
3586 IntOp $2 $2 + 1 ; Advance to the next position
3588 ; Create/write the value
3589 IntOp $2 $2 - $1 ; Total length
3590 System::Call "${RegSetValueEx}(r0, '$REG_VALUE', 0, ${REG_MULTI_SZ}, r1, r2) .r9"
3593 MessageBox MB_OK|MB_ICONSTOP "Can't set key value! ($9)"
3597 ; Close the registry key
3598 System::Call "${RegCloseKey}(r0)"
3602 SetPluginUnload manual
3611 Function AddProvider
3614 ReadRegStr $R0 HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\HWOrder" "ProviderOrder"
3616 StrCpy $R0 "TransarcAFSDaemon"
3620 StrCmp $R0 "" +1 DoOther
3621 ReadRegStr $R1 HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\HWOrder" "ProviderOrder"
3622 StrCpy $R0 "$R1,TransarcAFSDaemon"
3623 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\HWOrder" "ProviderOrder" $R0
3625 ReadRegStr $R0 HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\Order" "ProviderOrder"
3627 StrCpy $R0 "TransarcAFSDaemon"
3631 StrCmp $R0 "" +1 End
3632 ReadRegStr $R1 HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\Order" "ProviderOrder"
3633 StrCpy $R0 "$R1,TransarcAFSDaemon"
3634 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\Order" "ProviderOrder" $R0
3640 Function un.RemoveProvider
3642 StrCpy $R0 "TransarcAFSDaemon"
3644 StrCpy $R0 "SYSTEM\CurrentControlSet\Control\NetworkProvider\HWOrder"
3645 Call un.RemoveFromProvider
3646 StrCpy $R0 "TransarcAFSDaemon"
3648 StrCpy $R0 "SYSTEM\CurrentControlSet\Control\NetworkProvider\Order"
3649 Call un.RemoveFromProvider
3653 Function un.RemoveFromProvider
3662 ReadRegStr $1 HKLM "$R0" "ProviderOrder"
3663 StrCpy $5 $1 1 -1 # copy last char
3664 StrCmp $5 "," +2 # if last char != ,
3665 StrCpy $1 "$1," # append ,
3668 Call un.StrStr ; Find `$0,` in $1
3669 Pop $2 ; pos of our dir
3670 StrCmp $2 "" unRemoveFromPath_done
3671 ; else, it is in path
3676 StrCpy $5 $1 -$4 # $5 is now the part before the path to remove
3677 StrCpy $6 $2 "" $3 # $6 is now the part after the path to remove
3680 StrCpy $5 $3 1 -1 # copy last char
3681 StrCmp $5 "," 0 +2 # if last char == ,
3682 StrCpy $3 $3 -1 # remove last char
3684 WriteRegStr HKLM "$R0" "ProviderOrder" $3
3686 unRemoveFromPath_done:
3696 Function CheckPathForAFS
3701 ReadRegStr $1 HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "PATH"
3710 IfFileExists "$3\afsd_service.exe" Error
3711 StrCpy $1 $0 32768 1
3713 IntCmp $2 0 Done Done loop
3716 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."
3717 Abort "Unable to install OpenAFS"