/[ascend]/trunk/installer.nsi
ViewVC logotype

Diff of /trunk/installer.nsi

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1566 by jpye, Sat Jun 30 01:23:36 2007 UTC revision 1567 by jpye, Thu Aug 2 15:10:54 2007 UTC
# Line 17  Name "ASCEND ${VERSION}" Line 17  Name "ASCEND ${VERSION}"
17  !define PYVERSION "2.5"  !define PYVERSION "2.5"
18  !endif  !endif
19    
20    !ifndef PYPATCH
21    !define PYPATCH ".1"
22    !endif
23    
24  ; The file to write  ; The file to write
25  !ifdef OUTFILE  !ifdef OUTFILE
26  OutFile ${OUTFILE}  OutFile ${OUTFILE}
# Line 98  Function .onInit Line 102  Function .onInit
102    
103  FunctionEnd  FunctionEnd
104    
   
105  ; The stuff to install  ; The stuff to install
106  Section "ASCEND (required)"  Section "ASCEND (required)"
107      SectionIn RO      SectionIn RO
# Line 189  ascendconfigerror: Line 192  ascendconfigerror:
192            
193  SectionEnd  SectionEnd
194    
195    !define PYTHON_VERSION "${PYVERSION}${PYPATCH}"
196    !define PYTHON_FILENAME "python-${PYTHON_VERSION}.msi"
197    !define PYTHON_URL "http://www.python.org/ftp/python/${PYTHON_VERSION}/${PYTHON_FILENAME}"
198    
199    !define GTK_FILENAME "gtk-2.10.11-win32-1.exe"
200    !define GTK_URL "http://downloads.sourceforge.net/gladewin32/${GTK_FILENAME}"
201    
202    !define PYGOBJECT_FILENAME "pygobject-2.12.3-1.win32-py${PYVERSION}.exe"
203    !define PYGOBJECT_URL "http://ftp.gnome.org/pub/GNOME/binaries/win32/pygobject/2.12/${PYGOBJECT_FILENAME}"
204    
205    !define PYCAIRO_FILENAME "pycairo-1.2.6-1.win32-py${PYVERSION}.exe"
206    !define PYCAIRO_URL "http://ftp.gnome.org/pub/GNOME/binaries/win32/pycairo/1.2/${PYCAIRO_FILENAME}"
207    
208    !define PYGTK_FILENAME "pygtk-2.10.4-1.win32-py${PYVERSION}.exe"
209    !define PYGTK_URL "http://ftp.gnome.org/pub/GNOME/binaries/win32/pygtk/2.10/${PYGTK_FILENAME}"
210    
211    
212    Section "Download prerequisites if necessary"
213        ${If} $PYOK == 'NOK'
214            MessageBox MB_OK "Downloading python..."
215    
216            StrCpy $2 "$TEMP\${PYTHON_FILENAME}"
217            nsisdl::download /TIMEOUT=30000 ${PYTHON_URL} $2
218            Pop $R0 ;Get the return value
219            ${If} $R0 == "success"
220                MessageBox MB_OK "Installing python..."
221                ExecWait $2
222                Delete $2          
223                Call DetectPython
224                Pop $PYOK
225                Pop $PYPATH
226            ${ElseIf} $R0 == "cancel"
227                MessageBox MB_OK "Python download cancelled"
228                Quit
229            ${Else}
230                MessageBox MB_OK "Download failed: $R0"
231                Quit
232            ${EndIf}
233        ${EndIf}
234        
235        ${If} $GTKOK == 'NOK'
236            MessageBox MB_OK "Downloading GTK..."
237            StrCpy $2 "$TEMP\${GTK_FILENAME}"
238            nsisdl::download /TIMEOUT=30000 ${GTK_URL} $2
239            Pop $R0 ;Get the return value
240            ${If} $R0 == "success"
241                MessageBox MB_OK "Installing GTK..."
242                ExecWait $2
243                Delete $2              
244                Call DetectGTK
245                Pop $GTKOK
246                Pop $GTKPATH
247                Call DetectGlade
248                Pop $GLADEOK
249                Pop $GLADEPATH              
250            ${ElseIf} $R0 == "cancel"
251                MessageBox MB_OK "GTK download cancelled"
252                Quit
253            ${Else}
254                MessageBox MB_OK "Download failed: $R0"
255                Quit
256            ${EndIf}
257        ${EndIf}
258        
259        ${If} $PYGOBJECTOK == 'NOK'
260            MessageBox MB_OK "Downloading PyGObject..."
261            StrCpy $2 "$TEMP\${PYGOBJECT_FILENAME}"
262            nsisdl::download /TIMEOUT=30000 ${PYGOBJECT_URL} $2
263            Pop $R0 ;Get the return value
264            ${If} $R0 == "success"
265                MessageBox MB_OK "Installing PyGObject..."
266                ExecWait $2
267                Delete $2              
268                Call DetectPyGObject
269                Pop $PYGOBJECTOK
270            ${ElseIf} $R0 == "cancel"
271                MessageBox MB_OK "PyGObject download cancelled"
272                Quit
273            ${Else}
274                MessageBox MB_OK "Download failed: $R0"
275                Quit
276            ${EndIf}
277        ${EndIf}
278        
279        ${If} $PYCAIROOK == 'NOK'
280            MessageBox MB_OK "Downloading PyCairo..."
281            StrCpy $2 "$TEMP\${PYCAIRO_FILENAME}"
282            nsisdl::download /TIMEOUT=30000 ${PYCAIRO_URL} $2
283            Pop $R0 ;Get the return value
284            ${If} $R0 == "success"
285                MessageBox MB_OK "Installing PyCairo..."
286                ExecWait $2
287                Delete $2              
288                Call DetectPyCairo
289                Pop $PYCAIROOK
290            ${ElseIf} $R0 == "cancel"
291                MessageBox MB_OK "PyCairo download cancelled"
292                Quit
293            ${Else}
294                MessageBox MB_OK "Download failed: $R0"
295                Quit
296            ${EndIf}
297        ${EndIf}
298    
299        
300        ${If} $PYGTKOK == 'NOK'
301            MessageBox MB_OK "Downloading PyGTK..."
302            StrCpy $2 "$TEMP\${PYGTK_FILENAME}"
303            nsisdl::download /TIMEOUT=30000 ${PYGTK_URL} $2
304            Pop $R0 ;Get the return value
305            ${If} $R0 == "success"
306                MessageBox MB_OK "Installing PyGTK..."
307                ExecWait $2
308                Delete $2              
309                Call DetectPyGTK
310                Pop $PYGTKOK
311            ${ElseIf} $R0 == "cancel"
312                MessageBox MB_OK "PyGTK download cancelled"
313                Quit
314            ${Else}
315                MessageBox MB_OK "Download failed: $R0"
316                Quit
317            ${EndIf}
318        ${EndIf}    
319        
320    SectionEnd  
321    
322  ;--------------------------------  ;--------------------------------
323    
324  Section "PyGTK GUI"  Section "PyGTK GUI"
# Line 198  Section "PyGTK GUI" Line 328  Section "PyGTK GUI"
328      ${ElseIf} $GTKOK == 'NOK'      ${ElseIf} $GTKOK == 'NOK'
329          MessageBox MB_OK "PyGTK GUI cannot be installed, because GTK+ 2.x was not found on this system.$\nIf you do want to use the PyGTK GUI, please check the installation instructions$\n$\n(GTKPATH=$GTKPATH)"          MessageBox MB_OK "PyGTK GUI cannot be installed, because GTK+ 2.x was not found on this system.$\nIf you do want to use the PyGTK GUI, please check the installation instructions$\n$\n(GTKPATH=$GTKPATH)"
330      ${ElseIf} $GLADEOK == 'NOK'      ${ElseIf} $GLADEOK == 'NOK'
331          MessageBox MB_OK "PyGTK GUI cannot be installed, because Glade 2.x was not found on this system.$\nIf you do want to use the PyGTK GUI, please check the installation instructions$\n$\n(GTKPATH=$GTKPATH)"          MessageBox MB_OK "PyGTK GUI cannot be installed, because Glade 2.x was not found on this system.$\nIf you do want to use the PyGTK GUI, please check the installation instructions$\n$\n(GTKPATH=$GTKPATH).\n\nIf you do have GTK+ runtime installed, make sure\nyou have a version that includes support for Glade."
332      ${ElseIf} $PYGTKOK == "NOK"      ${ElseIf} $PYGTKOK == "NOK"
333          MessageBox MB_OK "PyGTK GUI cannot be installed, because PyGTK was not found on this system.$\nPlease check the installation instructions.$\n$\n(PYPATH=$PYPATH)"          MessageBox MB_OK "PyGTK GUI cannot be installed, because PyGTK was not found on this system.$\nPlease check the installation instructions.$\n$\n(PYPATH=$PYPATH)"
334      ${ElseIf} $PYCAIROOK == "NOK"      ${ElseIf} $PYCAIROOK == "NOK"
# Line 274  SectionEnd Line 404  SectionEnd
404    
405  Section "Tcl/Tk GUI"  Section "Tcl/Tk GUI"
406    
407  ${If} $TCLOK != 'OK'      ${If} $TCLOK != 'OK'
408      MessageBox MB_OK "Tck/Tk GUI can not be installed, because ActiveTcl was not found on this system. If do you want to use the Tcl/Tk GUI, please check the installation instructions ($TCLPATH)"          MessageBox MB_OK "Tck/Tk GUI can not be installed, because ActiveTcl was not found on this system. If do you want to use the Tcl/Tk GUI, please check the installation instructions ($TCLPATH)"
409  ${Else}      ${Else}
410      DetailPrint "--- TCL/TK INTERFACE ---"          DetailPrint "--- TCL/TK INTERFACE ---"
411      SetOutPath $INSTDIR\tcltk          SetOutPath $INSTDIR\tcltk
412      File /r /x .svn "tcltk\TK\*"          File /r /x .svn "tcltk\TK\*"
413      SetOutPath $INSTDIR          SetOutPath $INSTDIR
414      File "tcltk\generic\interface\ascendtcl.dll"          File "tcltk\generic\interface\ascendtcl.dll"
415      File "tcltk\generic\interface\ascend4.exe"          File "tcltk\generic\interface\ascend4.exe"
416        
417      StrCpy $TCLINSTALLED "1"          StrCpy $TCLINSTALLED "1"
418      WriteRegDWORD HKLM "SOFTWARE\ASCEND" "TclTk" 1          WriteRegDWORD HKLM "SOFTWARE\ASCEND" "TclTk" 1
419    
420  ${EndIf}      ${EndIf}
421    
422  SectionEnd  SectionEnd
423    

Legend:
Removed from v.1566  
changed lines
  Added in v.1567

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22