]> git.lyx.org Git - features.git/commitdiff
installer: get rid of all NSIS compiler warnings
authorUwe Stöhr <uwestoehr@web.de>
Wed, 2 May 2007 23:06:01 +0000 (23:06 +0000)
committerUwe Stöhr <uwestoehr@web.de>
Wed, 2 May 2007 23:06:01 +0000 (23:06 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18181 a592a061-630c-0410-9148-cb99ea01b6c8

development/Win32/packaging/installer/LyXWinInstaller/Aspell.nsh
development/Win32/packaging/installer/LyXWinInstaller/InstallActions-update.nsh
development/Win32/packaging/installer/LyXWinInstaller/LyXInstaller-complete.nsi
development/Win32/packaging/installer/LyXWinInstaller/LyXInstaller-small.nsi
development/Win32/packaging/installer/LyXWinInstaller/LyXInstaller-update.nsi
development/Win32/packaging/installer/LyXWinInstaller/LyXUtils.nsh
development/Win32/packaging/installer/LyXWinInstaller/Updated.nsh

index 4910a430ea88e6450eca6108c9267668f2b8e960..24acf69e80c7f204a7d98b9b0d271986e8a00ad4 100644 (file)
@@ -1,5 +1,7 @@
 # Aspell dictionaries
 
+!if ${INSTALLER_TYPE} == "NotUpdate" # only for Small and Complete installer
+
 Function DownloadDictionary
        
  FileOpen $R5 "$INSTDIR\Resources\AspellDictionaryNames.txt" r
@@ -66,8 +68,12 @@ Function DownloadDictionary
 
 FunctionEnd
 
+!endif # endif ${INSTALLER_TYPE} == "NotUpdate"
+
 #--------------------------------
 
+!if ${INSTALLER_TYPE} == "NotUpdate" # only for Small and Complete installer
+
 Function InstallAspellDictionary
        
  StrCpy $AspellInstallYes ""
@@ -207,6 +213,8 @@ Function InstallAspellDictionary
  DownloadLater:
         
 FunctionEnd
+
+!endif # endif ${INSTALLER_TYPE} == "NotUpdate"
  
 #---------------------------
 
index 0a2e345f2835ab62982f06e4397d8d910c844ae3..cddf0a8bd492ceeddd2e2a3797c0733123504354 100644 (file)
@@ -5,10 +5,13 @@ Section "-Installation actions" SecInstallation
 
   # dummy actions to avoid NSIS warnings
   StrCpy $AspellBaseReg ""
+  StrCpy $AspellMessage ""
+  StrCpy $DictCode ""
   StrCpy $LangCode ""
   StrCpy $LangCodeSys ""
   StrCpy $LangName ""
   StrCpy $LangNameSys ""
+  StrCpy $RunNumber ""
   
   # init, this variable is later only set to a value in function InstDirChange
   # when the $INSTDIR is changed
index d6cf333d6be66549f8f742d8a0505063a3310fc8..a646adfeb6d24361795df91d0485e2b3eb75b335 100644 (file)
@@ -27,6 +27,7 @@ CRCCheck force
 !define INSTALLER_VERSION "Complete"
 !define INSTALLER2_VERSION "Small"
 !define INSTALLER3_VERSION "Update"
+!define INSTALLER_TYPE "NotUpdate"
 
 # load the settings
 !include "Settings.nsh"
@@ -93,10 +94,6 @@ Var UserName
 !include "LogicLib.nsh"
 !include "FileFunc.nsh"
 !include "StrFunc.nsh"
-!include "TextFunc.nsh"
-!insertmacro LineFind
-!include "WordFunc.nsh"
-!insertmacro WordReplace
 
 # Set of various macros and functions
 !include "LyXUtils.nsh"
index 77ef2736d14a626e9b78bfe317f7790cf41b183c..ef05935d2c5a678cd7c042d6722e0dc63e0e2a09 100644 (file)
@@ -27,6 +27,7 @@ CRCCheck force
 !define INSTALLER_VERSION "Small"
 !define INSTALLER2_VERSION "Complete"
 !define INSTALLER3_VERSION "Update"
+!define INSTALLER_TYPE "NotUpdate"
 
 # load the settings
 !include "Settings.nsh"
@@ -91,10 +92,6 @@ Var UserName
 !include "LogicLib.nsh"
 !include "FileFunc.nsh"
 !include "StrFunc.nsh"
-!include "TextFunc.nsh"
-!insertmacro LineFind
-!include "WordFunc.nsh"
-!insertmacro WordReplace
 
 # Set of various macros and functions
 !include "LyXUtils.nsh"
index ee5e3f953a2aa8e1723f741a65a98d4e54ec9f40..5a18848ca0fdf5f54f5b6d7c954c3a4726db6c62 100644 (file)
@@ -27,6 +27,7 @@ SetCompressor lzma
 !define INSTALLER_VERSION "Update"
 !define INSTALLER2_VERSION "Small"
 !define INSTALLER3_VERSION "Complete"
+!define INSTALLER_TYPE "Update"
 
 # load the settings
 !include "Settings.nsh"
index e5df991c124242ddfa74e097ab1cc07144fd3eb2..bf0661696054971de5e399afd0c39f7d7adc0c63 100644 (file)
@@ -1,12 +1,14 @@
 # This script contains the following functions:
 #
-# - LaTeXCheck (check installed LaTeX-system), uses:
+# - LaTeXCheck (check installed LaTeX-system),
+#    (only used by Small and Complete installer), uses:
 #    StrPointer
 #    StrPoint
 #    RevStrPointer
 #    RevStrPoint
 #
-# - un.DelAppPathSub and UnAppPreSuff, (delete the folder ~\Documents and Settings\username\Application Data\LyX for all users), uses:
+# - un.DelAppPathSub and UnAppPreSuff,
+#    (delete the folder ~\Documents and Settings\username\Application Data\LyX for all users), uses:
 #    un.GetParentA
 #    un.GetUsers
 #    un.StrPoint
@@ -14,7 +16,9 @@
 #    StrPoint
 #    UnAppPreSuff
 #
-# - CreateAppPathSub and AppPreSuff, (creates the folder ~\Documents and Settings\username\Application Data\LyX for all users), uses:
+# - CreateAppPathSub and AppPreSuff,
+#    (creates the folder ~\Documents and Settings\username\Application Data\LyX for all users),
+#    (only used by Small and Complete installer), uses:
 #    GetParentA
 #    GetUsers
 #    StrPointer
@@ -97,9 +101,13 @@ FunctionEnd
  
 #--------------------------------
 
-Function RevStrPoint
- !insertmacro RevStrPointer $String $Search $Pointer
-FunctionEnd
+!if ${INSTALLER_TYPE} == "NotUpdate" # only for Small and Complete installer
+
+ Function RevStrPoint
+  !insertmacro RevStrPointer $String $Search $Pointer
+ FunctionEnd
+
+!endif # endif ${INSTALLER_TYPE} == "NotUpdate"
 
 #--------------------------------
 
@@ -311,7 +319,9 @@ FunctionEnd
 
 #--------------------------------
 
-Function CreateAppPathSub
+!if ${INSTALLER_TYPE} == "NotUpdate" # only for Small and Complete installer
+
+ Function CreateAppPathSub
  # creates a subfolder of the APPDATA path for all users
 
   # get folder names
@@ -352,21 +362,29 @@ Function CreateAppPathSub
   CopyFiles "$INSTDIR\Resources\session" "$AppPath"
   Delete "$INSTDIR\Resources\session" # delete the session file in the INSTDIR because it is unneeded there
   
-FunctionEnd
+ FunctionEnd
+
+!endif # endif ${INSTALLER_TYPE} == "NotUpdate"
 
 #--------------------------------
 
-Function ReplaceLineContent
+!if ${INSTALLER_TYPE} == "Update" # only for Update installer
+
+ Function ReplaceLineContent
  # replaces "$OldString" with "LyX $NewString"
 
- ${WordReplace} '$R9' "$OldString" "$NewString" "+" '$R9' # macro from WordFunc.nsh
- Push $0
 ${WordReplace} '$R9' "$OldString" "$NewString" "+" '$R9' # macro from WordFunc.nsh
 Push $0
  
-FunctionEnd
+ FunctionEnd
+
+!endif # endif ${INSTALLER_TYPE} == "Update"
 
 #--------------------------------
 
-Function CheckAppPathPreferences
+!if ${INSTALLER_TYPE} == "Update" # only for Update installer
+
+ Function CheckAppPathPreferences
  # replaces a string "$OldString" with "$NewString" in a file "$FileName"
 
   # get folder names
@@ -414,7 +432,9 @@ Function CheckAppPathPreferences
   ${LineFind} "$AppPath\$FileName" "" "1:-1" "ReplaceLineContent"
   doneB:
   
-FunctionEnd
+ FunctionEnd
+
+!endif # endif ${INSTALLER_TYPE} == "Update"
 
 #--------------------------------
 
@@ -464,7 +484,9 @@ FunctionEnd
 
 #------------------------------------------
 
-Function LaTeXCheck
+!if ${INSTALLER_TYPE} == "NotUpdate" # only for Small and Complete installer
+
+ Function LaTeXCheck
  # searches the string "$Search" in the string "$String" and extracts the path around it
  # the extracted path is checked if the file "latex.exe" is in it
 
@@ -504,5 +526,7 @@ Function LaTeXCheck
     Goto StartCheck
    ${endif}
 
-FunctionEnd
+ FunctionEnd
+
+!endif # endif ${INSTALLER_TYPE} == "NotUpdate"
 
index 804d274c00289529547d3dd8feb7760e1fe54d3a..a0a88268a77f562cb0e432cba7b8a4be3c667e6f 100644 (file)
@@ -14,6 +14,8 @@ Function UpdateModifiedFiles
  SetOutPath "$INSTDIR\Resources\doc\de"
  File "${PRODUCT_SOURCEDIR}\Resources\doc\de\TOC.lyx" # must be here when another \doc file has been changed
  File "${PRODUCT_SOURCEDIR}\Resources\doc\de\UserGuide.lyx"
+ SetOutPath "$INSTDIR\Resources\examples"
+ File "${PRODUCT_SOURCEDIR}\Resources\examples\armenian-article.lyx"
  SetOutPath "$INSTDIR\Resources\examples\de"
  File "${PRODUCT_SOURCEDIR}\Resources\examples\de\TabellenBeispiel.lyx"
  SetOutPath "$INSTDIR\Resources\layouts"