1 ; OpenAFS Install Script for NSIS
2 ; This version compiles with NSIS v2.07
4 ; Originally written by Rob Murawski <rsm4@ieee.org>
6 ;Redistribution and use in source and binary forms, with or without modification, are permitted
7 ;provided that the following conditions are met:
9 ; Redistributions of source code must retain the above copyright notice, this list of conditions
10 ; and the following disclaimer. Redistributions in binary form must reproduce the above copyright
11 ; notice, this list of conditions and the following disclaimer in the documentation and/or other
12 ; materials provided with the distribution. The name of the author may not be used to endorse or
13 ; promote products derived from this software without specific prior written permission.
15 ; THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
16 ; INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
17 ; PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT,
18 ; INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
19 ; LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
20 ; BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
21 ; STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
22 ; USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 ; Some code originally based on:
26 ; NSIS Modern User Interface version 1.63
27 ; MultiLanguage Example Script
28 ; Written by Joost Verburg
30 ; Read in the environment information
31 !include ${INCLUDEDIR}\nsi-includes.nsi
35 Name "OpenAFS ${AFS_VERSION} ${__DATE__} ${__TIME__}"
37 Name "OpenAFS ${AFS_VERSION} ${__DATE__} ${__TIME__} Checked/Debug"
38 !endif ; End DEBUG/!DEBUG
41 Name "OpenAFS ${AFS_VERSION}"
43 Name "OpenAFS ${AFS_VERSION} Checked/Debug"
44 !endif ; End DEBUG/!DEBUG
46 VIProductVersion "${AFS_VERSION}.00"
47 VIAddVersionKey "ProductName" "OpenAFS"
48 VIAddVersionKey "CompanyName" "OpenAFS.org"
49 VIAddVersionKey "ProductVersion" ${AFS_VERSION}
50 VIAddVersionKey "FileVersion" ${AFS_VERSION}
51 VIAddVersionKey "FileDescription" "OpenAFS for Windows Installer"
52 VIAddVersionKey "LegalCopyright" "(C)2000-2005"
54 VIAddVersionKey "PrivateBuild" "Checked/Debug"
61 ;--------------------------------
64 !define REPLACEDLL_NOREGISTER
69 OutFile "${AFS_DESTDIR}\WinInstall\OpenAFSforWindows.exe"
71 OutFile "${AFS_DESTDIR}\WinInstall\OpenAFSforWindows-DEBUG.exe"
75 OutFile "${AFS_DESTDIR}\WinInstall\OpenAFSforWindows-IFS.exe"
77 OutFile "${AFS_DESTDIR}\WinInstall\OpenAFSforWindows-IFS-DEBUG.exe"
81 SetCompressor /solid lzma
82 !define MUI_ICON "..\..\client_config\OpenAFS.ico"
83 !define MUI_UNICON "..\..\client_config\OpenAFS.ico"
84 !define AFS_COMPANY_NAME "OpenAFS"
85 !define AFS_PRODUCT_NAME "OpenAFS"
86 !define AFS_REGKEY_ROOT "Software\TransarcCorporation"
89 ;Folder selection page
90 InstallDir "$PROGRAMFILES\OpenAFS" ; Install to shorter path
92 ;Remember install folder
93 InstallDirRegKey HKCU ${AFS_REGKEY_ROOT} ""
95 ;Remember the installer language
96 !define MUI_LANGDLL_REGISTRY_ROOT "HKCU"
97 !define MUI_LANGDLL_REGISTRY_KEY ${AFS_REGKEY_ROOT}
98 !define MUI_LANGDLL_REGISTRY_VALUENAME "Installer Language"
100 ;Where are the files?
101 !define AFS_CLIENT_BUILDDIR "${AFS_DESTDIR}\root.client\usr\vice\etc"
102 !define AFS_WININSTALL_DIR "${AFS_DESTDIR}\WinInstall\Config"
103 !define AFS_BUILD_INCDIR "${AFS_DESTDIR}\include"
104 !define AFS_CLIENT_LIBDIR "${AFS_DESTDIR}\lib"
105 !define AFS_SERVER_BUILDDIR "${AFS_DESTDIR}\root.server\usr\afs\bin"
106 !define AFS_ETC_BUILDDIR "${AFS_DESTDIR}\etc"
107 !define SYSTEMDIR "$%SystemRoot%\System32"
109 ;--------------------------------
110 ;Modern UI Configuration
112 ;!define MUI_LICENSEPAGE
113 !define MUI_CUSTOMPAGECOMMANDS
114 !define MUI_WELCOMEPAGE
115 !define MUI_COMPONENTSPAGE
116 !define MUI_COMPONENTSPAGE_SMALLDESC
117 !define MUI_DIRECTORYPAGE
119 !define MUI_ABORTWARNING
120 !define MUI_FINISHPAGE
122 !define MUI_UNINSTALLER
123 !define MUI_UNCONFIRMPAGE
126 !insertmacro MUI_PAGE_WELCOME
127 !insertmacro MUI_PAGE_COMPONENTS
128 !insertmacro MUI_PAGE_DIRECTORY
129 Page custom AFSPageGetCellServDB
130 Page custom AFSPageGetCellName
131 Page custom AFSPageConfigAFSCreds
132 !insertmacro MUI_PAGE_INSTFILES
133 !insertmacro MUI_PAGE_FINISH
135 ;LicenseData "Licenses.rtf"
136 ;--------------------------------
139 !insertmacro MUI_LANGUAGE "English"
140 ;!insertmacro MUI_LANGUAGE "French"
141 !insertmacro MUI_LANGUAGE "German"
142 !insertmacro MUI_LANGUAGE "Spanish"
143 !insertmacro MUI_LANGUAGE "SimpChinese"
144 !insertmacro MUI_LANGUAGE "TradChinese"
145 !insertmacro MUI_LANGUAGE "Japanese"
146 !insertmacro MUI_LANGUAGE "Korean"
147 ;!insertmacro MUI_LANGUAGE "Italian"
148 ;!insertmacro MUI_LANGUAGE "Dutch"
149 ;!insertmacro MUI_LANGUAGE "Danish"
150 ;!insertmacro MUI_LANGUAGE "Greek"
151 ;!insertmacro MUI_LANGUAGE "Russian"
152 !insertmacro MUI_LANGUAGE "PortugueseBR"
153 ;!insertmacro MUI_LANGUAGE "Polish"
154 ;!insertmacro MUI_LANGUAGE "Ukrainian"
155 ;!insertmacro MUI_LANGUAGE "Czech"
156 ;!insertmacro MUI_LANGUAGE "Slovak"
157 ;!insertmacro MUI_LANGUAGE "Croatian"
158 ;!insertmacro MUI_LANGUAGE "Bulgarian"
159 ;!insertmacro MUI_LANGUAGE "Hungarian"
160 ;!insertmacro MUI_LANGUAGE "Thai"
161 ;!insertmacro MUI_LANGUAGE "Romanian"
162 ;!insertmacro MUI_LANGUAGE "Macedonian"
163 ;!insertmacro MUI_LANGUAGE "Turkish"
165 ;--------------------------------
169 LangString DESC_SecCopyUI ${LANG_ENGLISH} "OpenAFS for Windows: English"
170 ;LangString DESC_SecCopyUI ${LANG_FRENCH} "OpenAFS for Windows: French"
171 LangString DESC_SecCopyUI ${LANG_GERMAN} "OpenAFS for Windows: German"
172 LangString DESC_SecCopyUI ${LANG_SPANISH} "OpenAFS for Windows: Spanish"
173 LangString DESC_SecCopyUI ${LANG_SIMPCHINESE} "OpenAFS for Windows: Simplified Chinese"
174 LangString DESC_SecCopyUI ${LANG_TRADCHINESE} "OpenAFS for Windows: Traditional Chinese description"
175 LangString DESC_SecCopyUI ${LANG_JAPANESE} "OpenAFS for Windows: Japanese description"
176 LangString DESC_SecCopyUI ${LANG_KOREAN} "OpenAFS for Windows: Korean description"
177 ;LangString DESC_SecCopyUI ${LANG_ITALIAN} "OpenAFS for Windows: Italian description"
178 ;LangString DESC_SecCopyUI ${LANG_DUTCH} "OpenAFS for Windows: Dutch description"
179 ;LangString DESC_SecCopyUI ${LANG_DANISH} "OpenAFS for Windows: Danish description"
180 ;LangString DESC_SecCopyUI ${LANG_GREEK} "OpenAFS for Windows: Greek description"
181 ;LangString DESC_SecCopyUI ${LANG_RUSSIAN} "OpenAFS for Windows: Russian description"
182 LangString DESC_SecCopyUI ${LANG_PORTUGUESEBR} "OpenAFS for Windows: Portuguese (Brasil) description"
183 ;LangString DESC_SecCopyUI ${LANG_POLISH} "OpenAFS for Windows: Polish description"
184 ;LangString DESC_SecCopyUI ${LANG_UKRAINIAN} "OpenAFS for Windows: Ukrainian description"
185 ;LangString DESC_SecCopyUI ${LANG_CZECH} "OpenAFS for Windows: Czechian description"
186 ;LangString DESC_SecCopyUI ${LANG_SLOVAK} "OpenAFS for Windows: Slovakian description"
187 ;LangString DESC_SecCopyUI ${LANG_CROATIAN} "OpenAFS for Windows: Slovakian description"
188 ;LangString DESC_SecCopyUI ${LANG_BULGARIAN} "OpenAFS for Windows: Bulgarian description"
189 ;LangString DESC_SecCopyUI ${LANG_HUNGARIAN} "OpenAFS for Windows: Hungarian description"
190 ;LangString DESC_SecCopyUI ${LANG_THAI} "OpenAFS for Windows: Thai description"
191 ;LangString DESC_SecCopyUI ${LANG_ROMANIAN} "OpenAFS for Windows: Romanian description"
192 ;LangString DESC_SecCopyUI ${LANG_MACEDONIAN} "OpenAFS for Windows: Macedonian description"
193 ;LangString DESC_SecCopyUI ${LANG_TURKISH} "OpenAFS for Windows: Turkish description"
195 LangString DESC_secClient ${LANG_ENGLISH} "OpenAFS Client: Allows you to access AFS from your Windows PC."
196 LangString DESC_secClient ${LANG_GERMAN} "OpenAFS Client: Allows you to access AFS from your Windows PC."
197 LangString DESC_secClient ${LANG_SPANISH} "OpenAFS Client: Allows you to access AFS from your Windows PC."
198 LangString DESC_secClient ${LANG_SIMPCHINESE} "OpenAFS Client: Allows you to access AFS from your Windows PC."
199 LangString DESC_secClient ${LANG_TRADCHINESE} "OpenAFS Client: Allows you to access AFS from your Windows PC."
200 LangString DESC_secClient ${LANG_JAPANESE} "OpenAFS Client: Allows you to access AFS from your Windows PC."
201 LangString DESC_secClient ${LANG_KOREAN} "OpenAFS Client: Allows you to access AFS from your Windows PC."
202 LangString DESC_secClient ${LANG_PORTUGUESEBR} "OpenAFS Client: Allows you to access AFS from your Windows PC."
204 LangString DESC_secLoopback ${LANG_ENGLISH} "MS Loopback adapter: Installs the adapter for a more reliable AFS client."
205 LangString DESC_secLoopback ${LANG_GERMAN} "MS Loopback adapter: Installs the adapter for a more reliable AFS client."
206 LangString DESC_secLoopback ${LANG_SPANISH} "MS Loopback adapter: Installs the adapter for a more reliable AFS client."
207 LangString DESC_secLoopback ${LANG_SIMPCHINESE} "MS Loopback adapter: Installs the adapter for a more reliable AFS client."
208 LangString DESC_secLoopback ${LANG_TRADCHINESE} "MS Loopback adapter: Installs the adapter for a more reliable AFS client."
209 LangString DESC_secLoopback ${LANG_JAPANESE} "MS Loopback adapter: Installs the adapter for a more reliable AFS client."
210 LangString DESC_secLoopback ${LANG_KOREAN} "MS Loopback adapter: Installs the adapter for a more reliable AFS client."
211 LangString DESC_secLoopback ${LANG_PORTUGUESEBR} "MS Loopback adapter: Installs the adapter for a more reliable AFS client."
213 LangString DESC_secServer ${LANG_ENGLISH} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
214 LangString DESC_secServer ${LANG_GERMAN} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
215 LangString DESC_secServer ${LANG_SPANISH} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
216 LangString DESC_secServer ${LANG_SIMPCHINESE} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
217 LangString DESC_secServer ${LANG_TRADCHINESE} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
218 LangString DESC_secServer ${LANG_JAPANESE} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
219 LangString DESC_secServer ${LANG_KOREAN} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
220 LangString DESC_secServer ${LANG_PORTUGUESEBR} "OpenAFS Server: Allows you to run an AFS file server. This option requires the AFS Client."
222 LangString DESC_secControl ${LANG_ENGLISH} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
223 LangString DESC_secControl ${LANG_GERMAN} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
224 LangString DESC_secControl ${LANG_SPANISH} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
225 LangString DESC_secControl ${LANG_SIMPCHINESE} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
226 LangString DESC_secControl ${LANG_TRADCHINESE} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
227 LangString DESC_secControl ${LANG_JAPANESE} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
228 LangString DESC_secControl ${LANG_KOREAN} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
229 LangString DESC_secControl ${LANG_PORTUGUESEBR} "Control Center: GUI utilities for managing and configuring AFS servers. This option requires the AFS Client."
231 LangString DESC_secDocs ${LANG_ENGLISH} "Supplemental Documentation: Additional documentation for using OpenAFS."
232 LangString DESC_secDocs ${LANG_GERMAN} "Supplemental Documentation: Additional documentation for using OpenAFS."
233 LangString DESC_secDocs ${LANG_SPANISH} "Supplemental Documentation: Additional documentation for using OpenAFS."
234 LangString DESC_secDocs ${LANG_SIMPCHINESE} "Supplemental Documentation: Additional documentation for using OpenAFS."
235 LangString DESC_secDocs ${LANG_TRADCHINESE} "Supplemental Documentation: Additional documentation for using OpenAFS."
236 LangString DESC_secDocs ${LANG_JAPANESE} "Supplemental Documentation: Additional documentation for using OpenAFS."
237 LangString DESC_secDocs ${LANG_KOREAN} "Supplemental Documentation: Additional documentation for using OpenAFS."
238 LangString DESC_secDocs ${LANG_PORTUGUESEBR} "Supplemental Documentation: Additional documentation for using OpenAFS."
240 LangString DESC_secSDK ${LANG_ENGLISH} "SDK: Header files and libraries for developing software with OpenAFS."
241 LangString DESC_secSDK ${LANG_GERMAN} "SDK: Header files and libraries for developing software with OpenAFS."
242 LangString DESC_secSDK ${LANG_SPANISH} "SDK: Header files and libraries for developing software with OpenAFS."
243 LangString DESC_secSDK ${LANG_SIMPCHINESE} "SDK: Header files and libraries for developing software with OpenAFS."
244 LangString DESC_secSDK ${LANG_TRADCHINESE} "SDK: Header files and libraries for developing software with OpenAFS."
245 LangString DESC_secSDK ${LANG_JAPANESE} "SDK: Header files and libraries for developing software with OpenAFS."
246 LangString DESC_secSDK ${LANG_KOREAN} "SDK: Header files and libraries for developing software with OpenAFS."
247 LangString DESC_secSDK ${LANG_PORTUGUESEBR} "SDK: Header files and libraries for developing software with OpenAFS."
249 LangString DESC_secDEBUG ${LANG_ENGLISH} "Debug symbols: Used for debugging problems with OpenAFS."
250 LangString DESC_secDEBUG ${LANG_GERMAN} "Debug symbols: Used for debugging problems with OpenAFS."
251 LangString DESC_secDEBUG ${LANG_SPANISH} "Debug symbols: Used for debugging problems with OpenAFS."
252 LangString DESC_secDEBUG ${LANG_SIMPCHINESE} "Debug symbols: Used for debugging problems with OpenAFS."
253 LangString DESC_secDEBUG ${LANG_TRADCHINESE} "Debug symbols: Used for debugging problems with OpenAFS."
254 LangString DESC_secDEBUG ${LANG_JAPANESE} "Debug symbols: Used for debugging problems with OpenAFS."
255 LangString DESC_secDEBUG ${LANG_KOREAN} "Debug symbols: Used for debugging problems with OpenAFS."
256 LangString DESC_secDEBUG ${LANG_PORTUGUESEBR} "Debug symbols: Used for debugging problems with OpenAFS."
258 ; Popup error messages
259 LangString CellError ${LANG_ENGLISH} "You must specify a valid CellServDB file to copy during install"
260 LangString CellError ${LANG_GERMAN} "You must specify a valid CellServDB file to copy during the install"
261 LangString CellError ${LANG_SPANISH} "You must specify a valid CellServDB file to copy during the install"
262 LangString CellError ${LANG_SIMPCHINESE} "You must specify a valid CellServDB file to copy during the install"
263 LangString CellError ${LANG_TRADCHINESE} "You must specify a valid CellServDB file to copy during the install"
264 LangString CellError ${LANG_JAPANESE} "You must specify a valid CellServDB file to copy during the install"
265 LangString CellError ${LANG_KOREAN} "You must specify a valid CellServDB file to copy during the install"
266 LangString CellError ${LANG_PORTUGUESEBR} "You must specify a valid CellServDB file to copy during the install"
268 LangString CellNameError ${LANG_ENGLISH} "You must specify a cell name for your client to use."
269 LangString CellNameError ${LANG_GERMAN} "You must specify a cell name for your client to use."
270 LangString CellNameError ${LANG_SPANISH} "You must specify a cell name for your client to use."
271 LangString CellNameError ${LANG_SIMPCHINESE} "You must specify a cell name for your client to use."
272 LangString CellNameError ${LANG_TRADCHINESE} "You must specify a cell name for your client to use."
273 LangString CellNameError ${LANG_JAPANESE} "You must specify a cell name for your client to use."
274 LangString CellNameError ${LANG_KOREAN} "You must specify a cell name for your client to use."
275 LangString CellNameError ${LANG_PORTUGUESEBR} "You must specify a cell name for your client to use."
277 LangString URLError ${LANG_ENGLISH} "You must specify a URL if you choose the option to download the CellServDB."
278 LangString URLError ${LANG_GERMAN} "You must specify a URL if you choose the option to download the CellServDB."
279 LangString URLError ${LANG_SPANISH} "You must specify a URL if you choose the option to download the CellServDB."
280 LangString URLError ${LANG_SIMPCHINESE} "You must specify a URL if you choose the option to download the CellServDB."
281 LangString URLError ${LANG_TRADCHINESE} "You must specify a URL if you choose the option to download the CellServDB."
282 LangString URLError ${LANG_JAPANESE} "You must specify a URL if you choose the option to download the CellServDB."
283 LangString URLError ${LANG_KOREAN} "You must specify a URL if you choose the option to download the CellServDB."
284 LangString URLError ${LANG_PORTUGUESEBR} "You must specify a URL if you choose the option to download the CellServDB."
287 ; Upgrade/re-install strings
288 LangString UPGRADE_CLIENT ${LANG_ENGLISH} "Upgrade AFS Client"
289 LangString UPGRADE_CLIENT ${LANG_GERMAN} "Upgrade AFS Client"
290 LangString UPGRADE_CLIENT ${LANG_SPANISH} "Upgrade AFS Client"
291 LangString UPGRADE_CLIENT ${LANG_SIMPCHINESE} "Upgrade AFS Client"
292 LangString UPGRADE_CLIENT ${LANG_TRADCHINESE} "Upgrade AFS Client"
293 LangString UPGRADE_CLIENT ${LANG_JAPANESE} "Upgrade AFS Client"
294 LangString UPGRADE_CLIENT ${LANG_KOREAN} "Upgrade AFS Client"
295 LangString UPGRADE_CLIENT ${LANG_PORTUGUESEBR} "Upgrade AFS Client"
297 LangString REINSTALL_CLIENT ${LANG_ENGLISH} "Re-install AFS Client"
298 LangString REINSTALL_CLIENT ${LANG_GERMAN} "Re-install AFS Client"
299 LangString REINSTALL_CLIENT ${LANG_SPANISH} "Re-install AFS Client"
300 LangString REINSTALL_CLIENT ${LANG_SIMPCHINESE} "Re-install AFS Client"
301 LangString REINSTALL_CLIENT ${LANG_TRADCHINESE} "Re-install AFS Client"
302 LangString REINSTALL_CLIENT ${LANG_JAPANESE} "Re-install AFS Client"
303 LangString REINSTALL_CLIENT ${LANG_KOREAN} "Re-install AFS Client"
304 LangString REINSTALL_CLIENT ${LANG_PORTUGUESEBR} "Re-install AFS Client"
306 LangString UPGRADE_SERVER ${LANG_ENGLISH} "Upgrade AFS Server"
307 LangString UPGRADE_SERVER ${LANG_GERMAN} "Upgrade AFS Server"
308 LangString UPGRADE_SERVER ${LANG_SPANISH} "Upgrade AFS Server"
309 LangString UPGRADE_SERVER ${LANG_SIMPCHINESE} "Upgrade AFS Server"
310 LangString UPGRADE_SERVER ${LANG_TRADCHINESE} "Upgrade AFS Server"
311 LangString UPGRADE_SERVER ${LANG_JAPANESE} "Upgrade AFS Server"
312 LangString UPGRADE_SERVER ${LANG_KOREAN} "Upgrade AFS Server"
313 LangString UPGRADE_SERVER ${LANG_PORTUGUESEBR} "Upgrade AFS Server"
315 LangString REINSTALL_SERVER ${LANG_ENGLISH} "Re-install AFS Server"
316 LangString REINSTALL_SERVER ${LANG_GERMAN} "Re-install AFS Server"
317 LangString REINSTALL_SERVER ${LANG_SPANISH} "Re-install AFS Server"
318 LangString REINSTALL_SERVER ${LANG_SIMPCHINESE} "Re-install AFS Server"
319 LangString REINSTALL_SERVER ${LANG_TRADCHINESE} "Re-install AFS Server"
320 LangString REINSTALL_SERVER ${LANG_JAPANESE} "Re-install AFS Server"
321 LangString REINSTALL_SERVER ${LANG_KOREAN} "Re-install AFS Server"
322 LangString REINSTALL_SERVER ${LANG_PORTUGUESEBR} "Re-install AFS Server"
324 ReserveFile "CellServPage.ini"
325 ReserveFile "AFSCell.ini"
326 !insertmacro MUI_RESERVEFILE_INSTALLOPTIONS ;InstallOptions plug-in
327 !insertmacro MUI_RESERVEFILE_LANGDLL ;Language selection dialog
328 ;--------------------------------
330 ; Macro - Upgrade DLL File
331 ; Written by Joost Verburg
332 ; ------------------------
335 ; LOCALFILE - Location of the new DLL file (on the compiler system)
336 ; DESTFILE - Location of the DLL file that should be upgraded
337 ; (on the user's system)
338 ; TEMPBASEDIR - Directory on the user's system to store a temporary file
339 ; when the system has to be rebooted.
340 ; For Win9x support, this should be on the same volume as the
342 ; The Windows temp directory could be located on any volume,
343 ; so you cannot use this directory.
345 ; Define REPLACEDLL_NOREGISTER if you want to upgrade a DLL that does not
346 ; have to be registered.
348 ; Note: If you want to support Win9x, you can only use
349 ; short filenames (8.3).
352 ; !insertmacro ReplaceDLL "dllname.dll" "$SYSDIR\dllname.dll" "$SYSDIR"
355 !macro ReplaceDLL LOCALFILE DESTFILE TEMPBASEDIR
364 ;------------------------
365 ;Unique number for labels
367 !define REPLACEDLL_UNIQUE ${__LINE__}
369 ;------------------------
370 ;Copy the parameters used on run-time to a variable
371 ;This allows the usage of variables as paramter
373 StrCpy $R4 "${DESTFILE}"
374 StrCpy $R5 "${TEMPBASEDIR}"
376 ;------------------------
377 ;Check file and version
379 IfFileExists $R4 0 replacedll.copy_${REPLACEDLL_UNIQUE}
382 ; GetDLLVersionLocal "${LOCALFILE}" $R0 $R1
383 ; GetDLLVersion $R4 $R2 $R3
384 ;IfErrors replacedll.upgrade_${REPLACEDLL_UNIQUE}
386 ;IntCmpU $R0 $R2 0 replacedll.done_${REPLACEDLL_UNIQUE} \
387 ; replacedll.upgrade_${REPLACEDLL_UNIQUE}
388 ;IntCmpU $R1 $R3 replacedll.done_${REPLACEDLL_UNIQUE} \
389 ; replacedll.done_${REPLACEDLL_UNIQUE} \
390 ; replacedll.upgrade_${REPLACEDLL_UNIQUE}
392 ;------------------------
393 ;Let's replace the DLL!
397 ;replacedll.upgrade_${REPLACEDLL_UNIQUE}:
398 !ifndef REPLACEDLL_NOREGISTER
403 ;------------------------
404 ;Try to copy the DLL directly
408 Call :replacedll.file_${REPLACEDLL_UNIQUE}
409 IfErrors 0 replacedll.noreboot_${REPLACEDLL_UNIQUE}
411 ;------------------------
412 ;DLL is in use. Copy it to a temp file and Rename it on reboot.
414 GetTempFileName $R0 $R5
415 Call :replacedll.file_${REPLACEDLL_UNIQUE}
416 Rename /REBOOTOK $R0 $R4
418 ;------------------------
419 ;Register the DLL on reboot
421 !ifndef REPLACEDLL_NOREGISTER
422 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\RunOnce" \
423 "Register $R4" 'rundll32.exe "$R4",DllRegisterServer'
426 Goto replacedll.done_${REPLACEDLL_UNIQUE}
428 ;------------------------
429 ;DLL does not exist - just extract
431 replacedll.copy_${REPLACEDLL_UNIQUE}:
433 Call :replacedll.file_${REPLACEDLL_UNIQUE}
435 ;------------------------
438 replacedll.noreboot_${REPLACEDLL_UNIQUE}:
439 !ifndef REPLACEDLL_NOREGISTER
443 ;------------------------
446 replacedll.done_${REPLACEDLL_UNIQUE}:
455 ;------------------------
458 Goto replacedll.end_${REPLACEDLL_UNIQUE}
460 ;------------------------
461 ;Called to extract the DLL
463 replacedll.file_${REPLACEDLL_UNIQUE}:
464 File /oname=$R0 "${LOCALFILE}"
467 replacedll.end_${REPLACEDLL_UNIQUE}:
469 ;------------------------
472 SetOverwrite lastused
474 !undef REPLACEDLL_UNIQUE
479 ;--------------------------------
482 ;Things that need to be extracted on first (keep these lines before any File command!)
483 ;Only useful for BZIP2 compression
484 !insertmacro MUI_RESERVEFILE_LANGDLL
486 ;--------------------------------
497 ;--------------------------------
500 ;----------------------
502 Section "!AFS Client" secClient
504 SetShellVarContext all
506 ; Check for bad previous installation (if we are doing a new install)
507 Call IsAnyAFSInstalled
509 StrCmp $R0 "0" +1 skipCheck
513 ; Stop any running services or we can't replace the files
514 ; Stop the running processes
516 File /oname=$R0 "${AFS_WININSTALL_DIR}\Killer.exe" ; Might not have the MSVCR71.DLL file to run
517 nsExec::Exec '$R0 afsd_service.exe'
518 nsExec::Exec '$R0 afscreds.exe'
519 Exec "afscreds.exe -z"
520 ; in case we are upgrading an old version that does not support -z
521 nsExec::Exec '$R0 afscreds.exe'
523 ;nsExec::Exec '$R0 krbcc32s.exe'
526 nsExec::Exec "net stop TransarcAFSDaemon"
527 nsExec::Exec "net stop TransarcAFSServer"
529 ; Do client components
530 SetOutPath "$INSTDIR\Client\Program"
531 File "${AFS_CLIENT_BUILDDIR}\afsshare.exe"
532 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\libosi.dll" "$INSTDIR\Client\Program\libosi.dll" "$INSTDIR"
533 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\libafsconf.dll" "$INSTDIR\Client\Program\libafsconf.dll" "$INSTDIR"
534 File "${AFS_CLIENT_BUILDDIR}\klog.exe"
535 File "${AFS_CLIENT_BUILDDIR}\tokens.exe"
536 File "${AFS_CLIENT_BUILDDIR}\unlog.exe"
537 File "${AFS_CLIENT_BUILDDIR}\fs.exe"
538 File "${AFS_CLIENT_BUILDDIR}\afsdacl.exe"
539 File "${AFS_CLIENT_BUILDDIR}\cmdebug.exe"
540 File "${AFS_CLIENT_BUILDDIR}\aklog.exe"
541 File "${AFS_CLIENT_BUILDDIR}\afscreds.exe"
542 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext.dll" "$INSTDIR\Client\Program\afs_shl_ext.dll" "$INSTDIR"
543 File "${AFS_CLIENT_BUILDDIR}\afsd_service.exe"
544 File "${AFS_CLIENT_BUILDDIR}\symlink.exe"
545 File "${AFS_DESTDIR}\bin\kpasswd.exe"
546 File "${AFS_SERVER_BUILDDIR}\pts.exe"
547 File "${AFS_SERVER_BUILDDIR}\bos.exe"
548 File "${AFS_SERVER_BUILDDIR}\kas.exe"
549 File "${AFS_SERVER_BUILDDIR}\vos.exe"
550 File "${AFS_SERVER_BUILDDIR}\udebug.exe"
551 File "${AFS_DESTDIR}\bin\translate_et.exe"
552 File "${AFS_DESTDIR}\etc\rxdebug.exe"
553 File "${AFS_DESTDIR}\etc\backup.exe"
554 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa.cpl" "$INSTDIR\Client\Program\afs_cpa.cpl" "$INSTDIR"
557 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afslogon.dll" "$SYSDIR\afslogon.dll" "$INSTDIR"
558 File "${AFS_CLIENT_BUILDDIR}\afscpcc.exe"
561 !insertmacro ReplaceDLL "..\..\afsrdr\objfre_w2K_x86\i386\afsrdr.sys" "$SYSDIR\DRIVERS\afsrdr.sys" "$INSTDIR"
563 !insertmacro ReplaceDLL "..\..\afsrdr\objchk_w2K_x86\i386\afsrdr.sys" "$SYSDIR\DRIVERS\afsrdr.sys" "$INSTDIR"
569 ; Get AFS CellServDB file
570 Call afs.GetCellServDB
573 File /oname=$R0 "${AFS_WININSTALL_DIR}\AdminGroup.exe"
574 nsExec::Exec '$R0 -create'
577 ; Include Kerberos for Windows files in the installer...
578 SetOutPath "$INSTDIR\kfw\bin\"
579 File "${KFW_SOURCE}\bin\*"
580 SetOutPath "$INSTDIR\kfw\doc"
581 File "${KFW_SOURCE}\doc\*"
584 ;Store install folder
585 WriteRegStr HKCU "${AFS_REGKEY_ROOT}\Client" "" $INSTDIR
586 Call AFSCommon.Install
588 ; Write registry entries
589 WriteRegStr HKCR "*\shellex\ContextMenuHandlers\AFS Client Shell Extension" "" "{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}"
590 WriteRegStr HKCR "CLSID\{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}" "" "AFS Client Shell Extension"
591 WriteRegStr HKCR "CLSID\{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}\InprocServer32" "" "$INSTDIR\Client\Program\afs_shl_ext.dll"
592 WriteRegStr HKCR "CLSID\{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}\InprocServer32" "ThreadingModel" "Apartment"
593 WriteRegStr HKCR "FOLDER\shellex\ContextMenuHandlers\AFS Client Shell Extension" "" "{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}"
594 WriteRegStr HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Shell Extensions\Approved" "{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}" "AFS Client Shell Extension"
595 WriteRegStr HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Control Panel\Cpls" "afs_cpa" "$INSTDIR\Client\Program\afs_cpa.cpl"
597 ; Support for apps that wrote submount data directly to afsdsbmt.ini
598 WriteRegStr HKLM "SOFTWARE\Microsoft\Windows NT\CurrentVersion\IniFileMapping\afsdsbmt.ini" "AFS Mappings" "USR:Software\OpenAFS\Client\mappings"
599 WriteRegStr HKLM "SOFTWARE\Microsoft\Windows NT\CurrentVersion\IniFileMapping\afsdsbmt.ini" "AFS Submounts" "SYS:OpenAFS\Client\Submounts"
602 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion"
603 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "VersionString" ${AFS_VERSION}
604 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "Title" "AFS Client"
605 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "Description" "AFS Client"
606 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "PathName" "$INSTDIR\Client"
607 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "Software Type" "File System"
608 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "MajorVersion" ${AFS_MAJORVERSION}
609 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "MinorVersion" ${AFS_MINORVERSION}
610 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "PatchLevel" ${AFS_PATCHLEVEL}
611 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "VersionString" ${AFS_VERSION}
612 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "Title" "AFS Client"
613 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "Description" "AFS Client"
614 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "Software Type" "File System"
615 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "PathName" "$INSTDIR\Client\Program"
616 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "MajorVersion" ${AFS_MAJORVERSION}
617 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "MinorVersion" ${AFS_MINORVERSION}
618 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "PatchLevel" ${AFS_PATCHLEVEL}
620 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "Debug" 1
621 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "Debug" 1
623 ; Delete the DEBUG string
624 DeleteRegValue HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "Debug"
625 DeleteRegValue HKLM "${AFS_REGKEY_ROOT}\AFS Client\${AFS_VERSION}" "Debug"
628 ; On Windows 2000 work around KB301673. This is fixed in Windows XP and 2003
629 Call GetWindowsVersion
631 StrCmp $R1 "2000" +1 +2
632 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\NetBT\Parameters" "SmbDeviceEnabled" 0
634 ;Write start menu entries
635 CreateDirectory "$SMPROGRAMS\OpenAFS\Client"
636 CreateShortCut "$SMPROGRAMS\OpenAFS\Uninstall OpenAFS.lnk" "$INSTDIR\Uninstall.exe"
638 ; Create command line options for AFSCreds...
640 ReadINIStr $R1 $2 "Field 3" "State"
643 ReadINIStr $R1 $2 "Field 5" "State"
646 ReadINIStr $R1 $2 "Field 7" "State"
649 ReadINIStr $R1 $2 "Field 9" "State"
652 ReadINIStr $R1 $2 "Field 13" "State"
656 WriteRegStr HKLM "SOFTWARE\OpenAFS\Client" "AfscredsShortcutParams" "$R2"
658 CreateShortCut "$SMPROGRAMS\OpenAFS\Client\Authentication.lnk" "$INSTDIR\Client\Program\afscreds.exe" "$R2"
660 ReadINIStr $R1 $2 "Field 1" "State"
662 CreateShortCut "$SMSTARTUP\AFS Credentials.lnk" "$INSTDIR\Client\Program\afscreds.exe" "$R2"
664 Push "$INSTDIR\Client\Program"
666 Push "$INSTDIR\Common"
670 ; Add kfw to path too
671 Push "$INSTDIR\kfw\bin"
675 ; Create the AFS service
676 SetOutPath "$INSTDIR\Common"
677 File "${AFS_WININSTALL_DIR}\Service.exe"
678 nsExec::Exec "net stop TransarcAFSDaemon"
679 nsExec::Exec "net stop AfsRdr"
680 ;IMPORTANT! If we are not refreshing the config files, do NOT remove the service
681 ;Don't re-install because it must be present or we wouldn't have passed the Reg check
683 ReadRegStr $R2 HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "Cell"
684 StrCmp $R2 "" +1 skipremove
685 nsExec::Exec '$INSTDIR\Common\Service.exe u TransarcAFSDaemon'
686 nsExec::Exec '$INSTDIR\Common\Service.exe TransarcAFSDaemon "$INSTDIR\Client\Program\afsd_service.exe" "OpenAFS Client Service"'
687 nsExec::Exec '$INSTDIR\Common\Service.exe u AfsRdr'
689 nsExec::Exec '$INSTDIR\Common\Service.exe AfsRdr "System32\DRIVERS\afsrdr.sys" "AFS Redirector"'
692 Delete "$INSTDIR\Common\service.exe"
695 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon" "" ""
696 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "ProviderPath" "$SYSDIR\afslogon.dll"
697 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "AuthentProviderPath" "$SYSDIR\afslogon.dll"
698 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "Class" 2
699 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "VerboseLogging" 10
701 ; Must also add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\NetworkProvider\HwOrder
702 ; and HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\NetworkProvider\Order
703 ; to also include the service name.
705 ReadINIStr $R0 $1 "Field 7" "State"
706 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "LogonOptions" $R0
707 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "LogonScript" "$INSTDIR\Client\Program\afscreds.exe -:%s -x -a -m -n -q"
708 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\NetworkProvider" "Name" "OpenAFSDaemon"
711 ReadINIStr $R0 $1 "Field 2" "State"
712 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "Cell" $R0
713 ReadINIStr $R0 $1 "Field 3" "State"
714 WriteRegDWORD HKLM "SOFTWARE\OpenAFS\Client" "ShowTrayIcon" 1
715 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "SecurityLevel" $R0
716 ReadINIStr $R0 $1 "Field 5" "State"
717 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "FreelanceClient" $R0
718 ReadINIStr $R0 $1 "Field 9" "State"
719 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "UseDNS" $R0
720 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "NetbiosName" "AFS"
721 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "MountRoot" "/afs"
722 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "RxMaxMTU" 1260
723 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "IsGateway" 0
724 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "HideDotFiles" 1
726 ; Find Lana By Name appears to be causing grief for many people
727 ; I do not have time to track this down so I am simply going to disable it
728 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "NoFindLanaByName" 1
730 strcpy $REG_SUB_KEY "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon"
731 strcpy $REG_VALUE "DependOnGroup"
732 strcpy $REG_DATA_1 "PNP_TDI"
733 strcpy $REG_DATA_2 ""
734 strcpy $REG_DATA_3 ""
735 strcpy $REG_DATA_4 ""
736 Call RegWriteMultiStr
737 strcpy $REG_SUB_KEY "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon"
738 strcpy $REG_VALUE "DependOnService"
739 strcpy $REG_DATA_1 "Tcpip"
740 strcpy $REG_DATA_2 "NETBIOS"
741 strcpy $REG_DATA_3 "RpcSs"
743 strcpy $REG_DATA_4 "AfsRdr"
745 strcpy $REG_DATA_4 ""
747 Call RegWriteMultiStr
749 strcpy $REG_SUB_KEY "SYSTEM\CurrentControlSet\Services\AfsRdr"
750 strcpy $REG_VALUE "DependOnService"
751 strcpy $REG_DATA_1 "Tcpip"
752 strcpy $REG_DATA_2 ""
753 strcpy $REG_DATA_3 ""
754 strcpy $REG_DATA_4 ""
755 Call RegWriteMultiStr
758 ; WinLogon Event Notification
759 WriteRegDWORD HKLM "Software\Microsoft\Windows NT\CurrentVersion\WinLogon\Notify\AfsLogon" "Asynchronous" 0
760 WriteRegDWORD HKLM "Software\Microsoft\Windows NT\CurrentVersion\WinLogon\Notify\AfsLogon" "Impersonate" 1
761 WriteRegStr HKLM "Software\Microsoft\Windows NT\CurrentVersion\WinLogon\Notify\AfsLogon" "DLLName" "afslogon.dll"
762 WriteRegStr HKLM "Software\Microsoft\Windows NT\CurrentVersion\WinLogon\Notify\AfsLogon" "Logon" "AFS_Logon_Event"
763 WriteRegStr HKLM "Software\Microsoft\Windows NT\CurrentVersion\WinLogon\Notify\AfsLogon" "Logoff" "AFS_Logoff_Event"
764 WriteRegStr HKLM "Software\Microsoft\Windows NT\CurrentVersion\WinLogon\Notify\AfsLogon" "Startup" "AFS_Startup_Event"
766 WriteRegDWORD HKLM "Software\Microsoft\Windows NT\CurrentVersion\WinLogon\Notify\KFWLogon" "Asynchronous" 0
767 WriteRegDWORD HKLM "Software\Microsoft\Windows NT\CurrentVersion\WinLogon\Notify\KFWLogon" "Impersonate" 0
768 WriteRegStr HKLM "Software\Microsoft\Windows NT\CurrentVersion\WinLogon\Notify\KFWLogon" "DLLName" "afslogon.dll"
769 WriteRegStr HKLM "Software\Microsoft\Windows NT\CurrentVersion\WinLogon\Notify\KFWLogon" "Logon" "KFW_Logon_Event"
773 WriteUninstaller "$INSTDIR\Uninstall.exe"
774 WriteRegStr HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "DisplayIcon" "$INSTDIR\Uninstall.exe,0"
775 Call CreateDesktopIni
781 ; MS Loopback adapter
782 Section "!MS Loopback Adapter" secLoopback
784 Call afs.InstallMSLoopback
789 ;------------------------
791 Section /o "AFS Server" secServer
793 SetShellVarContext all
795 ; Check for bad previous installation (if we are doing a new install)
796 Call IsAnyAFSInstalled
798 StrCmp $R0 "0" +1 skipCheck
802 ; Stop any running services or we can't replace the files
803 ; Stop the running processes
805 File /oname=$R0 "${AFS_WININSTALL_DIR}\Killer.exe"
806 nsExec::Exec '$R0 afscreds.exe'
807 Exec "afscreds.exe -z"
808 ; in case we are upgrading an old version that does not support -z
810 nsExec::Exec '$R0 afscreds.exe'
812 ;nsExec::Exec '$R0 krbcc32s.exe'
817 nsExec::Exec "net stop TransarcAFSDaemon"
818 nsExec::Exec "net stop TransarcAFSServer"
820 CreateDirectory "$INSTDIR\Server\usr\afs\etc"
821 CreateDirectory "$INSTDIR\Server\usr\afs\local"
822 CreateDirectory "$INSTDIR\Server\usr\afs\etc\logs"
824 SetOutPath "$INSTDIR\Server\usr\afs\bin"
825 File "${AFS_SERVER_BUILDDIR}\afskill.exe"
826 File "${AFS_SERVER_BUILDDIR}\afssvrcfg.exe"
827 File "${AFS_SERVER_BUILDDIR}\asetkey.exe"
828 File "${AFS_SERVER_BUILDDIR}\bosctlsvc.exe"
829 File "${AFS_SERVER_BUILDDIR}\bosserver.exe"
830 File "${AFS_SERVER_BUILDDIR}\buserver.exe"
831 File "${AFS_ETC_BUILDDIR}\butc.exe"
832 File "${AFS_SERVER_BUILDDIR}\fileserver.exe"
833 File "${AFS_ETC_BUILDDIR}\fms.exe"
834 File "${AFS_SERVER_BUILDDIR}\kaserver.exe"
835 File "${AFS_SERVER_BUILDDIR}\ptserver.exe"
836 File "${AFS_SERVER_BUILDDIR}\salvager.exe"
837 File "${AFS_SERVER_BUILDDIR}\upclient.exe"
838 File "${AFS_SERVER_BUILDDIR}\upserver.exe"
839 File "${AFS_SERVER_BUILDDIR}\vlserver.exe"
840 File "${AFS_SERVER_BUILDDIR}\volinfo.exe"
841 File "${AFS_SERVER_BUILDDIR}\volserver.exe"
843 ;AFS Server common files
844 SetOutPath "$INSTDIR\Common"
845 File "${AFS_SERVER_BUILDDIR}\afsvosadmin.dll"
846 File "${AFS_SERVER_BUILDDIR}\afsbosadmin.dll"
847 File "${AFS_SERVER_BUILDDIR}\afscfgadmin.dll"
848 File "${AFS_SERVER_BUILDDIR}\afskasadmin.dll"
849 File "${AFS_SERVER_BUILDDIR}\afsptsadmin.dll"
851 SetOutPath "$INSTDIR\Common"
855 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver.cpl" "$SYSDIR\afsserver.cpl" "$INSTDIR"
857 ;Store install folder
858 WriteRegStr HKCU "${AFS_REGKEY_ROOT}\AFS Server" "" $INSTDIR
860 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion"
861 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "VersionString" ${AFS_VERSION}
862 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "Title" "AFS Server"
863 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "Description" "AFS Server for Windows"
864 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "PathName" "$INSTDIR\Server"
865 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "Software Type" "File System"
866 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "MajorVersion" ${AFS_MAJORVERSION}
867 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "MinorVersion" ${AFS_MINORVERSION}
868 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "PatchLevel" ${AFS_PATCHLEVEL}
869 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "VersionString" ${AFS_VERSION}
870 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "Title" "AFS Server"
871 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "Description" "AFS Server for Windows"
872 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "Software Type" "File System"
873 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "PathName" "$INSTDIR\Server"
874 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "MajorVersion" ${AFS_MAJORVERSION}
875 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "MinorVersion" ${AFS_MINORVERSION}
876 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "PatchLevel" ${AFS_PATCHLEVEL}
878 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "Debug" 1
879 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "Debug" 1
881 ; Delete the DEBUG string
882 DeleteRegValue HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "Debug"
883 DeleteRegValue HKLM "${AFS_REGKEY_ROOT}\AFS Server\${AFS_VERSION}" "Debug"
885 ; Install the service
886 SetOutPath "$INSTDIR\Common"
887 File "${AFS_WININSTALL_DIR}\Service.exe"
889 File "${AFS_WININSTALL_DIR}\Service.pdb"
892 ; Check if the service exists--if it does, this is an upgrade/re-install
893 ReadRegStr $R0 HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSServer" "ImagePath"
894 StrCmp $R0 "$INSTDIR\Server\usr\afs\bin\bosctlsvc.exe" SkipStartup
896 ; If an uninstall was done, but we kept the config files, also skip
897 IfFileExists "$INSTDIR\Server\usr\afs\etc\ThisCell" SkipStartup
899 ; Make the server config wizard auto-start on bootup if this is an install (not an upgrade)
900 WriteRegStr HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce" "AFS Server Wizard" '"$INSTDIR\Server\usr\afs\bin\afssvrcfg.exe" /wizard"'
904 ;Don't want to whack existing settings... Make users un-install and then re-install if they want that
905 ;nsExec::Exec '$INSTDIR\Common\service.exe u TransarcAFSServer'
906 nsExec::Exec '$INSTDIR\Common\service.exe TransarcAFSServer "$INSTDIR\Server\usr\afs\bin\bosctlsvc.exe" "OpenAFS AFS Server"'
907 Delete "$INSTDIR\Common\service.exe"
909 CreateDirectory "$SMPROGRAMS\OpenAFS\Server"
910 CreateShortCut "$SMPROGRAMS\OpenAFS\Server\Server Configuration.lnk" "$INSTDIR\Server\usr\afs\bin\afssvrcfg.exe"
913 WriteUninstaller "$INSTDIR\Uninstall.exe"
914 WriteRegStr HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "DisplayIcon" "$INSTDIR\Uninstall.exe,0"
919 ;----------------------------
920 ; OpenAFS Control Center
921 Section /o "AFS Control Center" secControl
923 SetShellVarContext all
925 SetOutPath "$INSTDIR\Control Center"
926 File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager.exe"
927 File "${AFS_SERVER_BUILDDIR}\TaAfsAdmSvr.exe"
928 File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager.exe"
931 ;AFS Server common files
932 Call AFSCommon.Install
934 SetOutPath "$INSTDIR\Common"
936 ;Store install folder
937 WriteRegStr HKCU "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "PathName" $INSTDIR
938 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "VersionString" ${AFS_VERSION}
939 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "MajorVersion" ${AFS_MAJORVERSION}
940 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "MinorVersion" ${AFS_MINORVERSION}
941 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "PatchLevel" ${AFS_PATCHLEVEL}
942 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "VersionString" ${AFS_VERSION}
943 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "MajorVersion" ${AFS_MAJORVERSION}
944 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "MinorVersion" ${AFS_MINORVERSION}
945 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "PatchLevel" ${AFS_PATCHLEVEL}
947 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "Debug" 1
948 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "Debug" 1
950 ; Delete the DEBUG string
951 DeleteRegValue HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "Debug"
952 DeleteRegValue HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\${AFS_VERSION}" "Debug"
955 ;Write start menu entries
956 CreateDirectory "$SMPROGRAMS\OpenAFS\Control Center"
957 CreateShortCut "$SMPROGRAMS\OpenAFS\Control Center\Account Manager.lnk" "$INSTDIR\Control Center\TaAfsAccountManager.exe"
958 CreateShortCut "$SMPROGRAMS\OpenAFS\Control Center\Server Manager.lnk" "$INSTDIR\Control Center\TaAfsServerManager.exe"
960 WriteUninstaller "$INSTDIR\Uninstall.exe"
961 WriteRegStr HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "DisplayIcon" "$INSTDIR\Uninstall.exe,0"
966 ;----------------------------
967 ; OpenAFS Supplemental Documentation
968 Section /o "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 WriteRegStr HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "DisplayIcon" "$INSTDIR\Uninstall.exe,0"
1119 CreateShortCut "$SMPROGRAMS\OpenAFS\Uninstall OpenAFS.lnk" "$INSTDIR\Uninstall.exe"
1120 Call AFSCommon.Install
1124 Section /o "Software Development Kit (SDK)" secSDK
1126 SetOutPath "$INSTDIR\Client\Program\lib"
1127 File /r "${AFS_CLIENT_LIBDIR}\*.*"
1129 SetOutPath "$INSTDIR\Client\Program\Include"
1130 File /r "${AFS_BUILD_INCDIR}\*.*"
1133 SetOutPath "$INSTDIR\Client\Program\Sample"
1134 File "..\..\afsd\sample\token.c"
1136 ;Store install folder
1137 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS SDK" "" $INSTDIR
1138 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS SDK\CurrentVersion" "VersionString" ${AFS_VERSION}
1139 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\CurrentVersion" "MajorVersion" ${AFS_MAJORVERSION}
1140 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\CurrentVersion" "MinorVersion" ${AFS_MINORVERSION}
1141 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\CurrentVersion" "PatchLevel" ${AFS_PATCHLEVEL}
1142 WriteRegStr HKLM "${AFS_REGKEY_ROOT}\AFS SDK\${AFS_VERSION}" "VersionString" ${AFS_VERSION}
1143 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\${AFS_VERSION}" "MajorVersion" ${AFS_MAJORVERSION}
1144 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\${AFS_VERSION}" "MinorVersion" ${AFS_MINORVERSION}
1145 WriteRegDWORD HKLM "${AFS_REGKEY_ROOT}\AFS SDK\${AFS_VERSION}" "PatchLevel" ${AFS_PATCHLEVEL}
1147 WriteUninstaller "$INSTDIR\Uninstall.exe"
1148 WriteRegStr HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "DisplayIcon" "$INSTDIR\Uninstall.exe,0"
1150 SetOutPath "$SMPROGRAMS\OpenAFS"
1151 CreateShortCut "$SMPROGRAMS\OpenAFS\Uninstall OpenAFS.lnk" "$INSTDIR\Uninstall.exe"
1153 Call AFSCommon.Install
1157 Section /o "Debug symbols" secDebug
1158 SectionGetFlags ${secClient} $R0
1159 IntOp $R0 $R0 & ${SF_SELECTED}
1160 IntCmp $R0 ${SF_SELECTED} +1 DoServer
1162 ; Do client components
1163 SetOutPath "$INSTDIR\Client\Program"
1164 File "${AFS_CLIENT_BUILDDIR}\afsshare.pdb"
1165 File "${AFS_CLIENT_BUILDDIR}\libosi.pdb"
1166 File "${AFS_CLIENT_BUILDDIR}\libafsconf.pdb"
1167 File "${AFS_CLIENT_BUILDDIR}\klog.pdb"
1168 File "${AFS_CLIENT_BUILDDIR}\tokens.pdb"
1169 File "${AFS_CLIENT_BUILDDIR}\unlog.pdb"
1170 File "${AFS_CLIENT_BUILDDIR}\fs.pdb"
1171 File "${AFS_CLIENT_BUILDDIR}\afsdacl.pdb"
1172 File "${AFS_CLIENT_BUILDDIR}\cmdebug.pdb"
1173 File "${AFS_CLIENT_BUILDDIR}\aklog.pdb"
1174 File "${AFS_CLIENT_BUILDDIR}\afscreds.pdb"
1175 File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext.pdb"
1176 File "${AFS_CLIENT_BUILDDIR}\afsd_service.pdb"
1177 File "${AFS_CLIENT_BUILDDIR}\symlink.pdb"
1178 File "${AFS_DESTDIR}\bin\kpasswd.pdb"
1179 File "${AFS_DESTDIR}\bin\pts.pdb"
1180 File "${AFS_SERVER_BUILDDIR}\bos.pdb"
1181 File "${AFS_SERVER_BUILDDIR}\kas.pdb"
1182 File "${AFS_SERVER_BUILDDIR}\vos.pdb"
1183 File "${AFS_SERVER_BUILDDIR}\udebug.pdb"
1184 File "${AFS_DESTDIR}\bin\translate_et.pdb"
1185 File "${AFS_DESTDIR}\etc\rxdebug.pdb"
1186 File "${AFS_DESTDIR}\etc\backup.pdb"
1187 File "${AFS_CLIENT_BUILDDIR}\afs_cpa.pdb"
1189 SetOutPath "$SYSDIR"
1190 File "${AFS_CLIENT_BUILDDIR}\afslogon.pdb"
1193 SectionGetFlags ${secServer} $R0
1194 IntOp $R0 $R0 & ${SF_SELECTED}
1195 IntCmp $R0 ${SF_SELECTED} +1 DoControl
1197 ; Do server components
1198 SetOutPath "$INSTDIR\Server\usr\afs\bin"
1199 File "${AFS_SERVER_BUILDDIR}\afskill.pdb"
1200 File "${AFS_SERVER_BUILDDIR}\afssvrcfg.pdb"
1201 File "${AFS_SERVER_BUILDDIR}\asetkey.pdb"
1202 File "${AFS_SERVER_BUILDDIR}\bosctlsvc.pdb"
1203 File "${AFS_SERVER_BUILDDIR}\bosserver.pdb"
1204 File "${AFS_SERVER_BUILDDIR}\buserver.pdb"
1205 File "${AFS_ETC_BUILDDIR}\butc.pdb"
1206 File "${AFS_SERVER_BUILDDIR}\fileserver.pdb"
1207 File "${AFS_ETC_BUILDDIR}\fms.pdb"
1208 File "${AFS_SERVER_BUILDDIR}\kaserver.pdb"
1209 File "${AFS_SERVER_BUILDDIR}\ptserver.pdb"
1210 File "${AFS_SERVER_BUILDDIR}\salvager.pdb"
1211 File "${AFS_SERVER_BUILDDIR}\upclient.pdb"
1212 File "${AFS_SERVER_BUILDDIR}\upserver.pdb"
1213 File "${AFS_SERVER_BUILDDIR}\vlserver.pdb"
1214 File "${AFS_SERVER_BUILDDIR}\volinfo.pdb"
1215 File "${AFS_SERVER_BUILDDIR}\volserver.pdb"
1217 ; Do server common components
1218 File "${AFS_SERVER_BUILDDIR}\afsvosadmin.pdb"
1219 File "${AFS_SERVER_BUILDDIR}\afsbosadmin.pdb"
1220 File "${AFS_SERVER_BUILDDIR}\afscfgadmin.pdb"
1221 File "${AFS_SERVER_BUILDDIR}\afskasadmin.pdb"
1222 File "${AFS_SERVER_BUILDDIR}\afsptsadmin.pdb"
1224 SetOutPath "$SYSDIR"
1225 File "${AFS_SERVER_BUILDDIR}\afsserver.pdb"
1227 ; Do control center components
1229 SectionGetFlags ${secControl} $R0
1230 IntOp $R0 $R0 & ${SF_SELECTED}
1231 IntCmp $R0 ${SF_SELECTED} +1 DoCommon
1233 SetOutPath "$INSTDIR\Control Center"
1234 File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager.pdb"
1235 File "${AFS_SERVER_BUILDDIR}\TaAfsAdmSvr.pdb"
1236 File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager.pdb"
1239 SetOutPath "$INSTDIR\Common"
1241 File "${SYSTEMDIR}\msvcr80d.pdb"
1242 File "${SYSTEMDIR}\msvcp80d.pdb"
1243 File "${SYSTEMDIR}\mfc80d.pdb"
1246 File "${SYSTEMDIR}\msvcr71d.pdb"
1247 File "${SYSTEMDIR}\msvcp71d.pdb"
1248 File "${SYSTEMDIR}\mfc71d.pdb"
1251 File "${SYSTEMDIR}\msvcr70d.pdb"
1252 File "${SYSTEMDIR}\msvcp70d.pdb"
1253 File "${SYSTEMDIR}\mfc70d.pdb"
1255 File "${SYSTEMDIR}\mfc42d.pdb"
1256 File "${SYSTEMDIR}\msvcp60d.pdb"
1257 File "${SYSTEMDIR}\msvcrtd.pdb"
1263 SetOutPath "$INSTDIR\Common"
1264 File "${AFS_CLIENT_BUILDDIR}\afs_config.pdb"
1265 File "${AFS_SERVER_BUILDDIR}\afsadminutil.pdb"
1266 File "${AFS_DESTDIR}\lib\afsauthent.pdb"
1267 File "${AFS_DESTDIR}\lib\afspthread.pdb"
1268 File "${AFS_DESTDIR}\lib\afsrpc.pdb"
1269 File "${AFS_SERVER_BUILDDIR}\afsclientadmin.pdb"
1270 File "${AFS_SERVER_BUILDDIR}\afsprocmgmt.pdb"
1271 File "${AFS_SERVER_BUILDDIR}\afsvosadmin.pdb"
1272 File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib.pdb"
1273 File "${AFS_SERVER_BUILDDIR}\afsvosadmin.pdb"
1274 File "${AFS_SERVER_BUILDDIR}\afsbosadmin.pdb"
1275 File "${AFS_SERVER_BUILDDIR}\afscfgadmin.pdb"
1276 File "${AFS_SERVER_BUILDDIR}\afskasadmin.pdb"
1277 File "${AFS_SERVER_BUILDDIR}\afsptsadmin.pdb"
1282 ;Display the Finish header
1283 ;Insert this macro after the sections if you are not using a finish page
1284 ;!insertmacro MUI_SECTIONS_FINISHHEADER
1286 ;--------------------------------
1287 ;Installer Functions
1291 !insertmacro MUI_LANGDLL_DISPLAY
1293 ; Set the default install options
1298 StrCmp $R0 "true" contInstall
1300 MessageBox MB_OK|MB_ICONSTOP|MB_TOPMOST "You must be an administrator of this machine to install this software."
1305 ; Set Install Type text
1306 InstTypeSetText 0 "AFS Client"
1307 InstTypeSetText 1 "AFS Administrator"
1308 InstTypeSetText 2 "AFS Server"
1309 InstTypeSetText 3 "AFS Developer Tools"
1311 ; Set sections in each install type
1312 SectionSetInstTypes 0 15 ; AFS Client
1313 SectionSetInstTypes 1 15 ; Loopback adapter
1314 SectionSetInstTypes 2 4 ; AFS Server
1315 SectionSetInstTypes 3 6 ; AFS Control Center
1316 SectionSetInstTypes 4 14 ; Documentation
1317 SectionSetInstTypes 5 8 ; SDK
1319 SectionSetInstTypes 6 8 ; Debug symbols
1321 SectionSetInstTypes 6 15 ; Debug symbols
1324 ; Check that RPC functions are installed (I believe any one of these can be present for
1326 ReadRegStr $R0 HKLM "SOFTWARE\Microsoft\RPC\ClientProtocols" "ncacn_np"
1327 StrCmp $R0 "rpcrt4.dll" contInstall2
1328 ReadRegStr $R0 HKLM "SOFTWARE\Microsoft\RPC\ClientProtocols" "ncacn_ip_tcp"
1329 StrCmp $R0 "rpcrt4.dll" contInstall2
1330 ReadRegStr $R0 HKLM "SOFTWARE\Microsoft\RPC\ClientProtocols" "ncadg_ip_udp"
1331 StrCmp $R0 "rpcrt4.dll" contInstall2
1332 ReadRegStr $R0 HKLM "SOFTWARE\Microsoft\RPC\ClientProtocols" "ncacn_http"
1333 StrCmp $R0 "rpcrt4.dll" contInstall2
1335 MessageBox MB_OK|MB_ICONSTOP|MB_TOPMOST "An error was detected with your Windows RPC installation. Please make sure Windows RPC is installed before installing OpenAFS."
1340 ; If the Loopback is already installed, we mark the option OFF and Read Only
1341 ; so the user can not select it.
1342 Call afs.isLoopbackInstalled
1343 IntCmp $R1 0 SkipLoop
1344 SectionGetFlags ${secLoopback} $0
1345 IntOp $0 $0 & ${SECTION_OFF}
1346 IntOp $0 $0 | ${SF_RO}
1347 SectionSetFlags ${secLoopback} $0
1348 ; And disable the loopback in the types
1349 SectionSetInstTypes 1 0 ; Loopback adapter
1352 ; Never install debug symbols unless explicitly selected, except in DEBUG mode
1354 SectionGetFlags ${secDebug} $0
1355 IntOp $0 $0 & ${SECTION_OFF}
1356 SectionSetFlags ${secDebug} $0
1358 SectionGetFlags ${secDebug} $0
1359 IntOp $0 $0 | ${SF_SELECTED}
1360 SectionSetFlags ${secDebug} $0
1362 ; Our logic should be like this.
1363 ; 1) If no AFS components are installed, we do a clean install with default options. (Client/Docs)
1364 ; 2) If existing modules are installed, we keep them selected
1365 ; 3) If it is an upgrade, we set the text accordingly, else we mark it as a re-install
1367 Call IsAnyAFSInstalled
1369 StrCmp $R0 "0" DefaultOptions
1371 Call ShouldClientInstall
1374 ; Check if it was an IBM/Transarc version
1375 ReadRegStr $R0 HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon" "DisplayName"
1376 StrCmp $R0 "IBM AFS Client" DoIBM
1377 StrCmp $R0 "Transarc AFS Client" DoIBM
1380 StrCmp $R2 "0" NoClient
1381 StrCmp $R2 "1" ReinstallClient
1382 StrCmp $R2 "2" UpgradeClient
1383 StrCmp $R2 "3" DowngradeClient
1386 ReadRegDWORD $R0 HKLM "Software\TransarcCorporation\AFS Client\CurrentVersion" "MajorVersion"
1387 StrCmp $R0 "3" +1 NotIBM
1392 SectionGetFlags ${secClient} $0
1393 IntOp $0 $0 | ${SF_SELECTED}
1394 SectionSetFlags ${secClient} $0
1395 ;# !insertmacro SelectSection ${secClient}
1398 ;StrCpy $1 ${secClient} ; Gotta remember which section we are at now...
1399 SectionGetFlags ${secClient} $0
1400 IntOp $0 $0 & ${SECTION_OFF}
1401 SectionSetFlags ${secClient} $0
1404 SectionGetFlags ${secClient} $0
1405 IntOp $0 $0 | ${SF_SELECTED}
1406 SectionSetFlags ${secClient} $0
1407 SectionSetText ${secClient} $(UPGRADE_CLIENT)
1410 SectionGetFlags ${secClient} $0
1411 IntOp $0 $0 | ${SF_SELECTED}
1412 SectionSetFlags ${secClient} $0
1413 SectionSetText ${secClient} $(REINSTALL_CLIENT)
1416 SectionGetFlags ${secClient} $0
1417 IntOp $0 $0 | ${SF_SELECTED}
1418 SectionSetFlags ${secClient} $0
1419 SectionSetText ${secClient} $(REINSTALL_CLIENT)
1425 Call ShouldServerInstall
1427 StrCmp $R2 "0" NoServer
1428 StrCmp $R2 "1" ReinstallServer
1429 StrCmp $R2 "2" UpgradeServer
1430 StrCmp $R2 "3" DowngradeServer
1432 SectionGetFlags ${secServer} $0
1433 IntOp $0 $0 | ${SF_SELECTED}
1434 SectionSetFlags ${secServer} $0
1435 ;# !insertmacro UnselectSection ${secServer}
1439 SectionGetFlags ${secServer} $0
1440 IntOp $0 $0 | ${SF_SELECTED}
1441 SectionSetFlags ${secServer} $0
1442 SectionSetText ${secServer} $(UPGRADE_SERVER)
1446 SectionGetFlags ${secServer} $0
1447 IntOp $0 $0 | ${SF_SELECTED}
1448 SectionSetFlags ${secServer} $0
1449 SectionSetText ${secServer} $(REINSTALL_SERVER)
1453 SectionGetFlags ${secServer} $0
1454 IntOp $0 $0 | ${SF_SELECTED}
1455 SectionSetFlags ${secServer} $0
1456 SectionSetText ${secServer} $(REINSTALL_SERVER)
1460 SectionGetFlags ${secServer} $0
1461 IntOp $0 $0 & ${SECTION_OFF}
1462 SectionSetFlags ${secServer} $0
1463 ;# !insertmacro UnselectSection ${secServer}
1467 ; Check control center
1468 Call IsControlInstalled
1470 StrCmp $R2 "0" NoControl
1472 SectionGetFlags ${secControl} $0
1473 IntOp $0 $0 | ${SF_SELECTED}
1474 SectionSetFlags ${secControl} $0
1478 SectionGetFlags ${secControl} $0
1479 IntOp $0 $0 & ${SECTION_OFF}
1480 SectionSetFlags ${secControl} $0
1481 ;# !insertmacro UnselectSection ${secControl}
1484 ; Check Documentation
1485 Call IsDocumentationInstalled
1487 StrCmp $R2 "0" NoDocs
1488 SectionGetFlags ${secDocs} $0
1489 IntOp $0 $0 | ${SF_SELECTED}
1490 SectionSetFlags ${secDocs} $0
1494 SectionGetFlags ${secDocs} $0
1495 IntOp $0 $0 & ${SECTION_OFF}
1496 SectionSetFlags ${secDocs} $0
1499 ; To check the SDK, we simply look to see if the files exist. If they do,
1500 ; the SDK is installed. If not, we don't need to push it on the user.
1501 ; If they are there, we want to make sure they match the installed version.
1503 IfFileExists "$INSTDIR\Client\Program\Include\main.h" +1 NoSDK
1504 SectionGetFlags ${secSDK} $0
1505 IntOp $0 $0 | ${SF_SELECTED}
1506 SectionSetFlags ${secSDK} $0
1510 SectionGetFlags ${secSDK} $0
1511 IntOp $0 $0 & ${SECTION_OFF}
1512 SectionSetFlags ${secSDK} $0
1517 SectionGetFlags ${secClient} $0
1518 IntOp $0 $0 | ${SF_SELECTED}
1519 SectionSetFlags ${secClient} $0
1521 ; Server NOT selected
1522 SectionGetFlags ${secServer} $0
1523 IntOp $0 $0 & ${SECTION_OFF}
1524 SectionSetFlags ${secServer} $0
1526 ; Control Center NOT selected
1527 SectionGetFlags ${secControl} $0
1528 IntOp $0 $0 & ${SECTION_OFF}
1529 SectionSetFlags ${secControl} $0
1530 ;# !insertmacro UnselectSection ${secControl}
1532 ; Documentation NOT selected
1533 SectionGetFlags ${secDocs} $0
1534 IntOp $0 $0 & ${SECTION_OFF}
1535 SectionSetFlags ${secDocs} $0
1536 ;# !insertmacro UnselectSection ${secDocs}
1539 SectionGetFlags ${secSDK} $0
1540 IntOp $0 $0 & ${SECTION_OFF}
1541 SectionSetFlags ${secSDK} $0
1542 ;# !insertmacro UnselectSection ${secSDK}
1551 ; See if we can set a default installation path...
1552 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "PathName"
1553 StrCmp $R0 "" TryServer
1557 ; Work around bug in 1.3.5000, 1.3.5100, 1.3.5200, 1.3.5201, 1.3.5299 installers...
1558 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "MajorVersion"
1559 StrCmp $R0 "1" +1 SkipParent
1560 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "MinorVersion"
1561 StrCmp $R0 "3" +1 SkipParent
1562 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion" "PatchLevel"
1563 StrCmp $R0 "5000" UpParent
1564 StrCmp $R0 "5100" UpParent
1565 StrCmp $R0 "5200" UpParent
1566 StrCmp $R0 "5201" UpParent
1567 StrCmp $R0 "5299" UpParent
1579 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion" "PathName"
1580 StrCmp $R0 "" TryControl
1588 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion" "PathName"
1596 File /oname=$0 CellServPage.ini
1598 File /oname=$1 AFSCell.ini
1600 File /oname=$2 AFSCreds.ini
1601 ;File /oname=$1 ConfigURL.ini
1606 ;--------------------------------
1607 ; These are our cleanup functions
1608 Function .onInstFailed
1613 Function .onInstSuccess
1619 ;--------------------------------
1622 !insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
1623 !insertmacro MUI_DESCRIPTION_TEXT ${secServer} $(DESC_secServer)
1624 !insertmacro MUI_DESCRIPTION_TEXT ${secClient} $(DESC_secClient)
1625 !insertmacro MUI_DESCRIPTION_TEXT ${secControl} $(DESC_secControl)
1626 !insertmacro MUI_DESCRIPTION_TEXT ${secDocs} $(DESC_secDocs)
1627 !insertmacro MUI_DESCRIPTION_TEXT ${secSDK} $(DESC_secSDK)
1628 !insertmacro MUI_DESCRIPTION_TEXT ${secLoopback} $(DESC_secLoopback)
1629 !insertmacro MUI_DESCRIPTION_TEXT ${secDebug} $(DESC_secDebug)
1630 !insertmacro MUI_FUNCTION_DESCRIPTION_END
1632 ;--------------------------------
1633 ;Uninstaller Section
1636 ; Make sure the user REALLY wants to do this, unless they did a silent uninstall, in which case...let them!
1637 IfSilent StartRemove ; New in v2.0b4
1638 MessageBox MB_YESNO "Are you sure you want to remove OpenAFS from this machine?" IDYES StartRemove
1643 SetShellVarContext all
1644 ; Stop the running processes
1646 File /oname=$R0 "${AFS_WININSTALL_DIR}\Killer.exe"
1647 nsExec::Exec '$R0 afscreds.exe'
1648 Exec "afscreds.exe -z"
1649 ; in case we are upgrading an old version that does not support -z
1651 nsExec::Exec '$R0 afscreds.exe'
1653 nsExec::Exec '$R0 krbcc32s.exe'
1656 ; Delete the AFS service
1658 File /oname=$R0 "${AFS_WININSTALL_DIR}\Service.exe"
1659 nsExec::Exec "net stop TransarcAFSDaemon"
1660 nsExec::Exec "net stop TransarcAFSServer"
1661 nsExec::Exec '$R0 u TransarcAFSDaemon'
1662 ; After we stop the service, but before we delete it, we have to remove the volume data
1663 ; This is because the storage locations are in the registry under the service key.
1664 ; Call un.RemoveAFSVolumes
1665 nsExec::Exec '$R0 u TransarcAFSServer'
1668 Call un.RemoveProvider
1670 Push "$INSTDIR\Client\Program"
1671 Call un.RemoveFromPath
1672 Push "$INSTDIR\Common"
1673 Call un.RemoveFromPath
1675 Push "$INSTDIR\kfw\bin"
1676 Call un.RemoveFromPath
1679 ; Delete documentation
1680 Delete "$INSTDIR\Documentation\README.TXT"
1681 Delete "$INSTDIR\Documentation\html\*"
1682 Delete "$INSTDIR\Documentation\html\CmdRef\*"
1683 Delete "$INSTDIR\Documentation\html\InstallGd\*"
1684 Delete "$INSTDIR\Documentation\html\ReleaseNotes\*"
1685 Delete "$INSTDIR\Documentation\html\SysAdminGd\*"
1687 Delete /REBOOTOK "$INSTDIR\Common\afs_config.exe"
1688 Delete /REBOOTOK "$INSTDIR\Common\afs_shl_ext.dll"
1689 Delete /REBOOTOK "$INSTDIR\Common\afsadminutil.dll"
1690 Delete /REBOOTOK "$INSTDIR\Common\lib\afsauthent.dll"
1691 Delete /REBOOTOK "$INSTDIR\Common\lib\afspthread.dll"
1692 Delete /REBOOTOK "$INSTDIR\Common\lib\afsrpc.dll"
1693 Delete /REBOOTOK "$INSTDIR\Common\afsclientadmin.dll"
1694 Delete /REBOOTOK "$INSTDIR\Common\afsprocmgmt.dll"
1695 Delete /REBOOTOK "$INSTDIR\Common\afsvosadmin.dll"
1696 Delete /REBOOTOK "$INSTDIR\Common\TaAfsAppLib.dll"
1697 Delete /REBOOTOK "$INSTDIR\Common\afsvosadmin.dll"
1698 Delete /REBOOTOK "$INSTDIR\Common\afsbosadmin.dll"
1699 Delete /REBOOTOK "$INSTDIR\Common\afscfgadmin.dll"
1700 Delete /REBOOTOK "$INSTDIR\Common\afskasadmin.dll"
1701 Delete /REBOOTOK "$INSTDIR\Common\afsptsadmin.dll"
1703 Delete /REBOOTOK "$INSTDIR\Common\afs_config.pdb"
1704 Delete /REBOOTOK "$INSTDIR\Common\afs_shl_ext.pdb"
1705 Delete /REBOOTOK "$INSTDIR\Common\afsadminutil.pdb"
1706 Delete /REBOOTOK "$INSTDIR\Common\lib\afsauthent.pdb"
1707 Delete /REBOOTOK "$INSTDIR\Common\lib\afspthread.pdb"
1708 Delete /REBOOTOK "$INSTDIR\Common\lib\afsrpc.pdb"
1709 Delete /REBOOTOK "$INSTDIR\Common\afsclientadmin.pdb"
1710 Delete /REBOOTOK "$INSTDIR\Common\afsprocmgmt.pdb"
1711 Delete /REBOOTOK "$INSTDIR\Common\afsvosadmin.pdb"
1712 Delete /REBOOTOK "$INSTDIR\Common\TaAfsAppLib.pdb"
1713 Delete /REBOOTOK "$INSTDIR\Common\afsvosadmin.pdb"
1714 Delete /REBOOTOK "$INSTDIR\Common\afsbosadmin.pdb"
1715 Delete /REBOOTOK "$INSTDIR\Common\afscfgadmin.pdb"
1716 Delete /REBOOTOK "$INSTDIR\Common\afskasadmin.pdb"
1717 Delete /REBOOTOK "$INSTDIR\Common\afsptsadmin.pdb"
1720 Delete /REBOOTOK "$INSTDIR\bin\msvcr80d.dll"
1721 Delete /REBOOTOK "$INSTDIR\bin\msvcr80d.pdb"
1722 Delete /REBOOTOK "$INSTDIR\bin\msvcp80d.dll"
1723 Delete /REBOOTOK "$INSTDIR\bin\msvcp80d.pdb"
1724 Delete /REBOOTOK "$INSTDIR\bin\mfc80d.dll"
1725 Delete /REBOOTOK "$INSTDIR\bin\mfc80d.pdb"
1728 Delete /REBOOTOK "$INSTDIR\bin\msvcr71d.dll"
1729 Delete /REBOOTOK "$INSTDIR\bin\msvcr71d.pdb"
1730 Delete /REBOOTOK "$INSTDIR\bin\msvcp71d.dll"
1731 Delete /REBOOTOK "$INSTDIR\bin\msvcp71d.pdb"
1732 Delete /REBOOTOK "$INSTDIR\bin\mfc71d.dll"
1733 Delete /REBOOTOK "$INSTDIR\bin\mfc71d.pdb"
1736 Delete /REBOOTOK "$INSTDIR\bin\msvcr70d.dll"
1737 Delete /REBOOTOK "$INSTDIR\bin\msvcr70d.pdb"
1738 Delete /REBOOTOK "$INSTDIR\bin\msvcp70d.dll"
1739 Delete /REBOOTOK "$INSTDIR\bin\msvcp70d.pdb"
1740 Delete /REBOOTOK "$INSTDIR\bin\mfc70d.dll"
1741 Delete /REBOOTOK "$INSTDIR\bin\mfc70d.pdb"
1743 Delete /REBOOTOK "$INSTDIR\bin\mfc42d.dll"
1744 Delete /REBOOTOK "$INSTDIR\bin\mfc42d.pdb"
1745 Delete /REBOOTOK "$INSTDIR\bin\msvcp60d.dll"
1746 Delete /REBOOTOK "$INSTDIR\bin\msvcp60d.pdb"
1747 Delete /REBOOTOK "$INSTDIR\bin\msvcrtd.dll"
1748 Delete /REBOOTOK "$INSTDIR\bin\msvcrtd.pdb"
1754 Delete /REBOOTOK "$INSTDIR\bin\mfc80.dll"
1755 Delete /REBOOTOK "$INSTDIR\bin\msvcr80.dll"
1756 Delete /REBOOTOK "$INSTDIR\bin\msvcp80.dll"
1757 Delete /REBOOTOK "$INSTDIR\bin\MFC80CHS.DLL"
1758 Delete /REBOOTOK "$INSTDIR\bin\MFC80CHT.DLL"
1759 Delete /REBOOTOK "$INSTDIR\bin\MFC80DEU.DLL"
1760 Delete /REBOOTOK "$INSTDIR\bin\MFC80ENU.DLL"
1761 Delete /REBOOTOK "$INSTDIR\bin\MFC80ESP.DLL"
1762 Delete /REBOOTOK "$INSTDIR\bin\MFC80FRA.DLL"
1763 Delete /REBOOTOK "$INSTDIR\bin\MFC80ITA.DLL"
1764 Delete /REBOOTOK "$INSTDIR\bin\MFC80JPN.DLL"
1765 Delete /REBOOTOK "$INSTDIR\bin\MFC80KOR.DLL"
1768 Delete /REBOOTOK "$INSTDIR\bin\mfc71.dll"
1769 Delete /REBOOTOK "$INSTDIR\bin\msvcr71.dll"
1770 Delete /REBOOTOK "$INSTDIR\bin\msvcp71.dll"
1771 Delete /REBOOTOK "$INSTDIR\bin\MFC71CHS.DLL"
1772 Delete /REBOOTOK "$INSTDIR\bin\MFC71CHT.DLL"
1773 Delete /REBOOTOK "$INSTDIR\bin\MFC71DEU.DLL"
1774 Delete /REBOOTOK "$INSTDIR\bin\MFC71ENU.DLL"
1775 Delete /REBOOTOK "$INSTDIR\bin\MFC71ESP.DLL"
1776 Delete /REBOOTOK "$INSTDIR\bin\MFC71FRA.DLL"
1777 Delete /REBOOTOK "$INSTDIR\bin\MFC71ITA.DLL"
1778 Delete /REBOOTOK "$INSTDIR\bin\MFC71JPN.DLL"
1779 Delete /REBOOTOK "$INSTDIR\bin\MFC71KOR.DLL"
1782 Delete /REBOOTOK "$INSTDIR\bin\mfc70.dll"
1783 Delete /REBOOTOK "$INSTDIR\bin\msvcr70.dll"
1784 Delete /REBOOTOK "$INSTDIR\bin\msvcp70.dll"
1785 Delete /REBOOTOK "$INSTDIR\bin\MFC70CHS.DLL"
1786 Delete /REBOOTOK "$INSTDIR\bin\MFC70CHT.DLL"
1787 Delete /REBOOTOK "$INSTDIR\bin\MFC70DEU.DLL"
1788 Delete /REBOOTOK "$INSTDIR\bin\MFC70ENU.DLL"
1789 Delete /REBOOTOK "$INSTDIR\bin\MFC70ESP.DLL"
1790 Delete /REBOOTOK "$INSTDIR\bin\MFC70FRA.DLL"
1791 Delete /REBOOTOK "$INSTDIR\bin\MFC70ITA.DLL"
1792 Delete /REBOOTOK "$INSTDIR\bin\MFC70JPN.DLL"
1793 Delete /REBOOTOK "$INSTDIR\bin\MFC70KOR.DLL"
1795 Delete /REBOOTOK "$INSTDIR\bin\mfc42.dll"
1796 Delete /REBOOTOK "$INSTDIR\bin\msvcp60.dll"
1797 Delete /REBOOTOK "$INSTDIR\bin\msvcrt.dll"
1804 ; IfFileExists "$INSTDIR\Client\CellServDB" CellExists SkipDelAsk
1806 MessageBox MB_YESNO "Would you like to keep your configuration information?" IDYES SkipDel
1807 Delete "$INSTDIR\Client\CellServDB"
1809 ; Only remove krb5.ini if KfW was installed
1811 Delete "$WINDIR\krb5.ini"
1813 Delete "$INSTDIR\Client\afsdns.ini"
1816 File /oname=$R0 "${AFS_WININSTALL_DIR}\AdminGroup.exe"
1817 nsExec::Exec '$R0 -remove'
1820 Delete "$WINDIR\afsd_init.log"
1821 Delete "$INSTDIR\Uninstall.exe"
1824 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\afskill.exe"
1825 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\afssvrcfg.exe"
1826 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\bosctlsvc.exe"
1827 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\bosserver.exe"
1828 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\buserver.exe"
1829 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\butc.exe"
1830 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\fileserver.exe"
1831 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\fms.exe"
1832 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\kaserver.exe"
1833 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\ptserver.exe"
1834 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\salvager.exe"
1835 Delete "$INSTDIR\Server\usr\afs\bin\ServerUninst.dll"
1836 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\upclient.exe"
1837 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\upserver.exe"
1838 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\vlserver.exe"
1839 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\volinfo.exe"
1840 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\volserver.exe"
1842 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\afskill.pdb"
1843 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\afssvrcfg.pdb"
1844 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\bosctlsvc.pdb"
1845 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\bosserver.pdb"
1846 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\buserver.pdb"
1847 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\butc.pdb"
1848 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\fileserver.pdb"
1849 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\fms.pdb"
1850 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\kaserver.pdb"
1851 Delete /REBOOTOK "$INSTDIR\Server\usr\afs\bin\ptserver.pdb"
1852 Delete "$INSTDIR\Server\usr\afs\bin\salvager.pdb"
1853 Delete "$INSTDIR\Server\usr\afs\bin\ServerUninst.pdb"
1854 Delete "$INSTDIR\Server\usr\afs\bin\upclient.pdb"
1855 Delete "$INSTDIR\Server\usr\afs\bin\upserver.pdb"
1856 Delete "$INSTDIR\Server\usr\afs\bin\vlserver.pdb"
1857 Delete "$INSTDIR\Server\usr\afs\bin\volinfo.pdb"
1858 Delete "$INSTDIR\Server\usr\afs\bin\volserver.pdb"
1860 RMDir /r "$INSTDIR\Server\usr\afs\bin"
1861 ; do not delete the server configuration files
1862 ; or we will lose the volumes and authentication
1864 ;RmDir /r "$INSTDIR\Server\usr\afs\etc\logs"
1865 ;RmDir /r "$INSTDIR\Server\usr\afs\etc"
1866 ;RmDir /r "$INSTDIR\Server\usr\afs\local"
1867 ;RMDIR /r "$INSTDIR\Server\usr\afs\logs"
1869 Delete /REBOOTOK "$SYSDIR\afsserver.cpl"
1870 Delete /REBOOTOK "$SYSDIR\afs_cpa.cpl"
1871 Delete /REBOOTOK "$SYSDIR\afslogon.dll"
1872 Delete /REBOOTOK "$SYSDIR\afscpcc.exe"
1874 Delete /REBOOTOK "$SYSDIR\afsserver.pdb"
1875 Delete /REBOOTOK "$SYSDIR\afs_cpa.pdb"
1876 Delete /REBOOTOK "$SYSDIR\afslogon.pdb"
1877 Delete /REBOOTOK "$SYSDIR\afscpcc.pdb"
1879 RMDir /r "$INSTDIR\Documentation\html\CmdRef"
1880 RMDir /r "$INSTDIR\Documentation\html\InstallGd"
1881 RMDir /r "$INSTDIR\Documentation\html\ReleaseNotes"
1882 RMDir /r "$INSTDIR\Documentation\html\SysAdminGd"
1883 RMDIr /r "$INSTDIR\Documentation\html"
1885 RMDir "$INSTDIR\Documentation"
1886 ; Delete DOC short cut
1887 Delete /REBOOTOK "$INSTDIR\Client\Program\afscreds.exe"
1889 Delete /REBOOTOK "$INSTDIR\Client\Program\afscreds.pdb"
1891 Delete /REBOOTOK "$INSTDIR\Client\Program\*"
1892 Delete /REBOOTOK "$INSTDIR\Client\Program\Include\*"
1893 Delete /REBOOTOK "$INSTDIR\Client\Program\Include\afs\*"
1894 Delete /REBOOTOK "$INSTDIR\Client\Program\Include\rx\*"
1895 Delete /REBOOTOK "$INSTDIR\Client\Program\Sample\*"
1896 RMDir "$INSTDIR\Client\Program\Sample"
1897 RMDir "$INSTDIR\Client\Program\Include\afs"
1898 RMDir "$INSTDIR\Client\Program\Include\rx"
1899 RMDir "$INSTDIR\Client\Program\Include"
1900 RMDir "$INSTDIR\Client\Program"
1901 RMDir "$INSTDIR\Client"
1905 Delete /REBOOTOK "$INSTDIR\bin\msvcr80d.dll"
1906 Delete /REBOOTOK "$INSTDIR\bin\msvcr80d.pdb"
1907 Delete /REBOOTOK "$INSTDIR\bin\msvcp80d.dll"
1908 Delete /REBOOTOK "$INSTDIR\bin\msvcp80d.pdb"
1909 Delete /REBOOTOK "$INSTDIR\bin\mfc80d.dll"
1910 Delete /REBOOTOK "$INSTDIR\bin\mfc80d.pdb"
1913 Delete /REBOOTOK "$INSTDIR\bin\msvcr71d.dll"
1914 Delete /REBOOTOK "$INSTDIR\bin\msvcr71d.pdb"
1915 Delete /REBOOTOK "$INSTDIR\bin\msvcp71d.dll"
1916 Delete /REBOOTOK "$INSTDIR\bin\msvcp71d.pdb"
1917 Delete /REBOOTOK "$INSTDIR\bin\mfc71d.dll"
1918 Delete /REBOOTOK "$INSTDIR\bin\mfc71d.pdb"
1921 Delete /REBOOTOK "$INSTDIR\bin\msvcr70d.dll"
1922 Delete /REBOOTOK "$INSTDIR\bin\msvcr70d.pdb"
1923 Delete /REBOOTOK "$INSTDIR\bin\msvcp70d.dll"
1924 Delete /REBOOTOK "$INSTDIR\bin\msvcp70d.pdb"
1925 Delete /REBOOTOK "$INSTDIR\bin\mfc70d.dll"
1926 Delete /REBOOTOK "$INSTDIR\bin\mfc70d.pdb"
1928 Delete /REBOOTOK "$INSTDIR\bin\mfc42d.dll"
1929 Delete /REBOOTOK "$INSTDIR\bin\mfc42d.pdb"
1930 Delete /REBOOTOK "$INSTDIR\bin\msvcp60d.dll"
1931 Delete /REBOOTOK "$INSTDIR\bin\msvcp60d.pdb"
1932 Delete /REBOOTOK "$INSTDIR\bin\msvcrtd.dll"
1933 Delete /REBOOTOK "$INSTDIR\bin\msvcrtd.pdb"
1939 Delete /REBOOTOK "$INSTDIR\bin\mfc80.dll"
1940 Delete /REBOOTOK "$INSTDIR\bin\msvcr80.dll"
1941 Delete /REBOOTOK "$INSTDIR\bin\msvcp80.dll"
1942 Delete /REBOOTOK "$INSTDIR\bin\MFC80CHS.DLL"
1943 Delete /REBOOTOK "$INSTDIR\bin\MFC80CHT.DLL"
1944 Delete /REBOOTOK "$INSTDIR\bin\MFC80DEU.DLL"
1945 Delete /REBOOTOK "$INSTDIR\bin\MFC80ENU.DLL"
1946 Delete /REBOOTOK "$INSTDIR\bin\MFC80ESP.DLL"
1947 Delete /REBOOTOK "$INSTDIR\bin\MFC80FRA.DLL"
1948 Delete /REBOOTOK "$INSTDIR\bin\MFC80ITA.DLL"
1949 Delete /REBOOTOK "$INSTDIR\bin\MFC80JPN.DLL"
1950 Delete /REBOOTOK "$INSTDIR\bin\MFC80KOR.DLL"
1953 Delete /REBOOTOK "$INSTDIR\bin\mfc71.dll"
1954 Delete /REBOOTOK "$INSTDIR\bin\msvcr71.dll"
1955 Delete /REBOOTOK "$INSTDIR\bin\msvcp71.dll"
1956 Delete /REBOOTOK "$INSTDIR\bin\MFC71CHS.DLL"
1957 Delete /REBOOTOK "$INSTDIR\bin\MFC71CHT.DLL"
1958 Delete /REBOOTOK "$INSTDIR\bin\MFC71DEU.DLL"
1959 Delete /REBOOTOK "$INSTDIR\bin\MFC71ENU.DLL"
1960 Delete /REBOOTOK "$INSTDIR\bin\MFC71ESP.DLL"
1961 Delete /REBOOTOK "$INSTDIR\bin\MFC71FRA.DLL"
1962 Delete /REBOOTOK "$INSTDIR\bin\MFC71ITA.DLL"
1963 Delete /REBOOTOK "$INSTDIR\bin\MFC71JPN.DLL"
1964 Delete /REBOOTOK "$INSTDIR\bin\MFC71KOR.DLL"
1967 Delete /REBOOTOK "$INSTDIR\bin\mfc70.dll"
1968 Delete /REBOOTOK "$INSTDIR\bin\msvcr70.dll"
1969 Delete /REBOOTOK "$INSTDIR\bin\msvcp70.dll"
1970 Delete /REBOOTOK "$INSTDIR\bin\MFC70CHS.DLL"
1971 Delete /REBOOTOK "$INSTDIR\bin\MFC70CHT.DLL"
1972 Delete /REBOOTOK "$INSTDIR\bin\MFC70DEU.DLL"
1973 Delete /REBOOTOK "$INSTDIR\bin\MFC70ENU.DLL"
1974 Delete /REBOOTOK "$INSTDIR\bin\MFC70ESP.DLL"
1975 Delete /REBOOTOK "$INSTDIR\bin\MFC70FRA.DLL"
1976 Delete /REBOOTOK "$INSTDIR\bin\MFC70ITA.DLL"
1977 Delete /REBOOTOK "$INSTDIR\bin\MFC70JPN.DLL"
1978 Delete /REBOOTOK "$INSTDIR\bin\MFC70KOR.DLL"
1980 Delete /REBOOTOK "$INSTDIR\bin\mfc42.dll"
1981 Delete /REBOOTOK "$INSTDIR\bin\msvcp60.dll"
1982 Delete /REBOOTOK "$INSTDIR\bin\msvcrt.dll"
1988 Delete /REBOOTOK "$INSTDIR\Common\*"
1989 RMDir "$INSTDIR\Common"
1993 Delete /REBOOTOK "$INSTDIR\kfw\bin\*"
1994 RMDIR /r "$INSTDIR\kfw\bin"
1995 Delete /REBOOTOK "$INSTDIR\kfw\doc\*"
1996 RMDIR /r "$INSTDIR\kfw\doc"
1997 RMDIR /r "$INSTDIR\kfw"
2000 Delete "$SMPROGRAMS\OpenAFS\Documentation.lnk"
2002 ; Remove control center
2003 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsAccountManager.exe"
2004 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsAdmSvr.exe"
2005 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsServerManager.exe"
2006 Delete /REBOOTOK "$INSTDIR\Control Center\CCUninst.dll"
2007 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsAccountManager.pdb"
2008 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsAdmSvr.pdb"
2009 Delete /REBOOTOK "$INSTDIR\Control Center\TaAfsServerManager.pdb"
2010 RMDir "$INSTDIR\Control Center"
2012 Delete "$SMPROGRAMS\OpenAFS\Uninstall OpenAFS.lnk"
2013 Delete "$SMPROGRAMS\OpenAFS\Client\Authentication.lnk"
2014 Delete "$SMPROGRAMS\OpenAFS\Control Center\Account Manager.lnk"
2015 Delete "$SMPROGRAMS\OpenAFS\Control Center\Server Manager.lnk"
2016 RMDIR "$SMPROGRAMS\OpenAFS\Control Center"
2017 RMDir /r "$SMPROGRAMS\OpenAFS\Client"
2018 RMDir /r "$SMPROGRAMS\OpenAFS"
2019 Delete "$SMSTARTUP\AFS Credentials.lnk"
2021 ReadRegStr $R0 HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon" "CachePath"
2023 Delete "$R0\AFSCache"
2024 Delete "C:\AFSCache"
2026 DeleteRegKey HKCR "*\shellex\ContextMenuHandlers\AFS Client Shell Extension"
2027 DeleteRegKey HKCR "CLSID\{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}\InprocServer32"
2028 DeleteRegKey HKCR "CLSID\{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}"
2029 DeleteRegKey HKCR "FOLDER\shellex\ContextMenuHandlers\AFS Client Shell Extension"
2030 DeleteRegValue HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Shell Extensions\Approved" "{DC515C27-6CAC-11D1-BAE7-00C04FD140D2}"
2031 DeleteRegValue HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Control Panel\Cpls" "afs_cpa"
2033 ; WinLogon Event Notification
2034 DeleteRegKey HKLM "Software\Microsoft\Windows NT\CurrentVersion\Winlogon\Notify\AfsLogon"
2036 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Client\CurrentVersion"
2037 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Client"
2038 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation\CurrentVersion"
2039 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Supplemental Documentation"
2040 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Control Center\CurrentVersion"
2041 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Control Center"
2042 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Server\CurrentVersion"
2043 DeleteRegKey HKLM "${AFS_REGKEY_ROOT}\AFS Server"
2044 DeleteRegKey /ifempty HKLM "${AFS_REGKEY_ROOT}"
2045 DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS"
2046 DeleteRegValue HKLM "SYSTEM\CurrentControlSet\Services\NetBT\Parameters" "SmbDeviceEnabled"
2048 ; Support for apps that wrote submount data directly to afsdsbmt.ini
2049 DeleteRegKey HKLM "SOFTWARE\Microsoft\Windows NT\CurrentVersion\IniFileMapping\afsdsbmt.ini"
2055 ;--------------------------------
2056 ;Uninstaller Functions
2060 ;Get language from registry
2061 ReadRegStr $LANGUAGE HKCU "Software\OpenAFS\AFS" "Installer Language"
2065 Function un.onUninstSuccess
2068 MessageBox MB_OK "Please reboot your machine to complete uninstallation of the software"
2073 ;------------------------------
2074 ; Get the CellServDB file from the Internet
2076 Function afs.GetCellServDB
2078 ;Check if we should download CellServDB
2079 ReadINIStr $R0 $0 "Field 4" "State"
2080 StrCmp $R0 "1" DoDownload
2082 ;Do nothing if we're keeping the existing file
2083 ReadINIStr $R0 $0 "Field 2" "State"
2086 ReadINIStr $R0 $0 "Field 6" "State"
2087 StrCmp $R0 "1" CheckOther
2089 ReadINIStr $R0 $0 "Field 3" "State"
2090 StrCmp $R0 "1" UsePackaged
2092 ; If none of these, grab file from other location
2096 ReadINIStr $R0 $0 "Field 5" "State"
2097 NSISdl::download $R0 "$INSTDIR\Client\CellServDB"
2098 Pop $R0 ;Get the return value
2099 StrCmp $R0 "success" +2
2100 MessageBox MB_OK|MB_ICONSTOP "Download failed: $R0"
2104 SetOutPath "$INSTDIR\Client"
2109 ReadINIStr $R0 $0 "Field 7" "State"
2111 CopyFiles $R0 "$INSTDIR\Client\CellServDB"
2117 Function AddProvider
2120 ReadRegStr $R0 HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\HWOrder" "ProviderOrder"
2122 StrCpy $R0 "TransarcAFSDaemon"
2126 StrCmp $R0 "" +1 DoOther
2127 ReadRegStr $R1 HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\HWOrder" "ProviderOrder"
2128 StrCpy $R0 "$R1,TransarcAFSDaemon"
2129 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\HWOrder" "ProviderOrder" $R0
2131 ReadRegStr $R0 HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\Order" "ProviderOrder"
2133 StrCpy $R0 "TransarcAFSDaemon"
2137 StrCmp $R0 "" +1 End
2138 ReadRegStr $R1 HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\Order" "ProviderOrder"
2139 StrCpy $R0 "$R1,TransarcAFSDaemon"
2140 WriteRegStr HKLM "SYSTEM\CurrentControlSet\Control\NetworkProvider\Order" "ProviderOrder" $R0
2146 Function un.RemoveProvider
2148 StrCpy $R0 "TransarcAFSDaemon"
2150 StrCpy $R0 "SYSTEM\CurrentControlSet\Control\NetworkProvider\HWOrder"
2151 Call un.RemoveFromProvider
2152 StrCpy $R0 "TransarcAFSDaemon"
2154 StrCpy $R0 "SYSTEM\CurrentControlSet\Control\NetworkProvider\Order"
2155 Call un.RemoveFromProvider
2159 Function un.RemoveFromProvider
2168 ReadRegStr $1 HKLM "$R0" "ProviderOrder"
2169 StrCpy $5 $1 1 -1 # copy last char
2170 StrCmp $5 "," +2 # if last char != ,
2171 StrCpy $1 "$1," # append ,
2174 Call un.StrStr ; Find `$0,` in $1
2175 Pop $2 ; pos of our dir
2176 StrCmp $2 "" unRemoveFromPath_done
2177 ; else, it is in path
2182 StrCpy $5 $1 -$4 # $5 is now the part before the path to remove
2183 StrCpy $6 $2 "" $3 # $6 is now the part after the path to remove
2186 StrCpy $5 $3 1 -1 # copy last char
2187 StrCmp $5 "," 0 +2 # if last char == ,
2188 StrCpy $3 $3 -1 # remove last char
2190 WriteRegStr HKLM "$R0" "ProviderOrder" $3
2192 unRemoveFromPath_done:
2202 Function CheckPathForAFS
2207 ReadRegStr $1 HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "PATH"
2216 IfFileExists "$3\afsd_service.exe" Error
2217 StrCpy $1 $0 32768 1
2219 IntCmp $2 0 Done Done loop
2222 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."
2223 Abort "Unable to install OpenAFS"
2231 Function AddToUniquePath
2235 ReadRegStr $R0 HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "PATH"
2239 StrCmp $R0 "" +1 Done
2245 ;-------------------------------
2246 ;Do the page to get the CellServDB
2248 Function AFSPageGetCellServDB
2249 ; Skip this page if we are not installing the client
2250 SectionGetFlags ${secClient} $R0
2251 IntOp $R0 $R0 & ${SF_SELECTED}
2254 ; Set the install options here
2257 WriteINIStr $0 "Field 2" "Flags" "DISABLED"
2258 WriteINIStr $0 "Field 3" "State" "1"
2259 WriteINISTR $0 "Field 4" "State" "0"
2260 WriteINIStr $0 "Field 6" "State" "0"
2262 ; If there is an existing afsdcell.ini file, migrate it to CellServDB
2263 IfFileExists "$WINDIR\afsdcell.ini" +1 +3
2264 CopyFiles /SILENT "$WINDIR\afsdcell.ini" "$INSTDIR\Client\CellServDB"
2265 Delete "$WINDIR\afsdcell.ini"
2266 ; If there is an existing CellServDB file, allow the user to choose it and make it default
2267 IfFileExists "$INSTDIR\Client\CellServDB" +1 notpresent
2268 WriteINIStr $0 "Field 2" "Flags" "ENABLED"
2269 WriteINIStr $0 "Field 2" "State" "1"
2270 WriteINIStr $0 "Field 3" "State" "0"
2274 !insertmacro MUI_HEADER_TEXT "CellServDB Configuration" "Please choose a method for installing the CellServDB file:"
2275 InstallOptions::dialog $0
2277 StrCmp $R1 "cancel" exit
2278 StrCmp $R1 "back" done
2279 StrCmp $R1 "success" done
2283 ; Check that if a file is set, a valid filename is entered...
2284 ReadINIStr $R0 $0 "Field 6" "State"
2285 StrCmp $R0 "1" CheckFileName
2287 ;Check if a URL is specified, one *IS* specified
2288 ReadINIStr $R0 $0 "Field 4" "State"
2289 StrCmp $R0 "1" CheckURL Skip
2292 ReadINIStr $R0 $0 "Field 5" "State"
2293 StrCmp $R0 "" +1 Skip
2294 MessageBox MB_OK|MB_ICONSTOP $(URLError)
2295 WriteINIStr $0 "Field 4" "State" "0"
2299 ReadINIStr $R0 $0 "Field 7" "State"
2300 IfFileExists $R0 Skip
2302 MessageBox MB_OK|MB_ICONSTOP $(CellError)
2303 WriteINIStr $0 "Field 6" "State" "0"
2311 Function AFSPageGetCellName
2313 ; Skip this page if we are not installing the client
2314 SectionGetFlags ${secClient} $R0
2315 IntOp $R0 $R0 & ${SF_SELECTED}
2319 ; We want to read in the existing parameters and make them the defaults
2322 ReadRegDWORD $R1 HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "SecurityLevel"
2324 WriteINIStr $1 "Field 3" "State" $R1
2326 WriteINIStr $1 "Field 3" "State" "1"
2329 ReadRegDWORD $R1 HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "UseDNS"
2331 WriteINIStr $1 "Field 9" "State" $R1
2333 WriteINIStr $1 "Field 9" "State" "1"
2335 ; Use integrated logon
2336 ReadRegDWORD $R1 HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "LogonOptions"
2338 WriteINIStr $1 "Field 7" "State" $R1
2340 WriteINIStr $1 "Field 7" "State" "0"
2342 ; If this is a server install, we do NOT want to recommend the Freelance client
2343 ; And we do not need to ask for the cell name.
2344 SectionGetFlags ${secServer} $R1
2345 IntOp $R1 $R1 & ${SF_SELECTED}
2346 StrCmp $R1 "1" +1 NotServer
2347 WriteINIStr $1 "Field 6" "Text" "Enable AFS Freelance client (Not Recommended for servers)"
2348 ReadRegDWORD $R1 HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "FreelanceClient"
2350 WriteINIStr $1 "Field 5" "State" $R1
2352 WriteINIStr $1 "Field 5" "State" "0"
2353 WriteINIStr $1 "Field 1" "Flags" "DISABLED"
2354 WriteINIStr $1 "Field 2" "Flags" "DISABLED"
2357 WriteINIStr $1 "Field 6" "Text" "Enable AFS Freelance client (Recommended)"
2358 ReadRegDWORD $R1 HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "FreelanceClient"
2360 WriteINIStr $1 "Field 5" "State" $R1
2362 WriteINIStr $1 "Field 5" "State" "1"
2363 WriteINIStr $1 "Field 1" "Flags" ""
2364 WriteINIStr $1 "Field 2" "Flags" ""
2366 ; Get the current cell name, if any
2367 ReadRegStr $R1 HKLM "SYSTEM\CurrentControlSet\Services\TransarcAFSDaemon\Parameters" "Cell"
2369 WriteINIStr $1 "Field 2" "State" $R1
2370 !insertmacro MUI_HEADER_TEXT "Client Cell Name Configuration" "Please enter the name for your default cell:"
2371 InstallOptions::dialog $1
2373 StrCmp $R1 "cancel" exit
2374 StrCmp $R1 "back" done
2375 StrCmp $R1 "success" done
2378 ReadINIStr $R0 $1 "Field 2" "State"
2379 StrCmp $R0 "" +1 good
2381 MessageBox MB_OK|MB_ICONSTOP $(CellNameError)
2387 ;---------------------------------------------------------
2388 ;Do the page to get the afscreds.exe startup configuration
2390 Function AFSPageConfigAFSCreds
2391 ; Skip this page if we are not installing the client
2392 SectionGetFlags ${secClient} $R0
2393 IntOp $R0 $R0 & ${SF_SELECTED}
2396 ; Set the install options here
2398 !insertmacro MUI_HEADER_TEXT "AFS Credentials Configuration" "Please choose default options for configuring the AFS Credentials program:"
2399 InstallOptions::dialog $2
2401 StrCmp $R1 "cancel" exit
2402 StrCmp $R1 "back" done
2403 StrCmp $R1 "success" done
2411 ; Common install routines for each module
2412 Function AFSCommon.Install
2414 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "DisplayName" "OpenAFS for Windows"
2415 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "UninstallString" "$INSTDIR\uninstall.exe"
2417 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "DisplayVersion" "${AFS_VERSION}"
2419 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "DisplayVersion" "${AFS_VERSION} Checked/Debug"
2421 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenAFS" "URLInfoAbout" "http://www.openafs.org/"
2426 ;-------------------
2427 ; Get the currently installed version and place it on the stack
2429 Function GetInstalledVersion
2434 ReadRegStr $R0 HKLM "Software\TransarcCorporation\$R2\CurrentVersion" "VersionString"
2435 StrCmp $R0 "" NotTransarc done
2439 ReadRegStr $R0 HKLM "${AFS_REGKEY_ROOT}\$R2\CurrentVersion" "VersionString"
2448 ; Functions to get each component of the version number
2449 Function GetInstalledVersionMajor
2454 ReadRegDWORD $R0 HKLM "Software\TransarcCorporation\$R2\CurrentVersion" "MajorVersion"
2455 StrCmp $R0 "" NotTransarc done
2459 ReadRegDWORD $R0 HKLM "${AFS_REGKEY_ROOT}\$R2\CurrentVersion" "MajorVersion"
2468 Function GetInstalledVersionMinor
2473 ReadRegDWORD $R0 HKLM "Software\TransarcCorporation\$R2\CurrentVersion" "MinorVersion"
2474 StrCmp $R0 "" NotTransarc done
2478 ReadRegDWORD $R0 HKLM "${AFS_REGKEY_ROOT}\$R2\CurrentVersion" "MinorVersion"
2487 Function GetInstalledVersionPatch
2492 ReadRegDWORD $R0 HKLM "Software\TransarcCorporation\$R2\CurrentVersion" "PatchLevel"
2493 StrCmp $R0 "" NotTransarc done
2497 ReadRegDWORD $R0 HKLM "${AFS_REGKEY_ROOT}\$R2\CurrentVersion" "PatchLevel"
2508 ;-------------------------------
2509 ; Check if the client should be checked for default install
2510 Function ShouldClientInstall
2512 StrCpy $R2 "AFS Client"
2513 Call GetInstalledVersion
2516 StrCmp $R0 "" NotInstalled
2517 ; Now we see if it's an older or newer version
2519 Call GetInstalledVersionMajor
2521 IntCmpU $R0 ${AFS_MAJORVERSION} +1 Upgrade Downgrade
2523 Call GetInstalledVersionMinor
2525 IntCmpU $R0 ${AFS_MINORVERSION} +1 Upgrade Downgrade
2527 Call GetInstalledVersionPatch
2529 IntCmpU $R0 ${AFS_PATCHLEVEL} Reinstall Upgrade Downgrade
2552 ;-------------------------------
2553 ; Check how the server options should be set
2554 Function ShouldServerInstall
2556 StrCpy $R2 "AFS Server"
2557 Call GetInstalledVersion
2560 StrCmp $R0 "" NotInstalled
2561 ; Now we see if it's an older or newer version
2563 Call GetInstalledVersionMajor
2565 IntCmpU $R0 ${AFS_MAJORVERSION} +1 Upgrade Downgrade
2567 Call GetInstalledVersionMinor
2569 IntCmpU $R0 ${AFS_MINORVERSION} +1 Upgrade Downgrade
2571 Call GetInstalledVersionPatch
2573 IntCmpU $R0 ${AFS_PATCHLEVEL} Reinstall Upgrade Downgrade
2598 ; See if AFS Server is installed
2599 ; Returns: "1" if it is, 0 if it is not (on the stack)
2600 Function IsServerInstalled
2602 StrCpy $R2 "AFS Server"
2603 Call GetInstalledVersion
2606 StrCmp $R0 "" NotInstalled
2619 ; See if AFS Client is installed
2620 ; Returns: "1" if it is, 0 if it is not (on the stack)
2621 Function IsClientInstalled
2623 StrCpy $R2 "AFS Client"
2624 Call GetInstalledVersion
2627 StrCmp $R0 "" NotInstalled
2641 ; See if AFS Documentation is installed
2642 ; Returns: "1" if it is, 0 if it is not (on the stack)
2643 Function IsDocumentationInstalled
2645 StrCpy $R2 "AFS Supplemental Documentation"
2646 Call GetInstalledVersion
2649 StrCmp $R0 "" NotInstalled
2662 ; See if Control Center is installed
2663 ; Returns: "1" if it is, 0 if it is not (on the stack)
2664 Function IsControlInstalled
2666 StrCpy $R2 "AFS Control Center"
2667 Call GetInstalledVersion
2670 StrCmp $R0 "" NotInstalled
2683 !ifdef USE_GETPARAMETERS
2686 ; output, top of stack (replaces, with e.g. whatever)
2687 ; modifies no other variables.
2689 Function GetParameters
2693 StrCpy $R0 $CMDLINE 1
2697 StrCpy $R1 ' ' ; we're scanning for a space instead of a quote
2699 StrCpy $R0 $CMDLINE 1 $R2
2700 StrCmp $R0 $R1 loop2
2706 StrCpy $R0 $CMDLINE 1 $R2
2707 StrCmp $R0 " " loop2
2708 StrCpy $R0 $CMDLINE "" $R2
2716 ;Check to see if any AFS component is installed
2717 ;Returns: Value on stack: "1" if it is, "0" if it is not
2718 Function IsAnyAFSInstalled
2723 Call IsClientInstalled
2725 Call IsServerInstalled
2727 Call IsControlInstalled
2729 Call IsDocumentationInstalled
2731 ; Now we must see if ANY of the $Rn values are 1
2732 StrCmp $R0 "1" SomethingInstalled
2733 StrCmp $R1 "1" SomethingInstalled
2734 StrCmp $R2 "1" SomethingInstalled
2735 StrCmp $R3 "1" SomethingInstalled
2749 ;Install English Language Files
2750 Function AFSLangFiles
2752 SetOutPath "$INSTDIR\Common"
2753 File "${AFS_CLIENT_BUILDDIR}\afs_config.exe"
2754 !insertmacro ReplaceDLL "${AFS_DESTDIR}\lib\afsauthent.dll" "$INSTDIR\Common\afsauthent.dll" "$INSTDIR"
2755 !insertmacro ReplaceDLL "${AFS_DESTDIR}\lib\afspthread.dll" "$INSTDIR\Common\afspthread.dll" "$INSTDIR"
2756 !insertmacro ReplaceDLL "${AFS_DESTDIR}\lib\afsrpc.dll" "$INSTDIR\Common\afsrpc.dll" "$INSTDIR"
2757 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsadminutil.dll" "$INSTDIR\Common\afsadminutil.dll" "$INSTDIR"
2758 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsclientadmin.dll" "$INSTDIR\Common\afsclientadmin.dll" "$INSTDIR"
2759 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsprocmgmt.dll" "$INSTDIR\Common\afsprocmgmt.dll" "$INSTDIR"
2760 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsvosadmin.dll" "$INSTDIR\Common\afsvosadmin.dll" "$INSTDIR"
2761 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAppLib.dll" "$INSTDIR\Common\TaAfsAppLib.dll" "$INSTDIR"
2762 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsvosadmin.dll" "$INSTDIR\Common\afsvosadmin.dll" "$INSTDIR"
2763 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsbosadmin.dll" "$INSTDIR\Common\afsbosadmin.dll" "$INSTDIR"
2764 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afscfgadmin.dll" "$INSTDIR\Common\afscfgadmin.dll" "$INSTDIR"
2765 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afskasadmin.dll" "$INSTDIR\Common\afskasadmin.dll" "$INSTDIR"
2766 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsptsadmin.dll" "$INSTDIR\Common\afsptsadmin.dll" "$INSTDIR"
2768 SetOutPath "$INSTDIR\Common"
2772 !insertmacro ReplaceDLL "${SYSTEMDIR}\msvcr80d.dll" "$INSTDIR\Common\msvcr80d.dll" "$INSTDIR"
2773 !insertmacro ReplaceDLL "${SYSTEMDIR}\msvcp80d.dll" "$INSTDIR\Common\msvcp80d.dll" "$INSTDIR"
2774 !insertmacro ReplaceDLL "${SYSTEMDIR}\mfc80d.dll" "$INSTDIR\Common\mfc80d.dll" "$INSTDIR"
2775 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80CHS.DLL" "$INSTDIR\Common\MFC80CHS.DLL" "$INSTDIR"
2776 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80CHT.DLL" "$INSTDIR\Common\MFC80CHT.DLL" "$INSTDIR"
2777 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80DEU.DLL" "$INSTDIR\Common\MFC80DEU.DLL" "$INSTDIR"
2778 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80ENU.DLL" "$INSTDIR\Common\MFC80ENU.DLL" "$INSTDIR"
2779 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80ESP.DLL" "$INSTDIR\Common\MFC80ESP.DLL" "$INSTDIR"
2780 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80FRA.DLL" "$INSTDIR\Common\MFC80FRA.DLL" "$INSTDIR"
2781 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80ITA.DLL" "$INSTDIR\Common\MFC80ITA.DLL" "$INSTDIR"
2782 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80JPN.DLL" "$INSTDIR\Common\MFC80JPN.DLL" "$INSTDIR"
2783 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80KOR.DLL" "$INSTDIR\Common\MFC80KOR.DLL" "$INSTDIR"
2786 !insertmacro ReplaceDLL "${SYSTEMDIR}\msvcr71d.dll" "$INSTDIR\Common\msvcr71d.dll" "$INSTDIR"
2787 !insertmacro ReplaceDLL "${SYSTEMDIR}\msvcp71d.dll" "$INSTDIR\Common\msvcp71d.dll" "$INSTDIR"
2788 !insertmacro ReplaceDLL "${SYSTEMDIR}\mfc71d.dll" "$INSTDIR\Common\mfc71d.dll" "$INSTDIR"
2789 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71CHS.DLL" "$INSTDIR\Common\MFC71CHS.DLL" "$INSTDIR"
2790 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71CHT.DLL" "$INSTDIR\Common\MFC71CHT.DLL" "$INSTDIR"
2791 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71DEU.DLL" "$INSTDIR\Common\MFC71DEU.DLL" "$INSTDIR"
2792 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71ENU.DLL" "$INSTDIR\Common\MFC71ENU.DLL" "$INSTDIR"
2793 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71ESP.DLL" "$INSTDIR\Common\MFC71ESP.DLL" "$INSTDIR"
2794 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71FRA.DLL" "$INSTDIR\Common\MFC71FRA.DLL" "$INSTDIR"
2795 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71ITA.DLL" "$INSTDIR\Common\MFC71ITA.DLL" "$INSTDIR"
2796 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71JPN.DLL" "$INSTDIR\Common\MFC71JPN.DLL" "$INSTDIR"
2797 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71KOR.DLL" "$INSTDIR\Common\MFC71KOR.DLL" "$INSTDIR"
2800 !insertmacro ReplaceDLL "${SYSTEMDIR}\msvcr70d.dll" "$INSTDIR\Common\msvcr70d.dll" "$INSTDIR"
2801 !insertmacro ReplaceDLL "${SYSTEMDIR}\msvcp70d.dll" "$INSTDIR\Common\msvcp70d.dll" "$INSTDIR"
2802 !insertmacro ReplaceDLL "${SYSTEMDIR}\mfc70d.dll" "$INSTDIR\Common\mfc70d.dll" "$INSTDIR"
2803 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70CHS.DLL" "$INSTDIR\Common\MFC70CHS.DLL" "$INSTDIR"
2804 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70CHT.DLL" "$INSTDIR\Common\MFC70CHT.DLL" "$INSTDIR"
2805 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70DEU.DLL" "$INSTDIR\Common\MFC70DEU.DLL" "$INSTDIR"
2806 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70ENU.DLL" "$INSTDIR\Common\MFC70ENU.DLL" "$INSTDIR"
2807 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70ESP.DLL" "$INSTDIR\Common\MFC70ESP.DLL" "$INSTDIR"
2808 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70FRA.DLL" "$INSTDIR\Common\MFC70FRA.DLL" "$INSTDIR"
2809 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70ITA.DLL" "$INSTDIR\Common\MFC70ITA.DLL" "$INSTDIR"
2810 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70JPN.DLL" "$INSTDIR\Common\MFC70JPN.DLL" "$INSTDIR"
2811 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70KOR.DLL" "$INSTDIR\Common\MFC70KOR.DLL" "$INSTDIR"
2813 !insertmacro ReplaceDLL "${SYSTEMDIR}\mfc42d.dll" "$INSTDIR\Common\mfc42d.dll" "$INSTDIR"
2814 !insertmacro ReplaceDLL "${SYSTEMDIR}\msvcp60d.dll" "$INSTDIR\Common\msvcp60d.dll" "$INSTDIR"
2815 !insertmacro ReplaceDLL "${SYSTEMDIR}\msvcrtd.dll" "$INSTDIR\Common\msvcrtd.dll" "$INSTDIR"
2821 !insertmacro ReplaceDLL "${SYSTEMDIR}\mfc80.dll" "$INSTDIR\Common\mfc80.dll" "$INSTDIR"
2822 !insertmacro ReplaceDLL "${SYSTEMDIR}\msvcr80.dll" "$INSTDIR\Common\msvcr80.dll" "$INSTDIR"
2823 !insertmacro ReplaceDLL "${SYSTEMDIR}\msvcp80.dll" "$INSTDIR\Common\msvcp80.dll" "$INSTDIR"
2824 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80CHS.DLL" "$INSTDIR\Common\MFC80CHS.DLL" "$INSTDIR"
2825 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80CHT.DLL" "$INSTDIR\Common\MFC80CHT.DLL" "$INSTDIR"
2826 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80DEU.DLL" "$INSTDIR\Common\MFC80DEU.DLL" "$INSTDIR"
2827 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80ENU.DLL" "$INSTDIR\Common\MFC80ENU.DLL" "$INSTDIR"
2828 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80ESP.DLL" "$INSTDIR\Common\MFC80ESP.DLL" "$INSTDIR"
2829 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80FRA.DLL" "$INSTDIR\Common\MFC80FRA.DLL" "$INSTDIR"
2830 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80ITA.DLL" "$INSTDIR\Common\MFC80ITA.DLL" "$INSTDIR"
2831 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80JPN.DLL" "$INSTDIR\Common\MFC80JPN.DLL" "$INSTDIR"
2832 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC80KOR.DLL" "$INSTDIR\Common\MFC80KOR.DLL" "$INSTDIR"
2835 !insertmacro ReplaceDLL "${SYSTEMDIR}\mfc71.dll" "$INSTDIR\Common\mfc71.dll" "$INSTDIR"
2836 !insertmacro ReplaceDLL "${SYSTEMDIR}\msvcr71.dll" "$INSTDIR\Common\msvcr71.dll" "$INSTDIR"
2837 !insertmacro ReplaceDLL "${SYSTEMDIR}\msvcp71.dll" "$INSTDIR\Common\msvcp71.dll" "$INSTDIR"
2838 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71CHS.DLL" "$INSTDIR\Common\MFC71CHS.DLL" "$INSTDIR"
2839 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71CHT.DLL" "$INSTDIR\Common\MFC71CHT.DLL" "$INSTDIR"
2840 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71DEU.DLL" "$INSTDIR\Common\MFC71DEU.DLL" "$INSTDIR"
2841 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71ENU.DLL" "$INSTDIR\Common\MFC71ENU.DLL" "$INSTDIR"
2842 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71ESP.DLL" "$INSTDIR\Common\MFC71ESP.DLL" "$INSTDIR"
2843 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71FRA.DLL" "$INSTDIR\Common\MFC71FRA.DLL" "$INSTDIR"
2844 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71ITA.DLL" "$INSTDIR\Common\MFC71ITA.DLL" "$INSTDIR"
2845 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71JPN.DLL" "$INSTDIR\Common\MFC71JPN.DLL" "$INSTDIR"
2846 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC71KOR.DLL" "$INSTDIR\Common\MFC71KOR.DLL" "$INSTDIR"
2849 !insertmacro ReplaceDLL "${SYSTEMDIR}\mfc70.dll" "$INSTDIR\Common\mfc70.dll" "$INSTDIR"
2850 !insertmacro ReplaceDLL "${SYSTEMDIR}\msvcr70.dll" "$INSTDIR\Common\msvcr70.dll" "$INSTDIR"
2851 !insertmacro ReplaceDLL "${SYSTEMDIR}\msvcp70.dll" "$INSTDIR\Common\msvcp70.dll" "$INSTDIR"
2852 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70CHS.DLL" "$INSTDIR\Common\MFC70CHS.DLL" "$INSTDIR"
2853 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70CHT.DLL" "$INSTDIR\Common\MFC70CHT.DLL" "$INSTDIR"
2854 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70DEU.DLL" "$INSTDIR\Common\MFC70DEU.DLL" "$INSTDIR"
2855 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70ENU.DLL" "$INSTDIR\Common\MFC70ENU.DLL" "$INSTDIR"
2856 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70ESP.DLL" "$INSTDIR\Common\MFC70ESP.DLL" "$INSTDIR"
2857 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70FRA.DLL" "$INSTDIR\Common\MFC70FRA.DLL" "$INSTDIR"
2858 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70ITA.DLL" "$INSTDIR\Common\MFC70ITA.DLL" "$INSTDIR"
2859 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70JPN.DLL" "$INSTDIR\Common\MFC70JPN.DLL" "$INSTDIR"
2860 !insertmacro ReplaceDLL "${SYSTEMDIR}\MFC70KOR.DLL" "$INSTDIR\Common\MFC70KOR.DLL" "$INSTDIR"
2862 !insertmacro ReplaceDLL "${SYSTEMDIR}\mfc42.dll" "$INSTDIR\Common\mfc42.dll" "$INSTDIR"
2863 !insertmacro ReplaceDLL "${SYSTEMDIR}\msvcp60.dll" "$INSTDIR\Common\msvcp60.dll" "$INSTDIR"
2864 !insertmacro ReplaceDLL "${SYSTEMDIR}\msvcrt.dll" "$INSTDIR\Common\msvcrt.dll" "$INSTDIR"
2870 StrCmp $LANGUAGE ${LANG_ENGLISH} DoEnglish
2871 StrCmp $LANGUAGE ${LANG_GERMAN} DoGerman
2872 StrCmp $LANGUAGE ${LANG_SPANISH} DoSpanish
2873 StrCmp $LANGUAGE ${LANG_JAPANESE} DoJapanese
2874 StrCmp $LANGUAGE ${LANG_KOREAN} DoKorean
2875 StrCmp $LANGUAGE ${LANG_PORTUGUESEBR} DoPortugueseBR
2876 StrCmp $LANGUAGE ${LANG_SIMPCHINESE} DoSimpChinese
2877 StrCmp $LANGUAGE ${LANG_TRADCHINESE} DoTradChinese
2881 SetOutPath "$INSTDIR\Documentation"
2882 File "..\..\doc\install\Documentation\en_US\README.TXT"
2884 SetOutPath "$INSTDIR\Client\Program"
2885 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afscreds_1033.dll" "$INSTDIR\Client\Program\afscreds_1033.dll" "$INSTDIR"
2886 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1033.dll" "$INSTDIR\Client\Program\afs_shl_ext_1033.dll" "$INSTDIR"
2888 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1033.pdb"
2889 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1033.pdb"
2892 SetOutPath "$INSTDIR\Common"
2893 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_config_1033.dll" "$INSTDIR\Common\afs_config_1033.dll" "$INSTDIR"
2894 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa_1033.dll" "$INSTDIR\Common\afs_cpa_1033.dll" "$INSTDIR"
2895 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afseventmsg_1033.dll" "$INSTDIR\Common\afseventmsg_1033.dll" "$INSTDIR"
2896 ;!insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1033.dll" "$INSTDIR\Common\afs_setup_utils_1033.dll" "$INSTDIR"
2897 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver_1033.dll" "$INSTDIR\Common\afsserver_1033.dll" "$INSTDIR"
2898 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afssvrcfg_1033.dll" "$INSTDIR\Common\afssvrcfg_1033.dll" "$INSTDIR"
2899 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1033.dll" "$INSTDIR\Common\TaAfsAccountManager_1033.dll" "$INSTDIR"
2900 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1033.dll" "$INSTDIR\Common\TaAfsAppLib_1033.dll" "$INSTDIR"
2901 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1033.dll" "$INSTDIR\Common\TaAfsServerManager_1033.dll" "$INSTDIR"
2902 File "..\..\doc\help\en_US\afs-cc.CNT"
2903 File "..\..\doc\help\en_US\afs-cc.hlp"
2904 File "..\..\doc\help\en_US\afs-light.CNT"
2905 File "..\..\doc\help\en_US\afs-light.hlp"
2906 File "..\..\doc\help\en_US\afs-nt.CNT"
2907 File "..\..\doc\help\en_US\afs-nt.HLP"
2908 File "..\..\doc\help\en_US\taafscfg.CNT"
2909 File "..\..\doc\help\en_US\taafscfg.hlp"
2910 File "..\..\doc\help\en_US\taafssvrmgr.CNT"
2911 File "..\..\doc\help\en_US\taafssvrmgr.hlp"
2912 File "..\..\doc\help\en_US\taafsusrmgr.CNT"
2913 File "..\..\doc\help\en_US\taafsusrmgr.hlp"
2916 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1033.pdb"
2917 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1033.pdb"
2918 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1033.pdb"
2919 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1033.pdb"
2920 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1033.pdb"
2921 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1033.pdb"
2922 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1033.pdb"
2923 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1033.pdb"
2929 SetOutPath "$INSTDIR\Documentation"
2930 File "..\..\doc\install\Documentation\de_DE\README.TXT"
2932 SetOutPath "$INSTDIR\Client\Program"
2933 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afscreds_1032.dll" "$INSTDIR\Client\Program\afscreds_1032.dll" "$INSTDIR"
2934 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1032.dll" "$INSTDIR\Client\Program\afs_shl_ext_1032.dll" "$INSTDIR"
2936 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1032.pdb"
2937 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1032.pdb"
2940 SetOutPath "$INSTDIR\Common"
2941 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_config_1032.dll" "$INSTDIR\Common\afs_config_1032.dll" "$INSTDIR"
2942 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa_1032.dll" "$INSTDIR\Common\afs_cpa_1032.dll" "$INSTDIR"
2943 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afseventmsg_1032.dll" "$INSTDIR\Common\afseventmsg_1032.dll" "$INSTDIR"
2944 ;!insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1032.dll" "$INSTDIR\Common\afs_setup_utils_1032.dll" "$INSTDIR"
2945 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver_1032.dll" "$INSTDIR\Common\afsserver_1032.dll" "$INSTDIR"
2946 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afssvrcfg_1032.dll" "$INSTDIR\Common\afssvrcfg_1032.dll" "$INSTDIR"
2947 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1032.dll" "$INSTDIR\Common\TaAfsAccountManager_1032.dll" "$INSTDIR"
2948 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1032.dll" "$INSTDIR\Common\TaAfsAppLib_1032.dll" "$INSTDIR"
2949 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1032.dll" "$INSTDIR\Common\TaAfsServerManager_1032.dll" "$INSTDIR"
2950 File "..\..\doc\help\de_DE\afs-cc.CNT"
2951 File "..\..\doc\help\de_DE\afs-cc.hlp"
2952 File "..\..\doc\help\de_DE\afs-light.CNT"
2953 File "..\..\doc\help\de_DE\afs-light.hlp"
2954 File "..\..\doc\help\de_DE\afs-nt.CNT"
2955 File "..\..\doc\help\de_DE\afs-nt.HLP"
2956 File "..\..\doc\help\de_DE\taafscfg.CNT"
2957 File "..\..\doc\help\de_DE\taafscfg.hlp"
2958 File "..\..\doc\help\de_DE\taafssvrmgr.CNT"
2959 File "..\..\doc\help\de_DE\taafssvrmgr.hlp"
2960 File "..\..\doc\help\de_DE\taafsusrmgr.CNT"
2961 File "..\..\doc\help\de_DE\taafsusrmgr.hlp"
2964 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1032.pdb"
2965 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1032.pdb"
2966 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1032.pdb"
2967 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1032.pdb"
2968 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1032.pdb"
2969 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1032.pdb"
2970 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1032.pdb"
2971 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1032.pdb"
2977 SetOutPath "$INSTDIR\Documentation"
2978 File "..\..\doc\install\Documentation\es_ES\README.TXT"
2980 SetOutPath "$INSTDIR\Client\Program"
2981 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afscreds_1034.dll" "$INSTDIR\Client\Program\afscreds_1034.dll" "$INSTDIR"
2982 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1034.dll" "$INSTDIR\Client\Program\afs_shl_ext_1034.dll" "$INSTDIR"
2984 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1034.pdb"
2985 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1034.pdb"
2988 SetOutPath "$INSTDIR\Common"
2989 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_config_1034.dll" "$INSTDIR\Common\afs_config_1034.dll" "$INSTDIR"
2990 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa_1034.dll" "$INSTDIR\Common\afs_cpa_1034.dll" "$INSTDIR"
2991 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afseventmsg_1034.dll" "$INSTDIR\Common\afseventmsg_1034.dll" "$INSTDIR"
2992 ;!insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1034.dll" "$INSTDIR\Common\afs_setup_utils_1034.dll" "$INSTDIR"
2993 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver_1034.dll" "$INSTDIR\Common\afsserver_1034.dll" "$INSTDIR"
2994 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afssvrcfg_1034.dll" "$INSTDIR\Common\afssvrcfg_1034.dll" "$INSTDIR"
2995 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1034.dll" "$INSTDIR\Common\TaAfsAccountManager_1034.dll" "$INSTDIR"
2996 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1034.dll" "$INSTDIR\Common\TaAfsAppLib_1034.dll" "$INSTDIR"
2997 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1034.dll" "$INSTDIR\Common\TaAfsServerManager_1034.dll" "$INSTDIR"
2998 File "..\..\doc\help\es_ES\afs-cc.CNT"
2999 File "..\..\doc\help\es_ES\afs-cc.hlp"
3000 File "..\..\doc\help\es_ES\afs-light.CNT"
3001 File "..\..\doc\help\es_ES\afs-light.hlp"
3002 File "..\..\doc\help\es_ES\afs-nt.CNT"
3003 File "..\..\doc\help\es_ES\afs-nt.HLP"
3004 File "..\..\doc\help\es_ES\taafscfg.CNT"
3005 File "..\..\doc\help\es_ES\taafscfg.hlp"
3006 File "..\..\doc\help\es_ES\taafssvrmgr.CNT"
3007 File "..\..\doc\help\es_ES\taafssvrmgr.hlp"
3008 File "..\..\doc\help\es_ES\taafsusrmgr.CNT"
3009 File "..\..\doc\help\es_ES\taafsusrmgr.hlp"
3012 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1034.pdb"
3013 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1034.pdb"
3014 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1034.pdb"
3015 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1034.pdb"
3016 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1034.pdb"
3017 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1034.pdb"
3018 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1034.pdb"
3019 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1034.pdb"
3025 SetOutPath "$INSTDIR\Documentation"
3026 File "..\..\doc\install\Documentation\ja_JP\README.TXT"
3028 SetOutPath "$INSTDIR\Client\Program"
3029 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afscreds_1041.dll" "$INSTDIR\Client\Program\afscreds_1041.dll" "$INSTDIR"
3030 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1041.dll" "$INSTDIR\Client\Program\afs_shl_ext_1041.dll" "$INSTDIR"
3032 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1041.pdb"
3033 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1041.pdb"
3036 SetOutPath "$INSTDIR\Common"
3037 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_config_1041.dll" "$INSTDIR\Common\afs_config_1041.dll" "$INSTDIR"
3038 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa_1041.dll" "$INSTDIR\Common\afs_cpa_1041.dll" "$INSTDIR"
3039 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afseventmsg_1041.dll" "$INSTDIR\Common\afseventmsg_1041.dll" "$INSTDIR"
3040 ;!insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1041.dll" "$INSTDIR\Common\afs_setup_utils_1041.dll" "$INSTDIR"
3041 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver_1041.dll" "$INSTDIR\Common\afsserver_1041.dll" "$INSTDIR"
3042 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afssvrcfg_1041.dll" "$INSTDIR\Common\afssvrcfg_1041.dll" "$INSTDIR"
3043 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1041.dll" "$INSTDIR\Common\TaAfsAccountManager_1041.dll" "$INSTDIR"
3044 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1041.dll" "$INSTDIR\Common\TaAfsAppLib_1041.dll" "$INSTDIR"
3045 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1041.dll" "$INSTDIR\Common\TaAfsServerManager_1041.dll" "$INSTDIR"
3046 File "..\..\doc\help\ja_JP\afs-cc.CNT"
3047 File "..\..\doc\help\ja_JP\afs-cc.hlp"
3048 File "..\..\doc\help\ja_JP\afs-light.CNT"
3049 File "..\..\doc\help\ja_JP\afs-light.hlp"
3050 File "..\..\doc\help\ja_JP\afs-nt.CNT"
3051 File "..\..\doc\help\ja_JP\afs-nt.HLP"
3052 File "..\..\doc\help\ja_JP\taafscfg.CNT"
3053 File "..\..\doc\help\ja_JP\taafscfg.hlp"
3054 File "..\..\doc\help\ja_JP\taafssvrmgr.CNT"
3055 File "..\..\doc\help\ja_JP\taafssvrmgr.hlp"
3056 File "..\..\doc\help\ja_JP\taafsusrmgr.CNT"
3057 File "..\..\doc\help\ja_JP\taafsusrmgr.hlp"
3060 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1041.pdb"
3061 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1041.pdb"
3062 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1041.pdb"
3063 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1041.pdb"
3064 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1041.pdb"
3065 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1041.pdb"
3066 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1041.pdb"
3067 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1041.pdb"
3073 SetOutPath "$INSTDIR\Documentation"
3074 File "..\..\doc\install\Documentation\ko_KR\README.TXT"
3076 SetOutPath "$INSTDIR\Client\Program"
3077 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afscreds_1042.dll" "$INSTDIR\Client\Program\afscreds_1042.dll" "$INSTDIR"
3078 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1042.dll" "$INSTDIR\Client\Program\afs_shl_ext_1042.dll" "$INSTDIR"
3080 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1042.pdb"
3081 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1042.pdb"
3084 SetOutPath "$INSTDIR\Common"
3085 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_config_1042.dll" "$INSTDIR\Common\afs_config_1042.dll" "$INSTDIR"
3086 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa_1042.dll" "$INSTDIR\Common\afs_cpa_1042.dll" "$INSTDIR"
3087 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afseventmsg_1042.dll" "$INSTDIR\Common\afseventmsg_1042.dll" "$INSTDIR"
3088 ;!insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1042.dll" "$INSTDIR\Common\afs_setup_utils_1042.dll" "$INSTDIR"
3089 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver_1042.dll" "$INSTDIR\Common\afsserver_1042.dll" "$INSTDIR"
3090 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afssvrcfg_1042.dll" "$INSTDIR\Common\afssvrcfg_1042.dll" "$INSTDIR"
3091 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1042.dll" "$INSTDIR\Common\TaAfsAccountManager_1042.dll" "$INSTDIR"
3092 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1042.dll" "$INSTDIR\Common\TaAfsAppLib_1042.dll" "$INSTDIR"
3093 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1042.dll" "$INSTDIR\Common\TaAfsServerManager_1042.dll" "$INSTDIR"
3094 File "..\..\doc\help\ko_KR\afs-cc.CNT"
3095 File "..\..\doc\help\ko_KR\afs-cc.hlp"
3096 File "..\..\doc\help\ko_KR\afs-light.CNT"
3097 File "..\..\doc\help\ko_KR\afs-light.hlp"
3098 File "..\..\doc\help\ko_KR\afs-nt.CNT"
3099 File "..\..\doc\help\ko_KR\afs-nt.HLP"
3100 File "..\..\doc\help\ko_KR\taafscfg.CNT"
3101 File "..\..\doc\help\ko_KR\taafscfg.hlp"
3102 File "..\..\doc\help\ko_KR\taafssvrmgr.CNT"
3103 File "..\..\doc\help\ko_KR\taafssvrmgr.hlp"
3104 File "..\..\doc\help\ko_KR\taafsusrmgr.CNT"
3105 File "..\..\doc\help\ko_KR\taafsusrmgr.hlp"
3108 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1042.pdb"
3109 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1042.pdb"
3110 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1042.pdb"
3111 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1042.pdb"
3112 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1042.pdb"
3113 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1042.pdb"
3114 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1042.pdb"
3115 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1042.pdb"
3122 SetOutPath "$INSTDIR\Documentation"
3123 File "..\..\doc\install\Documentation\pt_BR\README.TXT"
3125 SetOutPath "$INSTDIR\Client\Program"
3126 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afscreds_1046.dll" "$INSTDIR\Client\Program\afscreds_1046.dll" "$INSTDIR"
3127 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1046.dll" "$INSTDIR\Client\Program\afs_shl_ext_1046.dll" "$INSTDIR"
3129 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1046.pdb"
3130 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1046.pdb"
3133 SetOutPath "$INSTDIR\Common"
3134 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_config_1046.dll" "$INSTDIR\Common\afs_config_1046.dll" "$INSTDIR"
3135 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa_1046.dll" "$INSTDIR\Common\afs_cpa_1046.dll" "$INSTDIR"
3136 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afseventmsg_1046.dll" "$INSTDIR\Common\afseventmsg_1046.dll" "$INSTDIR"
3137 ;!insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1046.dll" "$INSTDIR\Common\afs_setup_utils_1046.dll" "$INSTDIR"
3138 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver_1046.dll" "$INSTDIR\Common\afsserver_1046.dll" "$INSTDIR"
3139 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afssvrcfg_1046.dll" "$INSTDIR\Common\afssvrcfg_1046.dll" "$INSTDIR"
3140 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1046.dll" "$INSTDIR\Common\TaAfsAccountManager_1046.dll" "$INSTDIR"
3141 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1046.dll" "$INSTDIR\Common\TaAfsAppLib_1046.dll" "$INSTDIR"
3142 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1046.dll" "$INSTDIR\Common\TaAfsServerManager_1046.dll" "$INSTDIR"
3143 File "..\..\doc\help\pt_BR\afs-cc.CNT"
3144 File "..\..\doc\help\pt_BR\afs-cc.hlp"
3145 File "..\..\doc\help\pt_BR\afs-light.CNT"
3146 File "..\..\doc\help\pt_BR\afs-light.hlp"
3147 File "..\..\doc\help\pt_BR\afs-nt.CNT"
3148 File "..\..\doc\help\pt_BR\afs-nt.HLP"
3149 File "..\..\doc\help\pt_BR\taafscfg.CNT"
3150 File "..\..\doc\help\pt_BR\taafscfg.hlp"
3151 File "..\..\doc\help\pt_BR\taafssvrmgr.CNT"
3152 File "..\..\doc\help\pt_BR\taafssvrmgr.hlp"
3153 File "..\..\doc\help\pt_BR\taafsusrmgr.CNT"
3154 File "..\..\doc\help\pt_BR\taafsusrmgr.hlp"
3157 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1046.pdb"
3158 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1046.pdb"
3159 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1046.pdb"
3160 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1046.pdb"
3161 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1046.pdb"
3162 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1046.pdb"
3163 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1046.pdb"
3164 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1046.pdb"
3170 SetOutPath "$INSTDIR\Documentation"
3171 File "..\..\doc\install\Documentation\zh_CN\README.TXT"
3173 SetOutPath "$INSTDIR\Client\Program"
3174 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afscreds_2052.dll" "$INSTDIR\Client\Program\afscreds_2052.dll" "$INSTDIR"
3175 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_2052.dll" "$INSTDIR\Client\Program\afs_shl_ext_2052.dll" "$INSTDIR"
3177 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_2052.pdb"
3178 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_2052.pdb"
3181 SetOutPath "$INSTDIR\Common"
3182 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_config_2052.dll" "$INSTDIR\Common\afs_config_2052.dll" "$INSTDIR"
3183 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa_2052.dll" "$INSTDIR\Common\afs_cpa_2052.dll" "$INSTDIR"
3184 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afseventmsg_2052.dll" "$INSTDIR\Common\afseventmsg_2052.dll" "$INSTDIR"
3185 ;!insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afs_setup_utils_2052.dll" "$INSTDIR\Common\afs_setup_utils_2052.dll" "$INSTDIR"
3186 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver_2052.dll" "$INSTDIR\Common\afsserver_2052.dll" "$INSTDIR"
3187 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afssvrcfg_2052.dll" "$INSTDIR\Common\afssvrcfg_2052.dll" "$INSTDIR"
3188 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_2052.dll" "$INSTDIR\Common\TaAfsAccountManager_2052.dll" "$INSTDIR"
3189 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_2052.dll" "$INSTDIR\Common\TaAfsAppLib_2052.dll" "$INSTDIR"
3190 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_2052.dll" "$INSTDIR\Common\TaAfsServerManager_2052.dll" "$INSTDIR"
3191 File "..\..\doc\help\zh_CN\afs-cc.CNT"
3192 File "..\..\doc\help\zh_CN\afs-cc.hlp"
3193 File "..\..\doc\help\zh_CN\afs-light.CNT"
3194 File "..\..\doc\help\zh_CN\afs-light.hlp"
3195 File "..\..\doc\help\zh_CN\afs-nt.CNT"
3196 File "..\..\doc\help\zh_CN\afs-nt.HLP"
3197 File "..\..\doc\help\zh_CN\taafscfg.CNT"
3198 File "..\..\doc\help\zh_CN\taafscfg.hlp"
3199 File "..\..\doc\help\zh_CN\taafssvrmgr.CNT"
3200 File "..\..\doc\help\zh_CN\taafssvrmgr.hlp"
3201 File "..\..\doc\help\zh_CN\taafsusrmgr.CNT"
3202 File "..\..\doc\help\zh_CN\taafsusrmgr.hlp"
3205 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_2052.pdb"
3206 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_2052.pdb"
3207 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_2052.pdb"
3208 ;File "${AFS_SERVER_BUILDDIR}\afsserver_2052.pdb"
3209 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_2052.pdb"
3210 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_2052.pdb"
3211 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_2052.pdb"
3212 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_2052.pdb"
3218 SetOutPath "$INSTDIR\Documentation"
3219 File "..\..\doc\install\Documentation\zh_TW\README.TXT"
3221 SetOutPath "$INSTDIR\Client\Program"
3222 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afscreds_1028.dll" "$INSTDIR\Client\Program\_1028.dll" "$INSTDIR"
3223 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1028.dll" "$INSTDIR\Client\Program\afs_shl_ext_1028.dll" "$INSTDIR"
3225 ;File "${AFS_CLIENT_BUILDDIR}\afscreds_1028.pdb"
3226 ;File "${AFS_CLIENT_BUILDDIR}\afs_shl_ext_1028.pdb"
3229 SetOutPath "$INSTDIR\Common"
3230 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_config_1028.dll" "$INSTDIR\Common\afs_config_1028.dll" "$INSTDIR"
3231 !insertmacro ReplaceDLL "${AFS_CLIENT_BUILDDIR}\afs_cpa_1028.dll" "$INSTDIR\Common\afs_cpa_1028.dll" "$INSTDIR"
3232 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afseventmsg_1028.dll" "$INSTDIR\Common\afseventmsg_1028.dll" "$INSTDIR"
3233 ;!insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afs_setup_utils_1028.dll" "$INSTDIR\Common\afs_setup_utils_1028.dll" "$INSTDIR"
3234 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afsserver_1028.dll" "$INSTDIR\Common\afsserver_1028.dll" "$INSTDIR"
3235 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\afssvrcfg_1028.dll" "$INSTDIR\Common\afssvrcfg_1028.dll" "$INSTDIR"
3236 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1028.dll" "$INSTDIR\Common\TaAfsAccountManager_1028.dll" "$INSTDIR"
3237 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1028.dll" "$INSTDIR\Common\TaAfsAppLib_1028.dll" "$INSTDIR"
3238 !insertmacro ReplaceDLL "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1028.dll" "$INSTDIR\Common\TaAfsServerManager_1028.dll" "$INSTDIR"
3239 File "..\..\doc\help\zh_TW\afs-cc.CNT"
3240 File "..\..\doc\help\zh_TW\afs-cc.hlp"
3241 File "..\..\doc\help\zh_TW\afs-light.CNT"
3242 File "..\..\doc\help\zh_TW\afs-light.hlp"
3243 File "..\..\doc\help\zh_TW\afs-nt.CNT"
3244 File "..\..\doc\help\zh_TW\afs-nt.HLP"
3245 File "..\..\doc\help\zh_TW\taafscfg.CNT"
3246 File "..\..\doc\help\zh_TW\taafscfg.hlp"
3247 File "..\..\doc\help\zh_TW\taafssvrmgr.CNT"
3248 File "..\..\doc\help\zh_TW\taafssvrmgr.hlp"
3249 File "..\..\doc\help\zh_TW\taafsusrmgr.CNT"
3250 File "..\..\doc\help\zh_TW\taafsusrmgr.hlp"
3253 ;File "${AFS_CLIENT_BUILDDIR}\afs_config_1028.pdb"
3254 ;File "${AFS_CLIENT_BUILDDIR}\afs_cpa_1028.pdb"
3255 ;File "${AFS_SERVER_BUILDDIR}\afseventmsg_1028.pdb"
3256 ;File "${AFS_SERVER_BUILDDIR}\afsserver_1028.pdb"
3257 ;File "${AFS_SERVER_BUILDDIR}\afssvrcfg_1028.pdb"
3258 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAccountManager_1028.pdb"
3259 ;File "${AFS_SERVER_BUILDDIR}\TaAfsAppLib_1028.pdb"
3260 ;File "${AFS_SERVER_BUILDDIR}\TaAfsServerManager_1028.pdb"
3269 ;====================================================
3270 ; AddToPath - Adds the given dir to the search path.
3271 ; Input - head of the stack
3272 ; Note - Win9x systems requires reboot
3273 ;====================================================
3280 # don't add if the path doesn't exist
3281 IfFileExists $0 "" AddToPath_done
3288 StrCmp $2 "" "" AddToPath_done
3293 StrCmp $2 "" "" AddToPath_done
3294 GetFullPathName /SHORT $3 $0
3299 StrCmp $2 "" "" AddToPath_done
3304 StrCmp $2 "" "" AddToPath_done
3308 StrCmp $1 1 AddToPath_NT
3311 FileOpen $1 "$1\autoexec.bat" a
3314 IntCmp $2 26 0 +2 +2 # DOS EOF
3315 FileSeek $1 -1 END # write over EOF
3316 FileWrite $1 "$\r$\nSET PATH=%PATH%;$3$\r$\n"
3322 ReadRegStr $1 HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "PATH"
3323 StrCpy $2 $1 1 -1 # copy last char
3324 StrCmp $2 ";" 0 +2 # if last char == ;
3325 StrCpy $1 $1 -1 # remove last char
3326 StrCmp $1 "" AddToPath_NTdoIt
3329 WriteRegExpandStr HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "PATH" $0
3330 SendMessage ${HWND_BROADCAST} ${WM_WININICHANGE} 0 "STR:Environment" /TIMEOUT=5000
3339 ;====================================================
3340 ; RemoveFromPath - Remove a given dir from the path
3341 ; Input: head of the stack
3342 ;====================================================
3343 Function un.RemoveFromPath
3352 IntFmt $6 "%c" 26 # DOS EOF
3356 StrCmp $1 1 unRemoveFromPath_NT
3359 FileOpen $1 "$1\autoexec.bat" r
3362 GetFullPathName /SHORT $0 $0
3363 StrCpy $0 "SET PATH=%PATH%;$0"
3364 Goto unRemoveFromPath_dosLoop
3366 unRemoveFromPath_dosLoop:
3368 StrCpy $5 $3 1 -1 # read last char
3369 StrCmp $5 $6 0 +2 # if DOS EOF
3370 StrCpy $3 $3 -1 # remove DOS EOF so we can compare
3371 StrCmp $3 "$0$\r$\n" unRemoveFromPath_dosLoopRemoveLine
3372 StrCmp $3 "$0$\n" unRemoveFromPath_dosLoopRemoveLine
3373 StrCmp $3 "$0" unRemoveFromPath_dosLoopRemoveLine
3374 StrCmp $3 "" unRemoveFromPath_dosLoopEnd
3376 Goto unRemoveFromPath_dosLoop
3377 unRemoveFromPath_dosLoopRemoveLine:
3379 Goto unRemoveFromPath_dosLoop
3381 unRemoveFromPath_dosLoopEnd:
3385 Delete "$1\autoexec.bat"
3386 CopyFiles /SILENT $4 "$1\autoexec.bat"
3388 Goto unRemoveFromPath_done
3390 unRemoveFromPath_NT:
3391 ReadRegStr $1 HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "PATH"
3392 StrCpy $5 $1 1 -1 # copy last char
3393 StrCmp $5 ";" +2 # if last char != ;
3394 StrCpy $1 "$1;" # append ;
3397 Call un.StrStr ; Find `$0;` in $1
3398 Pop $2 ; pos of our dir
3399 StrCmp $2 "" unRemoveFromPath_done
3400 ; else, it is in path
3405 StrCpy $5 $1 -$4 # $5 is now the part before the path to remove
3406 StrCpy $6 $2 "" $3 # $6 is now the part after the path to remove
3409 StrCpy $5 $3 1 -1 # copy last char
3410 StrCmp $5 ";" 0 +2 # if last char == ;
3411 StrCpy $3 $3 -1 # remove last char
3413 WriteRegExpandStr HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "PATH" $3
3414 SendMessage ${HWND_BROADCAST} ${WM_WININICHANGE} 0 "STR:Environment" /TIMEOUT=5000
3416 unRemoveFromPath_done:
3426 ;====================================================
3427 ; IsNT - Returns 1 if the current system is NT, 0
3429 ; Output: head of the stack
3430 ;====================================================
3434 ReadRegStr $0 HKLM "SOFTWARE\Microsoft\Windows NT\CurrentVersion" CurrentVersion
3435 StrCmp $0 "" 0 IsNT_yes
3447 !insertmacro IsNT ""
3448 !insertmacro IsNT "un."
3450 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
3452 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
3453 ;====================================================
3454 ; StrStr - Finds a given string in another given string.
3455 ; Returns -1 if not found and the pos if found.
3456 ; Input: head of the stack - string to find
3457 ; second in the stack - string to find in
3458 ; Output: head of the stack
3459 ;====================================================
3461 Function ${un}StrStr
3462 Exch $R1 ; st=haystack,old$R1, $R1=needle
3463 Exch ; st=old$R1,haystack
3464 Exch $R2 ; st=old$R1,old$R2, $R2=haystack
3476 StrCpy $R5 $R2 $R3 $R4
3482 StrCpy $R1 $R2 "" $R4
3490 !insertmacro StrStr ""
3491 !insertmacro StrStr "un."
3494 !ifdef ADDSHAREDDLLUSED
3497 ; Increments a shared DLLs reference count.
3498 ; Use by passing one item on the stack (the full path of the DLL).
3501 ; Push $SYSDIR\myDll.dll
3505 Function AddSharedDLL
3508 ReadRegDword $R0 HKLM Software\Microsoft\Windows\CurrentVersion\SharedDLLs $R1
3510 WriteRegDWORD HKLM Software\Microsoft\Windows\CurrentVersion\SharedDLLs $R1 $R0
3516 ; un.RemoveSharedDLL
3518 ; Decrements a shared DLLs reference count, and removes if necessary.
3519 ; Use by passing one item on the stack (the full path of the DLL).
3520 ; Note: for use in the main installer (not the uninstaller), rename the
3521 ; function to RemoveSharedDLL.
3524 ; Push $SYSDIR\myDll.dll
3525 ; Call un.RemoveSharedDLL
3528 Function un.RemoveSharedDLL
3531 ReadRegDword $R0 HKLM Software\Microsoft\Windows\CurrentVersion\SharedDLLs $R1
3532 StrCmp $R0 "" remove
3534 IntCmp $R0 0 rk rk uk
3536 DeleteRegValue HKLM Software\Microsoft\Windows\CurrentVersion\SharedDLLs $R1
3539 WriteRegDWORD HKLM Software\Microsoft\Windows\CurrentVersion\SharedDLLs $R1 $R0
3542 Delete /REBOOTOK $R1
3550 ; Installs the loopback adpater and disables it on Windows 2000
3551 Function afs.InstallMSLoopback
3553 File /oname=$R0 "${AFS_WININSTALL_DIR}\afsloopback.dll"
3554 nsExec::Exec "rundll32.exe $R0 doLoopBackEntry AFS 10.254.254.253 255.255.255.252"
3558 Function afs.isLoopbackInstalled
3560 File "${AFS_WININSTALL_DIR}\afsloopback.dll"
3561 System::Call "$TEMP\afsloopback.dll::IsLoopbackInstalled() i().r11"
3562 Delete "$TEMP\afsloopback.dll"
3568 ; Based on Yazno's function, http://yazno.tripod.com/powerpimpit/
3569 ; Updated by Joost Verburg
3571 ; Returns on top of stack
3573 ; Windows Version (95, 98, ME, NT x.x, 2000, XP, 2003)
3575 ; '' (Unknown Windows Version)
3578 ; Call GetWindowsVersion
3580 ; ; at this point $R0 is "NT 4.0" or whatnot
3582 Function GetWindowsVersion
3589 ReadRegStr $R0 HKLM \
3590 "SOFTWARE\Microsoft\Windows NT\CurrentVersion" CurrentVersion
3592 IfErrors 0 lbl_winnt
3595 ReadRegStr $R0 HKLM \
3596 "SOFTWARE\Microsoft\Windows\CurrentVersion" VersionNumber
3599 StrCmp $R1 '4' 0 lbl_error
3603 StrCmp $R1 '4.0' lbl_win32_95
3604 StrCmp $R1 '4.9' lbl_win32_ME lbl_win32_98
3622 StrCmp $R1 '3' lbl_winnt_x
3623 StrCmp $R1 '4' lbl_winnt_x
3627 StrCmp $R1 '5.0' lbl_winnt_2000
3628 StrCmp $R1 '5.1' lbl_winnt_XP
3629 StrCmp $R1 '5.2' lbl_winnt_2003 lbl_error
3632 StrCpy $R0 "NT $R0" 6
3657 ; Author: Lilla (lilla@earthlink.net) 2003-06-13
3658 ; function IsUserAdmin uses plugin \NSIS\PlusgIns\UserInfo.dll
3659 ; This function is based upon code in \NSIS\Contrib\UserInfo\UserInfo.nsi
3660 ; This function was tested under NSIS 2 beta 4 (latest CVS as of this writing).
3664 ; Pop $R0 ; at this point $R0 is "true" or "false"
3666 Function IsUserAdmin
3675 UserInfo::GetAccountType
3678 StrCmp $R2 "Admin" 0 Continue
3679 ; Observation: I get here when running Win98SE. (Lilla)
3680 ; The functions UserInfo.dll looks for are there on Win98 too,
3681 ; but just don't work. So UserInfo.dll, knowing that admin isn't required
3682 ; on Win98, returns admin anyway. (per kichik)
3683 ; MessageBox MB_OK 'User "$R1" is in the Administrators group'
3688 ; You should still check for an empty string because the functions
3689 ; UserInfo.dll looks for may not be present on Windows 95. (per kichik)
3692 ;MessageBox MB_OK 'User "$R1" is in the "$R2" group'
3696 ; comment/message below is by UserInfo.nsi author:
3697 ; This one means you don't need to care about admin or
3698 ; not admin because Windows 9x doesn't either
3699 ;MessageBox MB_OK "Error! This DLL can't run under Windows 9x!"
3703 ;MessageBox MB_OK 'User= "$R1" AccountType= "$R2" IsUserAdmin= "$R0"'
3711 ; input, top of stack (e.g. C:\Program Files\Poop)
3712 ; output, top of stack (replaces, with e.g. C:\Program Files)
3713 ; modifies no other variables.
3716 ; Push "C:\Program Files\Directory\Whatever"
3719 ; ; at this point $R0 will equal "C:\Program Files\Directory"
3733 IntCmp $R1 $R2 get 0 get
3734 StrCpy $R3 $R0 1 -$R1
3749 ;--------------------------------
3750 ;Handle what must and what must not be installed
3751 Function .onSelChange
3752 ; If they install the server, they MUST install the client
3753 SectionGetFlags ${secServer} $R0
3754 IntOp $R0 $R0 & ${SF_SELECTED}
3755 StrCmp $R0 "1" MakeClientSelected
3757 ; If they install the control center, we'll give them the client.
3758 ; It may not be required, but it's a bit more useful
3759 SectionGetFlags ${secControl} $R0
3760 IntOp $R0 $R0 & ${SF_SELECTED}
3761 StrCmp $R0 "1" MakeClientSelected
3765 SectionGetFlags ${secClient} $R0
3766 IntOp $R0 $R0 | ${SF_SELECTED}
3767 SectionSetFlags ${secClient} $R0
3772 Function RegWriteMultiStr
3773 !define HKEY_CLASSES_ROOT 0x80000000
3774 !define HKEY_CURRENT_USER 0x80000001
3775 !define HKEY_LOCAL_MACHINE 0x80000002
3776 !define HKEY_USERS 0x80000003
3777 !define HKEY_PERFORMANCE_DATA 0x80000004
3778 !define HKEY_PERFORMANCE_TEXT 0x80000050
3779 !define HKEY_PERFORMANCE_NLSTEXT 0x80000060
3780 !define HKEY_CURRENT_CONFIG 0x80000005
3781 !define HKEY_DYN_DATA 0x80000006
3783 !define KEY_QUERY_VALUE 0x0001
3784 !define KEY_SET_VALUE 0x0002
3785 !define KEY_CREATE_SUB_KEY 0x0004
3786 !define KEY_ENUMERATE_SUB_KEYS 0x0008
3787 !define KEY_NOTIFY 0x0010
3788 !define KEY_CREATE_LINK 0x0020
3792 !define REG_EXPAND_SZ 2
3793 !define REG_BINARY 3
3795 !define REG_DWORD_LITTLE_ENDIAN 4
3796 !define REG_DWORD_BIG_ENDIAN 5
3798 !define REG_MULTI_SZ 7
3800 !define RegCreateKey "Advapi32::RegCreateKeyA(i, t, *i) i"
3801 !define RegSetValueEx "Advapi32::RegSetValueExA(i, t, i, i, i, i) i"
3802 !define RegCloseKey "Advapi32::RegCloseKeyA(i) i"
3809 SetPluginUnload alwaysoff
3810 ; Create a buffer for the multi_sz value
3811 System::Call "*(&t${NSIS_MAX_STRLEN}) i.r1"
3812 ; Open/create the registry key
3813 System::Call "${RegCreateKey}(${HKEY_LOCAL_MACHINE}, '$REG_SUB_KEY', .r0) .r9"
3816 MessageBox MB_OK|MB_ICONSTOP "Can't create registry key! ($9)"
3820 ; Fill in the buffer with our strings
3821 StrCpy $2 $1 ; Initial position
3823 StrLen $9 '$REG_DATA_1' ; Length of first string
3824 IntOp $9 $9 + 1 ; Plus null
3825 System::Call "*$2(&t$9 '$REG_DATA_1')" ; Place the string
3826 IntOp $2 $2 + $9 ; Advance to the next position
3828 StrCmp '$REG_DATA_2' "" terminate
3829 StrLen $9 '$REG_DATA_2' ; Length of second string
3830 IntOp $9 $9 + 1 ; Plus null
3831 System::Call "*$2(&t$9 '$REG_DATA_2')" ; Place the string
3832 IntOp $2 $2 + $9 ; Advance to the next position
3834 StrCmp '$REG_DATA_3' "" terminate
3835 StrLen $9 '$REG_DATA_3' ; Length of third string
3836 IntOp $9 $9 + 1 ; Plus null
3837 System::Call "*$2(&t$9 '$REG_DATA_3')" ; Place the string
3838 IntOp $2 $2 + $9 ; Advance to the next position
3840 StrCmp '$REG_DATA_4' "" terminate
3841 StrLen $9 '$REG_DATA_4' ; Length of third string
3842 IntOp $9 $9 + 1 ; Plus null
3843 System::Call "*$2(&t$9 '$REG_DATA_4')" ; Place the string
3844 IntOp $2 $2 + $9 ; Advance to the next position
3847 System::Call "*$2(&t1 '')" ; Place the terminating null
3848 IntOp $2 $2 + 1 ; Advance to the next position
3850 ; Create/write the value
3851 IntOp $2 $2 - $1 ; Total length
3852 System::Call "${RegSetValueEx}(r0, '$REG_VALUE', 0, ${REG_MULTI_SZ}, r1, r2) .r9"
3855 MessageBox MB_OK|MB_ICONSTOP "Can't set key value! ($9)"
3859 ; Close the registry key
3860 System::Call "${RegCloseKey}(r0)"
3864 SetPluginUnload manual
3873 Function CreateDesktopIni
3874 WriteIniStr "$INSTDIR\Desktop.ini" ".ShellClassInfo" "IconFile" "client\program\afsd_service.exe"
3875 WriteIniStr "$INSTDIR\Desktop.ini" ".ShellClassInfo" "IconIndex" "0"
3876 SetFileAttributes "$INSTDIR\Desktop.ini" HIDDEN|SYSTEM
3877 SetFileAttributes "$INSTDIR\" READONLY