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

Diff of /trunk/nsis/installer.nsi

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

revision 1567 by jpye, Thu Aug 2 15:10:54 2007 UTC revision 1568 by jpye, Fri Aug 3 07:46:44 2007 UTC
# Line 11  Line 11 
11    
12  Name "ASCEND ${VERSION}"  Name "ASCEND ${VERSION}"
13    
14    ;SetCompressor /FINAL zlib
15    SetCompressor /SOLID lzma
16    
17  !include LogicLib.nsh  !include LogicLib.nsh
18    !include nsDialogs.nsh
19    
20  !ifndef PYVERSION  !ifndef PYVERSION
21  !define PYVERSION "2.5"  !define PYVERSION "2.5"
# Line 28  OutFile ${OUTFILE} Line 32  OutFile ${OUTFILE}
32  OutFile "ascend-${VERSION}-py${PYVERSION}.exe"  OutFile "ascend-${VERSION}-py${PYVERSION}.exe"
33  !endif  !endif
34    
 ;SetCompressor /FINAL zlib  
 SetCompressor /SOLID lzma  
35    
36  ; The default installation directory  ; The default installation directory
37  InstallDir $PROGRAMFILES\ASCEND  InstallDir $PROGRAMFILES\ASCEND
# Line 42  InstallDirRegKey HKLM "Software\ASCEND" Line 44  InstallDirRegKey HKLM "Software\ASCEND"
44    
45  ; Pages  ; Pages
46    
47    Page license
48    LicenseData LICENSE.txt
49    
50  Page components  Page components
51  Page directory  Page directory
52    Page custom dependenciesPage
53  Page instfiles  Page instfiles
54    
55  UninstPage uninstConfirm  UninstPage uninstConfirm
# Line 218  Section "Download prerequisites if neces Line 224  Section "Download prerequisites if neces
224          Pop $R0 ;Get the return value          Pop $R0 ;Get the return value
225          ${If} $R0 == "success"          ${If} $R0 == "success"
226              MessageBox MB_OK "Installing python..."              MessageBox MB_OK "Installing python..."
227              ExecWait $2              ExecWait 'msiexec /q "$2"' $0
228              Delete $2                        MessageBox MB_OK "python installer returned $0"
229                Delete $2
230              Call DetectPython              Call DetectPython
231              Pop $PYOK              Pop $PYOK
232              Pop $PYPATH              Pop $PYPATH
# Line 566  unnostart: Line 573  unnostart:
573  SectionEnd  SectionEnd
574    
575  ;---------------------------------------------------------------------  ;---------------------------------------------------------------------
576    ; CUSTOM PAGE to DOWNLOAD REQUIRED DEPENDENCIES
577    
578    Var CHECKPY
579    Var CHECKGTK
580    Var CHECKPYGTK
581    Var CHECKPYGOBJECT
582    Var CHECKPYCAIRO
583    
584    Function dependenciesPage
585        
586        ${If} $PYOK == 'OK'
587        ${AndIf} $GTKOK == 'OK'
588        ${AndIf} $PYGTKOK == 'OK'
589        ${AndIf} $PYGOBJECTOK == 'OK'
590        ${AndIf} $PYCAIROOK == 'OK'
591            ; do nothing in this page
592        ${Else}
593            nsDialogs::Create /NOUNLOAD 1018
594            Pop $0
595    
596            ${NSD_CreateLabel} 0 40u 75% 40u "For the components selected, you will need the following\nadditional components, which this installer can download\nand install for you:"
597            Pop $0
598    
599            ${If} $PYOK == 'NOK'
600                ${NSD_CreateCheckbox} 0 -50 100% 8u Python
601                Pop $CHECKPY
602                GetFunctionAddress $0 OnClickPython
603                nsDialogs::OnClick /NOUNLOAD $CHECKPY $0
604            ${EndIf}
605    
606            ${If} $GTKOK == 'NOK'
607                ${NSD_CreateCheckbox} 0 -40 100% 8u GTK+
608                Pop $CHECKGTK
609                GetFunctionAddress $0 OnClickGTK
610                nsDialogs::OnClick /NOUNLOAD $CHECKGTK $0
611            ${EndIf}
612    
613            ${If} $PYGOBJECTOK == 'NOK'
614                ${NSD_CreateCheckbox} 0 -30 100% 8u PyGObject
615                Pop $CHECKPYGOBJECT
616                GetFunctionAddress $0 OnClickPyGObject
617                nsDialogs::OnClick /NOUNLOAD $CHECKPYGOBJECT $0
618            ${EndIf}
619    
620            ${If} $PYCAIROOK == 'NOK'
621                ${NSD_CreateCheckbox} 0 -20 100% 8u PyCairo
622                Pop $CHECKPYCAIRO
623                GetFunctionAddress $0 OnClickPyCairo
624                nsDialogs::OnClick /NOUNLOAD $CHECKPYCAIRO $0
625            ${EndIf}
626    
627            ${If} $PYGTKOK == 'NOK'
628                ${NSD_CreateCheckbox} 0 -10 100% 8u PyGTK
629                Pop $CHECKPYGTK
630                GetFunctionAddress $0 OnClickPyGTK
631                nsDialogs::OnClick /NOUNLOAD $CHECKPYGTK $0
632            ${EndIf}    
633    
634            nsDialogs::Show
635        ${EndIf}
636        
637    FunctionEnd
638    
639    Function OnClickPython
640        MessageBox MB_OK "python clicked"
641    FunctionEnd
642    
643    Function OnClickGTK
644        MessageBox MB_OK "GTK clicked"
645    FunctionEnd
646    
647    Function OnClickPyGTK
648        MessageBox MB_OK "PyGTK clicked"
649    FunctionEnd
650    
651    Function OnClickPyCairo
652        MessageBox MB_OK "PyCairo clicked"
653    FunctionEnd
654    
655    Function OnClickPyGObject
656        MessageBox MB_OK "PyGObject clicked"
657    FunctionEnd
658    
659    ;---------------------------------------------------------------------
660  ; UTILITY ROUTINES  ; UTILITY ROUTINES
661    
662  Function DetectPython  Function DetectPython

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

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