summaryrefslogtreecommitdiff
path: root/packaging/windows
diff options
context:
space:
mode:
authorBjørn Lindeijer <bjorn@lindeijer.nl>2008-12-27 00:15:18 +0100
committerBjørn Lindeijer <bjorn@lindeijer.nl>2008-12-27 00:15:18 +0100
commit4accc40d8aceef2e802e2ec4b7b7c96bfb36c519 (patch)
treea80b6e65795d472f80530c8098ecc17367319955 /packaging/windows
parentc900cc8eb35335b31e678f7ecdb0e4e527f0174a (diff)
downloadmana-client-4accc40d8aceef2e802e2ec4b7b7c96bfb36c519.tar.gz
mana-client-4accc40d8aceef2e802e2ec4b7b7c96bfb36c519.tar.bz2
mana-client-4accc40d8aceef2e802e2ec4b7b7c96bfb36c519.tar.xz
mana-client-4accc40d8aceef2e802e2ec4b7b7c96bfb36c519.zip
Adapted setup.nsi to 0.0.27 and added instructions
readme.txt explains a bit about how to build the Windows installer.
Diffstat (limited to 'packaging/windows')
-rw-r--r--packaging/windows/readme.txt15
-rw-r--r--packaging/windows/setup.nsi58
2 files changed, 39 insertions, 34 deletions
diff --git a/packaging/windows/readme.txt b/packaging/windows/readme.txt
new file mode 100644
index 00000000..03a5717e
--- /dev/null
+++ b/packaging/windows/readme.txt
@@ -0,0 +1,15 @@
+HOW TO BUILD THE INSTALLER
+
+First time setup
+
+* Install NSIS (http://nsis.sourceforge.net)
+* Install UPX (http://upx.sourceforge.net/)
+ (the script expects upx to be in a "upx" subdirectory right here)
+
+Building the installer
+
+* Make sure TMW is compiled at the right version
+* Make sure the correct DLLs are in place
+* Make sure the latest music files are in place
+* Make sure setup.nsi mentions the right TMW version
+* Right-click setup.nsi and select "Compile NSIS Script"
diff --git a/packaging/windows/setup.nsi b/packaging/windows/setup.nsi
index f6dfa798..d1645882 100644
--- a/packaging/windows/setup.nsi
+++ b/packaging/windows/setup.nsi
@@ -2,12 +2,14 @@ CRCCheck on
SetCompress off
SetCompressor /SOLID lzma
+!define TMWROOT "..\.."
+
;--- (and without !defines ) ---
-!System "%ProgramFiles%\upx\upx.exe --best --crp-ms=999999 --compress-icons=0 --nrv2d tmw.exe"
+!System "upx\upx.exe --best --crp-ms=999999 --compress-icons=0 --nrv2d ${TMWROOT}\tmw.exe"
; HM NIS Edit helper defines
!define PRODUCT_NAME "The Mana World"
-!define PRODUCT_VERSION "0.0.26"
+!define PRODUCT_VERSION "0.0.27"
!define PRODUCT_PUBLISHER "The Mana World Development Team"
!define PRODUCT_WEB_SITE "http://themanaworld.org"
!define PRODUCT_DIR_REGKEY "Software\Microsoft\Windows\CurrentVersion\App Paths\tmw.exe"
@@ -20,9 +22,9 @@ SetCompressor /SOLID lzma
; MUI Settings
!define MUI_ABORTWARNING
;!define MUI_ICON "${NSISDIR}\Contrib\Graphics\Icons\win-install.ico"
-!define MUI_ICON "data\icons\tmw.ico"
+!define MUI_ICON "${TMWROOT}\data\icons\tmw.ico"
;!define MUI_UNICON "${NSISDIR}\Contrib\Graphics\Icons\win-uninstall.ico"
-!define MUI_UNICON "data\icons\tmw.ico"
+!define MUI_UNICON "${TMWROOT}\data\icons\tmw.ico"
;Language Selection Dialog Settings
;Remember the installer language
@@ -38,7 +40,7 @@ SetCompressor /SOLID lzma
!define MUI_WELCOMEPAGE_TITLE_3LINES
!insertmacro MUI_PAGE_WELCOME
; License page
-!insertmacro MUI_PAGE_LICENSE "COPYING"
+!insertmacro MUI_PAGE_LICENSE "${TMWROOT}\COPYING"
; Directory page
!insertmacro MUI_PAGE_DIRECTORY
; Instfiles page
@@ -47,7 +49,7 @@ SetCompressor /SOLID lzma
!define MUI_FINISHPAGE_RUN
!define MUI_FINISHPAGE_RUN_FUNCTION RunTMW
!define MUI_FINISHPAGE_SHOWREADME 'notepad.exe "$\"$INSTDIR\README$\""'
-!define MUI_PAGE_CUSTOMFUNCTION_PRE changeFinishBmp
+!define MUI_PAGE_CUSTOMFUNCTION_PRE changeFinishImage
!define MUI_FINISHPAGE_LINK "Visit TMW website for the latest news, FAQs and support"
!define MUI_FINISHPAGE_LINK_LOCATION "http://themanaworld.org"
!insertmacro MUI_PAGE_FINISH
@@ -57,7 +59,7 @@ SetOutPath $INSTDIR
Exec "$INSTDIR\tmw.exe"
FunctionEnd
-Function changeFinishBmp
+Function changeFinishImage
!insertmacro MUI_INSTALLOPTIONS_WRITE "ioSpecial.ini" "Field 1" "Text" "$PLUGINSDIR\setup_finish.bmp"
FunctionEnd
@@ -149,44 +151,32 @@ Section "Core files (required)" SecCore
CreateDirectory "$INSTDIR\data\graphics"
CreateDirectory "$INSTDIR\data\help"
CreateDirectory "$INSTDIR\data\icons"
- CreateDirectory "$INSTDIR\data\maps"
CreateDirectory "$INSTDIR\data\music"
- CreateDirectory "$INSTDIR\data\sfx"
CreateDirectory "$INSTDIR\data\graphics\gui"
CreateDirectory "$INSTDIR\data\graphics\images"
- CreateDirectory "$INSTDIR\data\graphics\items"
- CreateDirectory "$INSTDIR\data\graphics\tiles"
- CreateDirectory "$INSTDIR\data\graphics\images\ambient"
CreateDirectory "$INSTDIR\docs"
SetOverwrite ifnewer
SetOutPath "$INSTDIR"
-
- File "tmw.exe"
- File "*.dll"
- File "AUTHORS"
- File "ChangeLog"
- File "COPYING"
- File "NEWS"
- File "README"
+
+ File "${TMWROOT}\tmw.exe"
+ File "${TMWROOT}\*.dll"
+ File "${TMWROOT}\AUTHORS"
+ File "${TMWROOT}\COPYING"
+ File "${TMWROOT}\NEWS"
+ File "${TMWROOT}\README"
SetOutPath "$INSTDIR\data\graphics\gui"
- File "data\graphics\gui\*.png"
- SetOutPath "$INSTDIR\data\graphics\images\ambient"
- File /nonfatal "data\graphics\images\ambient\*.png"
+ File "${TMWROOT}\data\graphics\gui\*.png"
SetOutPath "$INSTDIR\data\graphics\images"
- File /x minimap_*.png data\graphics\images\*.png
- SetOutPath "$INSTDIR\data\graphics\sprites"
- File /nonfatal /x monster-*.png data\graphics\sprites\*.png
- SetOutPath "$INSTDIR\data\graphics\tiles"
- File /nonfatal "data\graphics\tiles\*.png"
+ File /x minimap_*.png ${TMWROOT}\data\graphics\images\*.png
SetOutPath "$INSTDIR\data\help"
- File "data\help\*.txt"
+ File "${TMWROOT}\data\help\*.txt"
SetOutPath "$INSTDIR\data\icons\"
- File "data\icons\tmw.ico"
+ File "${TMWROOT}\data\icons\tmw.ico"
SetOutPath "$INSTDIR\data\music"
- File /nonfatal "data\music\*.ogg"
+ File /nonfatal "${TMWROOT}\data\music\*.ogg"
SetOutPath "$INSTDIR\docs"
- File "docs\FAQ.txt"
+ File "${TMWROOT}\docs\FAQ.txt"
SectionEnd
Section -AdditionalIcons
@@ -225,7 +215,7 @@ Section Uninstall
Delete "$SMPROGRAMS\The Mana World\FAQ.lnk"
RMDir "$SMPROGRAMS\The Mana World"
-
+
RMDir /r "$INSTDIR\data"
RMDir /r "$INSTDIR\docs"
RMDir /r "$INSTDIR\updates"
@@ -234,4 +224,4 @@ Section Uninstall
DeleteRegKey ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}"
DeleteRegKey HKLM "${PRODUCT_DIR_REGKEY}"
SetAutoClose true
-SectionEnd \ No newline at end of file
+SectionEnd