Author: jerome
Date: 2009-09-17 13:34:22 +0200 (Thu, 17 Sep 2009)
New Revision: 5432
Added:
software_suite_v3/software/tool/tool-second-installer/trunk/tool-second-installer/installer.nsi
Log:
* Added nsi script.
Added:
software_suite_v3/software/tool/tool-second-installer/trunk/tool-second-installer/installer.nsi
===================================================================
---
software_suite_v3/software/tool/tool-second-installer/trunk/tool-second-installer/installer.nsi
(rev 0)
+++
software_suite_v3/software/tool/tool-second-installer/trunk/tool-second-installer/installer.nsi
2009-09-17 11:34:22 UTC (rev 5432)
@@ -0,0 +1,96 @@
+; installer.nsi
+; This installer which install the Second installer
+; -----------------------------------------------------------------------------
+
+; HM NIS Edit Wizard helper defines
+!define PRODUCT_NAME "Second Installer"
+!define PRODUCT_VERSION "0.0.1-b0"
+
+; Output names
+!define FINAL_INSTALLER_EXE "QuickStartGuideInstaller_${PRODUCT_VERSION}.exe"
+!define UNINSTALLER_EXE "QuickStartGuideUninstaller.exe"
+
+; The name of the installer
+Name "${PRODUCT_NAME} ${PRODUCT_VERSION}"
+
+; The file to write
+OutFile "${FINAL_INSTALLER_EXE}"
+
+; The default installation directory
+InstallDir c:\tuxdroid\bin\tuxhttpserver
+
+; Request application privileges to user
+RequestExecutionLevel user
+
+; Get the Tuxdroid installation paths
+var /GLOBAL TUXDROID_PATH
+var /GLOBAL UNINSTALLERS_SUB_PATH
+
+; -----------------------------------------------------------------------------
+; Section Pre-installation
+; -----------------------------------------------------------------------------
+Section -Pre
+!ifndef INNER
+ ; Needed
+ SectionIn RO
+ ; Get the Tuxdroid installation path
+ ReadRegStr $TUXDROID_PATH HKLM "SOFTWARE\Tux Droid\Installation"
"Install_Dir"
+ ; Uninstall old installations of Second installer
+ DetailPrint "Uninstalling old versions"
+ SetDetailsPrint none
+ ExecWait '"$TUXDROID_PATH\uninstallers\sub\${UNINSTALLER_EXE}" /S
_?=$TUXDROID_PATH\uninstallers'
+ Sleep 3000
+ SetDetailsPrint textonly
+!endif
+SectionEnd
+
+; -----------------------------------------------------------------------------
+; Section ""
+; -----------------------------------------------------------------------------
+Section ""
+ ; Kill troublesome tasks
+ Processes::KillProcess "QuickStart.exe"
+
+ ; Get the Tuxdroid installation paths
+ ReadRegStr $TUXDROID_PATH HKLM "SOFTWARE\Tux Droid\Installation"
"Install_Dir"
+ StrCpy $UNINSTALLERS_SUB_PATH "$TUXDROID_PATH\uninstallers\sub"
+
+ ; Write the files
+ CreateDirectory "$TUXDROID_PATH\softwares\quick-start-guide"
+ SetOutPath "$TUXDROID_PATH\softwares\quick-start-guide"
+ File QuickStart.exe
+
+ CreateDirectory "$TUXDROID_PATH\softwares\quick-start-guide\locale"
+ SetOutPath "$TUXDROID_PATH\softwares\quick-start-guide\locale"
+ File /r /x *.pyc /x *.svn locale\*
+
+ CreateDirectory "$TUXDROID_PATH\softwares\quick-start-guide\images"
+ SetOutPath "$TUXDROID_PATH\softwares\quick-start-guide\images"
+ File /r /x *.pyc /x *.svn images\*
+
+ CreateDirectory "$TUXDROID_PATH\softwares\quick-start-guide\attitunes"
+ SetOutPath "$TUXDROID_PATH\softwares\quick-start-guide\attitunes"
+ File /r /x *.pyc /x *.svn attitunes\*
+
+ ; Write the uninstall file
+ WriteUninstaller "$UNINSTALLERS_SUB_PATH\${UNINSTALLER_EXE}"
+SectionEnd
+
+; -----------------------------------------------------------------------------
+; Section "Uninstall"
+; -----------------------------------------------------------------------------
+Section "Uninstall"
+ ; Kill troublesome tasks
+ Processes::KillProcess "QuickStart.exe"
+
+ ; Get the Tuxdroid installation paths
+ ReadRegStr $TUXDROID_PATH HKLM "SOFTWARE\Tux Droid\Installation"
"Install_Dir"
+ StrCpy $UNINSTALLERS_SUB_PATH "$TUXDROID_PATH\uninstallers\sub"
+
+ ; Remove files and uninstaller
+ RMDir /r "$TUXDROID_PATH\softwares\quick-start-guide"
+ Delete "$UNINSTALLERS_SUB_PATH\${UNINSTALLER_EXE}"
+
+ ; Quit the uninstaller
+ Quit
+SectionEnd
\ No newline at end of file
------------------------------------------------------------------------------
Come build with us! The BlackBerry® Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9-12, 2009. Register now!
http://p.sf.net/sfu/devconf
_______________________________________________
Tux-droid-svn mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tux-droid-svn