/[pcsx2_0.9.7]/trunk/nsis/pcsx2_full_install.nsi
ViewVC logotype

Contents of /trunk/nsis/pcsx2_full_install.nsi

Parent Directory Parent Directory | Revision Log Revision Log


Revision 401 - (show annotations) (download)
Fri Feb 25 17:31:09 2011 UTC (8 years, 8 months ago) by william
File size: 6904 byte(s)
Auto Commited Import of: pcsx2-0.9.7-DEBUG (upstream: v0.9.7.4358 local: v0.9.7.313-latest) in ./trunk
1
2 ; PCSX2 Full/Complete Install Package!
3 ; (a NSIS installer script)
4 ;
5 ; Copyright 2009-2010 PCSX2 Dev Team
6 ;
7
8 !ifndef INC_CRT_2008
9 ; Set to 0 to disable inclusion of Visual Studio 2008 SP1 CRT Redists
10 !define INC_CRT_2008 1
11 !endif
12
13 !ifndef INC_CRT_2010
14 ; Set to 0 to disable inclusion of Visual Studio 2010 CRT Redists
15 !define INC_CRT_2010 1
16 !endif
17
18 !define OUTFILE_POSTFIX "setup"
19 !include "SharedBase.nsh"
20
21 ; Reserve features for improved performance with solid archiving.
22 File C:\Users\Jake\Documents\devpcsx2\trunk\nsis\SharedBase.nsh
23 ; (uncomment if we add our own install options ini files)
24 ;!insertmacro MUI_RESERVEFILE_INSTALLOPTIONS
25 ;!insertmacro MUI_RESERVEFILE_LANGDLL
26
27 !insertmacro MUI_PAGE_COMPONENTS
28 !insertmacro MUI_PAGE_DIRECTORY
29 !insertmacro MUI_PAGE_INSTFILES
30
31 !insertmacro MUI_UNPAGE_CONFIRM
32 !insertmacro MUI_UNPAGE_COMPONENTS
33 !insertmacro MUI_UNPAGE_INSTFILES
34
35 !insertmacro MUI_LANGUAGE "English"
36
37 !include "ApplyExeProps.nsh"
38 !include "SharedRedtape.nsh"
39
40 ; =======================================================================
41 ; Installer Sections
42 ; =======================================================================
43
44 ; -----------------------------------------------------------------------
45 ; Basic section (emulation proper)
46 Section "!${APP_NAME} (required)" SEC_CORE
47
48 SectionIn RO
49
50 !include "SectionCoreReqs.nsh"
51
52 ; ------------------------------------------
53 ; -- Plugins Section --
54 ; ------------------------------------------
55
56 !if ${INC_PLUGINS} > 0
57
58 SetOutPath "$INSTDIR\Plugins"
59 !insertmacro UNINSTALL.LOG_OPEN_INSTALL
60
61 File /nonfatal /oname=gsdx-sse2-r${SVNREV_GSDX}.dll ..\bin\Plugins\gsdx-sse2.dll
62 File /nonfatal /oname=gsdx-ssse3-r${SVNREV_GSDX}.dll ..\bin\Plugins\gsdx-ssse3.dll
63 File /nonfatal /oname=gsdx-sse4-r${SVNREV_GSDX}.dll ..\bin\Plugins\gsdx-sse4.dll
64 File /nonfatal /oname=zerogs-r${SVNREV_ZEROGS}.dll ..\bin\Plugins\zerogs.dll
65
66 File /nonfatal /oname=spu2-x-r${SVNREV_SPU2X}.dll ..\bin\Plugins\spu2-x.dll
67 File /nonfatal /oname=zerospu2-r${SVNREV_ZEROSPU2}.dll ..\bin\Plugins\zerospu2.dll
68
69 File /nonfatal /oname=cdvdiso-r${SVNREV_CDVDISO}.dll ..\bin\Plugins\cdvdiso.dll
70 File ..\bin\Plugins\cdvdGigaherz.dll
71
72 File /nonfatal /oname=lilypad-r${SVNREV_LILYPAD}.dll ..\bin\Plugins\lilypad.dll
73 File ..\bin\Plugins\PadSSSPSX.dll
74
75 ;File ..\bin\Plugins\FWlinuz.dll
76
77 !insertmacro UNINSTALL.LOG_CLOSE_INSTALL
78
79 !endif
80
81 SectionEnd
82
83 !include "SectionShortcuts.nsh"
84
85 ; -----------------------------------------------------------------------
86 ; MSVC Redistributable - required if the user does not already have it
87 ; Note: if your NSIS generates an error here it means you need to download the latest
88 ; visual studio redist package from microsoft. Any redist 2008/SP1 or newer will do.
89 ;
90 ; IMPORTANT: Online references for how to detect the presence of the VS2008 redists LIE.
91 ; None of the methods are reliable, because the registry keys placed by the MSI installer
92 ; vary depending on operating system *and* MSI installer version (youch).
93 ;
94 !if ${INC_CRT_2008} > 0
95 Section "Microsoft Visual C++ 2008 SP1 Redist (required)" SEC_CRT2008
96
97 SectionIn RO
98
99 ; Downloaded from:
100 ; http://download.microsoft.com/download/d/d/9/dd9a82d0-52ef-40db-8dab-795376989c03/vcredist_x86.exe
101
102 SetOutPath "$TEMP"
103 File "vcredist_2008_sp1_x86.exe"
104 DetailPrint "Running Visual C++ 2008 SP1 Redistributable Setup..."
105 ExecWait '"$TEMP\vcredist_2008_sp1_x86.exe" /qb'
106 DetailPrint "Finished Visual C++ 2008 SP1 Redistributable Setup"
107
108 Delete "$TEMP\vcredist_2008_sp1_x86.exe"
109
110 SectionEnd
111 !endif
112
113 !if ${INC_CRT_2010} > 0
114 Section "Microsoft Visual C++ 2010 Redist (recommended)" SEC_CRT2010
115
116 ;SectionIn RO
117
118 ; Detection made easy: Unlike previous redists, VC2010 now generates a platform
119 ; independent key for checking availability.
120
121 ; Downloaded from:
122 ; http://download.microsoft.com/download/5/B/C/5BC5DBB3-652D-4DCE-B14A-475AB85EEF6E/vcredist_x86.exe
123
124 ClearErrors
125 ReadRegDword $R0 HKLM "SOFTWARE\Microsoft\VisualStudio\10.0\VC\VCRedist\x86" "Installed"
126 IfErrors 0 +2
127 DetailPrint "Visual C++ 2010 Redistributable registry key was not found; assumed to be uninstalled."
128 StrCmp $R0 "1" 0 +3
129 DetailPrint "Visual C++ 2010 Redistributable is already installed; skipping!"
130 Goto done
131
132 SetOutPath "$TEMP"
133 File "vcredist_2010_x86.exe"
134 DetailPrint "Running Visual C++ 2010 Redistributable Setup..."
135 ExecWait '"$TEMP\vcredist_2010_x86.exe" /qb'
136 DetailPrint "Finished Visual C++ 2010 Redistributable Setup"
137
138 Delete "$TEMP\vcredist_2010_x86.exe"
139
140 done:
141 SectionEnd
142 !endif
143
144 ; -----------------------------------------------------------------------
145 ; This section needs to be last, so that in case it fails, the rest of the program will
146 ; be installed cleanly.
147 ;
148 ; This section could be optional, but why not? It's pretty painless to double-check that
149 ; all the libraries are up-to-date.
150 ;
151 Section "DirectX Web Setup (recommended)" SEC_DIRECTX
152
153 ;SectionIn RO
154
155 SetOutPath "$TEMP"
156 File "dxwebsetup.exe"
157 DetailPrint "Running DirectX Web Setup..."
158 ExecWait '"$TEMP\dxwebsetup.exe" /Q' $DirectXSetupError
159 DetailPrint "Finished DirectX Web Setup"
160
161 Delete "$TEMP\dxwebsetup.exe"
162
163 SectionEnd
164
165 !include "SectionUninstaller.nsh"
166
167 LangString DESC_CORE ${LANG_ENGLISH} "Core components (binaries, plugins, languages, etc)."
168
169 LangString DESC_STARTMENU ${LANG_ENGLISH} "Adds shortcuts for PCSX2 to the start menu (all users)."
170 LangString DESC_DESKTOP ${LANG_ENGLISH} "Adds a shortcut for PCSX2 to the desktop (all users)."
171
172 LangString DESC_CRT2008 ${LANG_ENGLISH} "Required by the PCSX2 binaries packaged in this installer."
173 LangString DESC_CRT2010 ${LANG_ENGLISH} "This will be used by future PCSX2 plugins and updates, but is not (yet) necessary."
174 LangString DESC_DIRECTX ${LANG_ENGLISH} "Only uncheck this if you are quite certain your Direct3D runtimes are up to date."
175
176 !insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
177 !insertmacro MUI_DESCRIPTION_TEXT ${SEC_CORE} $(DESC_CORE)
178 !insertmacro MUI_DESCRIPTION_TEXT ${SEC_STARTMENU} $(DESC_STARTMENU)
179 !insertmacro MUI_DESCRIPTION_TEXT ${SEC_DESKTOP} $(DESC_DESKTOP)
180
181 !if ${INC_CRT_2008} > 0
182 !insertmacro MUI_DESCRIPTION_TEXT ${SEC_CRT2008} $(DESC_CRT2008)
183 !endif
184
185 !if ${INC_CRT_2010} > 0
186 !insertmacro MUI_DESCRIPTION_TEXT ${SEC_CRT2010} $(DESC_CRT2010)
187 !endif
188
189 !insertmacro MUI_DESCRIPTION_TEXT ${SEC_DIRECTX} $(DESC_DIRECTX)
190 !insertmacro MUI_FUNCTION_DESCRIPTION_END
191

  ViewVC Help
Powered by ViewVC 1.1.22