From: Bo Peng Date: Tue, 20 Mar 2007 04:10:23 +0000 (+0000) Subject: Read and add comments to installer files... X-Git-Tag: 1.6.10~10561 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=c3fbd9e0d137c5d18843400e0a1f3daff7955896;p=lyx.git Read and add comments to installer files... git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17488 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/development/Win32/packaging/installer/components/core.nsh b/development/Win32/packaging/installer/components/core.nsh index ffae1c0664..d190c156a2 100644 --- a/development/Win32/packaging/installer/components/core.nsh +++ b/development/Win32/packaging/installer/components/core.nsh @@ -10,17 +10,22 @@ Binaries, Resources, Python, Aspell Section -Core SecCore - #Install and register the core LyX files - + # Install and register the core LyX files + # Initializes the plug-ins dir ($PLUGINSDIR) if not already initialized. + # $PLUGINSDIR is automatically deleted when the installer exits. InitPluginsDir - #Binaries + # Binaries SetOutPath "$INSTDIR\bin" + # launcher becomes lyx.exe while the real lyx.exe is renamed to lyxc.exe File "${FILES_LAUNCHER}\lyx.exe" File /oname=lyxc.exe "${FILES_LYX}\bin\lyx.exe" + # The macros are defined in filelists.nsh + # the parameters are COMMAND DIRECTORY that form command '${COMMAND} "${DIRECTORY}files" +' !insertmacro FileListLyXBin File "${FILES_LYX}\bin\" !insertmacro FileListQtBin File "${FILES_QT}\bin\" @@ -34,16 +39,18 @@ Section -Core SecCore !insertmacro FileListPDFViewBin File "${FILES_PDFVIEW}\" !insertmacro FileListPDFToolsBin File "${FILES_PDFTOOLS}\" - #Icons + # Icons SetOutPath "$INSTDIR\bin" !insertmacro FileListLyXIcons File "${FILES_ICONS}\" - #Resources + # Resources SetOutPath "$INSTDIR" + # recursively copy all files under Resources File /r "${FILES_LYX}\Resources" SetOutPath "$INSTDIR\Resources\fonts" + # put additional fonts to Resources\fonts !insertmacro FileListFonts File "${FILES_FONTS}\" #Components of Python @@ -58,30 +65,33 @@ Section -Core SecCore SetOutPath "$INSTDIR\python\Lib\encodings" !insertmacro FileListPythonLibEncodings File "${FILES_PYTHON}\Lib\encodings\" - #Aspell + # Aspell + # copy installer to pluginsdir (a temp dir) File /oname=$PLUGINSDIR\AspellData.exe "${FILES_ASPELLDATA}\AspellData.exe" + # silently install AspellData.exe (/S option) ${if} $CurrentUserInstall == ${TRUE} ExecWait '"$PLUGINSDIR\AspellData.exe" /S /CurrentUser' ${else} ExecWait '"$PLUGINSDIR\AspellData.exe" /S /AllUsers' ${endif} + # remove the installer Delete "$PLUGINSDIR\AspellData.exe" - #Aiksarus data + # Aiksarus data SetOutPath "$INSTDIR\aiksaurus" !insertmacro FileListAiksaurusData File "${FILES_AIKSAURUS}\" - #Helper DLLs for NSIS-based tools + # Helper DLLs for NSIS-based tools SetOutPath "$INSTDIR\bin" !insertmacro FileListNSISPluginsStandard File "${NSISDIR}\Plugins\" !insertmacro FileListNSISPlugins File "${FILES_NSISPLUGINS}\" - #Create uninstaller + # Create uninstaller WriteUninstaller "$INSTDIR\${SETUP_UNINSTALLER}" SectionEnd diff --git a/development/Win32/packaging/installer/lyx.nsi b/development/Win32/packaging/installer/lyx.nsi index cf4103b406..5b8e3ba402 100644 --- a/development/Win32/packaging/installer/lyx.nsi +++ b/development/Win32/packaging/installer/lyx.nsi @@ -13,6 +13,10 @@ SetCompressor /SOLID lzma !include "include\declarations.nsh" +#-------------------------------- +# The following commands use makensis to compile two applications. +# Although these applications are written in NSIS, they do not install anything. + #-------------------------------- #Compile the launcher @@ -25,17 +29,24 @@ SetCompressor /SOLID lzma #-------------------------------- #LyX Installer, output file can be specified using command line option -# /DExeFile=/path/to/installer +# /DExeFile=/path/to/installer or /DBundleExeFile=/path/to/installer if +# SETUPTYPE_BUNDLE is defined. -!ifdef ExeFile +# bundle installer !ifdef SETUPTYPE_BUNDLE +!ifdef BundleExeFile OutFile "${BundleExeFile}" !else -OutFile "${ExeFile}" +Outfile "${SETUP_EXE}" !endif +# regular installer +!else +!ifdef ExeFile +OutFile "${ExeFile}" !else Outfile "${SETUP_EXE}" !endif +!endif #-------------------------------- #Components