Change windows installer comments from ; to #

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17366 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Bo Peng 2007-02-26 16:03:30 +00:00
parent dca251a0ef
commit adc618f6e7
30 changed files with 781 additions and 781 deletions

View File

@ -1,4 +1,4 @@
; Aspell dictionaries
# Aspell dictionaries
Function DownloadDictionary
@ -18,8 +18,8 @@ Function DownloadDictionary
StrCpy $String $String -2 ; delete the linebreak characters at the end
; Download aspell dictionaries,
; if first download repository is not available try the other ones listed in "AspellRepositories.txt"
# Download aspell dictionaries,
# if first download repository is not available try the other ones listed in "AspellRepositories.txt"
FileOpen $R5 "$INSTDIR\Resources\AspellRepositories.txt" r
${For} $4 1 4
FileRead $R5 $Search ; $Search is now the AspellLocation
@ -27,8 +27,8 @@ Function DownloadDictionary
Push $R0
InetLoad::load /TIMEOUT=5000 "$Search/aspell6-$String.exe" "$INSTDIR\aspell6-$String.exe" /END
Pop $R0
; test if the downloaded file is really the expected one, because if the file didn't exist on the download server,
; berlios.de downloads a text file with the name of the non-existing file that contains the line "File doesn't exist"
# test if the downloaded file is really the expected one, because if the file didn't exist on the download server,
# berlios.de downloads a text file with the name of the non-existing file that contains the line "File doesn't exist"
FileOpen $R4 "$INSTDIR\aspell6-$String.exe" r
FileRead $R4 $Search
FileClose $R4
@ -42,14 +42,14 @@ Function DownloadDictionary
${Next}
FileClose $R5
; Download failed
# Download failed
${if} $R0 != "OK"
MessageBox MB_OK|MB_ICONEXCLAMATION "$(AspellDownloadFailed) $R0"
StrCpy $AspellInstallYes "$RunNumber$AspellInstallYes"
Goto abortinstall
${endif}
; Download successful
# Download successful
ExecWait '"$INSTDIR\aspell6-$String.exe" /NoDirChange /AutoClose'
${if} $AspellBaseReg == "HKLM"
ReadRegStr $R2 HKLM "Software\Aspell\Dictionaries" $DictCode
@ -66,13 +66,13 @@ Function DownloadDictionary
FunctionEnd
;--------------------------------
#--------------------------------
Function InstallAspellDictionary
StrCpy $AspellInstallYes ""
; install the english dictionary if not already installed
# install the english dictionary if not already installed
StrCpy $DictCode "en"
StrCpy $RunNumber "1"
${if} $AspellBaseReg == "HKLM" ; $AspellBaseReg is either "HKLM" or if Aspell is already installed only for the current user "HKCU"
@ -88,9 +88,9 @@ Function InstallAspellDictionary
StrCpy $AspellInstallYes "$RunNumber$AspellInstallYes"
${endif}
; install the dictionary corresponding to the system and the chosen menu language
; check if the system language and the chosen menu language are the same, if not install
; both dictionaries
# install the dictionary corresponding to the system and the chosen menu language
# check if the system language and the chosen menu language are the same, if not install
# both dictionaries
StrCpy $DictCode $LangCode 2
StrCpy $0 $DictCode ; $0 is now the language code of the chosen LyX menu language
StrCpy $RunNumber "2"
@ -136,7 +136,7 @@ Function InstallAspellDictionary
StrCpy $AspellInstallYes "4$AspellInstallYes"
${endif}
; check the registry to divide between nothing installed or all already installed
# check the registry to divide between nothing installed or all already installed
${if} $AspellInstallYes == "321"
${orif} $AspellInstallYes == "421"
${if} $AspellBaseReg == "HKLM"
@ -167,12 +167,12 @@ Function InstallAspellDictionary
Delete "$INSTDIR\Resources\AspellDictionaryNames.txt"
Delete "$INSTDIR\Resources\AspellRepositories.txt"
; show message about Aspell dictionaries
; the code rule to display the correct message:
; - when the englisch dictionary is already installed or couldn't be installed -> set a "1"
; - when the dictionary of the chosen LyX menu language is already installed or couldn't be installed -> set a "2"
; - when the dictionary of the Windows system language is already installed or couldn't be installed -> set a "3"
; - when the dictionary of the chosen LyX menu language is equal to the dictionary of the Windows system language -> set a "4"
# show message about Aspell dictionaries
# the code rule to display the correct message:
# - when the englisch dictionary is already installed or couldn't be installed -> set a "1"
# - when the dictionary of the chosen LyX menu language is already installed or couldn't be installed -> set a "2"
# - when the dictionary of the Windows system language is already installed or couldn't be installed -> set a "3"
# - when the dictionary of the chosen LyX menu language is equal to the dictionary of the Windows system language -> set a "4"
${if} $AspellInstallYes == "32"
${orif} $AspellInstallYes == "42"
MessageBox MB_ICONINFORMATION|MB_DEFBUTTON2|MB_YESNO "$(AspellPartStart)$(AspellPart1)$(AspellPart4)" IDYES DownloadNow IDNO DownloadLater
@ -208,14 +208,14 @@ Function InstallAspellDictionary
FunctionEnd
;---------------------------
#---------------------------
Function un.UninstAspell
ReadRegStr $1 HKLM "Software\Aspell" "Base Path"
; delete Aspells' install folder
# delete Aspells' install folder
RMDir /r $1
; unregister Aspell and its dictionaries
# unregister Aspell and its dictionaries
DeleteRegKey HKLM "Software\Aspell"
DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Aspell"
DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Aspell6-Dictionary-af"

View File

@ -1,20 +1,20 @@
; The '-' makes the section invisible.
; Sections are entered in order, so the settings above are all
; available to SecInstallation
# The '-' makes the section invisible.
# Sections are entered in order, so the settings above are all
# available to SecInstallation
Section "-Installation actions" SecInstallation
; extract all files
# extract all files
SetOutPath "$INSTDIR"
File /r "${PRODUCT_SOURCEDIR}\bin"
File /r "${PRODUCT_SOURCEDIR}\etc"
File /r "${PRODUCT_SOURCEDIR}\Resources"
File /r "${PRODUCT_SOURCEDIR}\external"
; install MiKTeX if not already installed
# install MiKTeX if not already installed
${if} $LatexPath == ""
; launch MiKTeX's installer
# launch MiKTeX's installer
MessageBox MB_OK|MB_ICONINFORMATION "$(LatexInfo)"
ExecWait ${MiKTeXInstall}
; test if MiKTeX is installed
# test if MiKTeX is installed
ReadRegStr $String HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "Path"
StrCpy $Search "miktex"
Call LaTeXCheck
@ -25,12 +25,12 @@ Section "-Installation actions" SecInstallation
Call LaTeXCheck
${endif}
${if} $LatexPath != ""
; set package repository (MiKTeX's primary package repository)
# set package repository (MiKTeX's primary package repository)
WriteRegStr HKLM "SOFTWARE\MiKTeX.org\MiKTeX" "OnlyWithLyX" "Yes" ; special entry to tell the uninstaller that it was installed with LyX
StrCpy $MiKTeXInstalled "yes"
${if} $MiKTeXUser != "HKCU"
StrCpy $MiKTeXPath "$LatexPath" -11
;MessageBox MB_OK|MB_ICONINFORMATION "$(MiKTeXPathInfo)" ; info that MiKTeX's installation folder must have write permissions for all users to work properly
#MessageBox MB_OK|MB_ICONINFORMATION "$(MiKTeXPathInfo)" ; info that MiKTeX's installation folder must have write permissions for all users to work properly
${endif}
${else}
MessageBox MB_OK|MB_ICONSTOP "$(LatexError1)"
@ -41,19 +41,19 @@ Section "-Installation actions" SecInstallation
${endif}
${if} $GhostscriptPath == ""
; register Ghostscript
# register Ghostscript
WriteRegStr HKLM "SOFTWARE\GPL Ghostscript\${GhostscriptVersion}" "GS_DLL" "${GhostscriptDir}\bin\gsdll32.dll"
WriteRegStr HKLM "SOFTWARE\GPL Ghostscript\${GhostscriptVersion}" "GS_LIB" "${GhostscriptDir}\lib;${GhostscriptDir}\fonts;${GhostscriptDir}\Resource"
WriteRegStr HKLM "SOFTWARE\GPL Ghostscript" "OnlyWithLyX" "Yes" ; special entry to tell the uninstaller that it was installed with LyX
StrCpy $GhostscriptPath "${GhostscriptDir}\bin"
${else}
; delete unnecessary files
# delete unnecessary files
RMDir /r ${GhostscriptDir}
${endif}
${if} $ImageMagickPath == ""
; register ImageMagick
# register ImageMagick
WriteRegStr HKLM "SOFTWARE\Classes\Applications" "AutoRun" "${ImageMagickDir}\convert.exe $$"
WriteRegStr HKLM "SOFTWARE\ImageMagick\${ImageMagickVersion}\Q:16" "BinPath" "${ImageMagickDir}"
WriteRegStr HKLM "SOFTWARE\ImageMagick\${ImageMagickVersion}\Q:16" "CoderModulesPath" "${ImageMagickDir}\modules\coders"
@ -72,15 +72,15 @@ Section "-Installation actions" SecInstallation
WriteRegStr HKLM "Software\ImageMagick" "OnlyWithLyX" "Yes" ; special entry to tell the uninstaller that it was installed with LyX
StrCpy $ImageMagickPath ${ImageMagickDir}
${else}
; delete unnecessary files
# delete unnecessary files
RMDir /r ${ImageMagickDir}
${endif}
${if} $AspellPath == ""
; extract Aspell's program files
# extract Aspell's program files
SetOutPath "$INSTDIR\external"
File /r "${PRODUCT_SOURCEDIR}\${AspellInstall}"
; copy the files and register Aspell
# copy the files and register Aspell
CopyFiles "$INSTDIR\${AspellInstall}" "$APPDATA"
WriteRegStr HKLM "SOFTWARE\Aspell" "Base Path" "${AspellDir}"
@ -96,21 +96,21 @@ Section "-Installation actions" SecInstallation
${endif}
${if} $AiksaurusPath == ""
; extract Aiksaurus' program files
# extract Aiksaurus' program files
SetOutPath "$INSTDIR\external"
File /r "${PRODUCT_SOURCEDIR}\${AiksaurusInstall}"
; copy the files and register Aiksaurus
# copy the files and register Aiksaurus
CopyFiles "$INSTDIR\${AiksaurusInstall}" "$APPDATA"
; WriteRegStr HKLM "Software\Aiksaurus" "OnlyWithLyX" "Yes" ; special entry to tell the uninstaller that it was installed with LyX
; WriteRegStr HKLM "Software\Aiksaurus" "Data Path" "${AiksaurusDir}"
# WriteRegStr HKLM "Software\Aiksaurus" "OnlyWithLyX" "Yes" ; special entry to tell the uninstaller that it was installed with LyX
# WriteRegStr HKLM "Software\Aiksaurus" "Data Path" "${AiksaurusDir}"
${endif}
${if} $PSVPath == ""
${if} $InstallGSview == "true"
; launch installer
# launch installer
MessageBox MB_OK|MB_ICONINFORMATION "$(GSviewInfo)"
ExecWait "$INSTDIR\${GSviewInstall}"
; test if GSview is installed
# test if GSview is installed
StrCpy $PSVPath ""
ReadRegStr $PSVPath HKLM "Software\Microsoft\Windows\CurrentVersion\App Paths\gsview32.exe" "Path"
${if} $PSVPath == ""
@ -121,10 +121,10 @@ Section "-Installation actions" SecInstallation
${if} $BibTeXEditorPath == ""
${if} $InstallJabRef == "true"
; launch installer
# launch installer
MessageBox MB_OK|MB_ICONINFORMATION "$(JabRefInfo)"
ExecWait "$INSTDIR\${JabRefInstall}"
; test if JabRef is installed
# test if JabRef is installed
StrCpy $BibTeXEditorPath ""
ReadRegStr $BibTeXEditorPath HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${JabRefVersion}" "UninstallString"
${if} $BibTeXEditorPath == ""
@ -135,7 +135,7 @@ Section "-Installation actions" SecInstallation
${endif}
${endif}
; create the PathPrefix
# create the PathPrefix
StrCpy $PathPrefix "$INSTDIR\bin"
${if} $PythonPath != ""
StrCpy $PathPrefix "$PathPrefix;$PythonPath"
@ -159,8 +159,8 @@ Section "-Installation actions" SecInstallation
StrCpy $PathPrefix "$PathPrefix;$ImageEditorPath"
${endif}
; install the LaTeX class files that are delivered with LyX
; and enable MiKTeX's automatic package installation
# install the LaTeX class files that are delivered with LyX
# and enable MiKTeX's automatic package installation
StrCpy $String $LatexPath
StrCpy $Search "miktex\bin"
StrLen $3 $String
@ -168,7 +168,7 @@ Section "-Installation actions" SecInstallation
${if} $Pointer != "-1" ; if something was found
IntOp $Pointer $Pointer - 1 ; jump before the first "\" of "\miktex\bin"
StrCpy $String $String "$Pointer" ; $String is now the part before "\miktex\bin"
; install LaTeX class files
# install LaTeX class files
SetOutPath "$String\tex\latex"
File "${ClassFileDir}\cv.cls"
CreateDirectory "$String\tex\latex\lyx"
@ -184,52 +184,52 @@ Section "-Installation actions" SecInstallation
CreateDirectory "$String\tex\latex\broadway"
SetOutPath "$String\tex\latex\broadway"
File "${ClassFileDir}\broadway.cls"
; install LaTeX-package dvipost (dvipost is not available for MiKTeX)
# install LaTeX-package dvipost (dvipost is not available for MiKTeX)
SetOutPath "$String\tex\latex\"
File /r "${DVIPostFileDir}"
${if} $MiKTeXVersion == "2.4"
; refresh MiKTeX's file name database
# refresh MiKTeX's file name database
ExecWait "$String\miktex\bin\initexmf --update-fndb"
; delete MiKTeX 2.4's dvipng executable as it is an old broken version. Then install a working one.
# delete MiKTeX 2.4's dvipng executable as it is an old broken version. Then install a working one.
Delete "$String\miktex\bin\dvipng.exe"
; Install a new one
# Install a new one
SetOutPath "$String\miktex\bin"
File "${PRODUCT_DIR}\LyX\external\dvipng.exe"
; enable package installation without asking (1=Yes, 0=No, 2=Always Ask Before Installing)
# enable package installation without asking (1=Yes, 0=No, 2=Always Ask Before Installing)
WriteRegStr HKCU "SOFTWARE\MiK\MiKTeX\CurrentVersion\MiKTeX" "InstallPackagesOnTheFly" "1"
WriteRegStr HKCU "SOFTWARE\MiK\MiKTeX\CurrentVersion\MPM\Settings" "" ""
; Setting package repository (MiKTeX's primary package repository)
# Setting package repository (MiKTeX's primary package repository)
WriteRegStr HKCU "SOFTWARE\MiK\MiKTeX\CurrentVersion\MPM" "RemotePackageRepository" "${MiKTeXRepo}"
${else} ; if MiKTeX 2.5
; refresh MiKTeX's file name database
# refresh MiKTeX's file name database
ExecWait "$LaTeXPath\initexmf --update-fndb"
; enable package installation without asking (t = Yes, f = No)
# enable package installation without asking (t = Yes, f = No)
WriteRegStr HKCU "SOFTWARE\MiKTeX.org\MiKTeX\2.5\MPM" "AutoInstall" "1" ; if only for curent user
WriteRegStr HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "MIKTEX_AUTOINSTALL" "t"
; set package repository (MiKTeX's primary package repository)
# set package repository (MiKTeX's primary package repository)
WriteRegStr HKCU "SOFTWARE\MiKTeX.org\MiKTeX\2.5\MPM" "RemoteRepository" "${MiKTeXRepo}" ; if only for curent user
WriteRegStr HKCU "SOFTWARE\MiKTeX.org\MiKTeX\2.5\MPM" "RepositoryType" "remote" ; if only for curent user
WriteRegStr HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "MIKTEX_REPOSITORY" "${MiKTeXRepo}"
${endif}
; enable MiKTeX's automatic package installation
# enable MiKTeX's automatic package installation
ExecWait '$LaTeXPath\mpm.com --update-fndb'
; the following feature is planned to be used for a possible CD-version
; ; copy LaTeX-packages needed by LyX
; SetOutPath "$INSTDIR"
; File /r "${LaTeXPackagesDir}"
# the following feature is planned to be used for a possible CD-version
# ; copy LaTeX-packages needed by LyX
# SetOutPath "$INSTDIR"
# File /r "${LaTeXPackagesDir}"
${endif} ; end ${if} $Pointer
; install Aspell dictionaries
# install Aspell dictionaries
${if} $LangCode == "nb_NO"
StrCpy $LangCode "no_NO" ; we only have a norwegian dictionary available
${endif}
Call InstallAspellDictionary ; function from aspell.nsh
; configure LyX
; Set a path prefix in lyxrc.dist
# configure LyX
# Set a path prefix in lyxrc.dist
ClearErrors
${if} "$PathPrefix" != ""
Delete "$INSTDIR\Resources\lyxrc.dist"
@ -240,7 +240,7 @@ Section "-Installation actions" SecInstallation
MessageBox MB_OK|MB_ICONEXCLAMATION "$(ModifyingConfigureFailed)"
${endif}
; Create a batch file to start LyX with the environment variables set
# Create a batch file to start LyX with the environment variables set
ClearErrors
Delete "${PRODUCT_BAT}"
FileOpen $R1 "${PRODUCT_BAT}" w
@ -252,17 +252,17 @@ Section "-Installation actions" SecInstallation
IfErrors 0 +2
MessageBox MB_OK|MB_ICONEXCLAMATION "$(CreateCmdFilesFailed)"
; set the preferences file
; having one preferences file that is modified to fit the needs isn't possible because the command
; ${LineFind} "$INSTDIR\Resources\preferences" "" "-16:-11" "DeleteLines" ; macro from TextFunc.nsh
; removes the file permissions for Users, so that it can later not be read (bug in ${LineFind} of TextFunc.nsh)
; if not Acrobat or Adobe Reader is used
# set the preferences file
# having one preferences file that is modified to fit the needs isn't possible because the command
# ${LineFind} "$INSTDIR\Resources\preferences" "" "-16:-11" "DeleteLines" ; macro from TextFunc.nsh
# removes the file permissions for Users, so that it can later not be read (bug in ${LineFind} of TextFunc.nsh)
# if not Acrobat or Adobe Reader is used
${if} $Acrobat == "None" ; clear the entries in the preferences file that define PDFViewWin7 or 8 as viewer
Rename "$INSTDIR\Resources\preferencesGSview" "$INSTDIR\Resources\preferences"
Delete "$INSTDIR\Resources\preferences7"
Delete "$INSTDIR\Resources\preferences8"
${endif}
; if Acrobat or Adobe Reader is used
# if Acrobat or Adobe Reader is used
${if} $Acrobat == "7" ; clear the entries in the preferences file that define PDFViewWin8 as viewer
Rename "$INSTDIR\Resources\preferences7" "$INSTDIR\Resources\preferences"
Delete "$INSTDIR\Resources\preferences8"
@ -274,7 +274,7 @@ Section "-Installation actions" SecInstallation
Delete "$INSTDIR\Resources\preferencesGSview"
${endif}
; register LyX
# register LyX
WriteRegStr HKLM "${PRODUCT_DIR_REGKEY}" "" "${PRODUCT_EXE}"
WriteRegStr ${PRODUCT_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "RootKey" "$ProductRootKey"
WriteRegStr ${PRODUCT_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayName" "${PRODUCT_NAME} ${PRODUCT_VERSION}"
@ -300,18 +300,18 @@ Section "-Installation actions" SecInstallation
CreateShortCut "$DESKTOP\${PRODUCT_NAME}.lnk" "${PRODUCT_BAT}" "" "${PRODUCT_EXE}"
${endif}
; register the extension .lyx
# register the extension .lyx
${if} $CreateFileAssociations == "true"
${CreateApplicationAssociation} "${PRODUCT_NAME}" "${PRODUCT_NAME}" "$(FileTypeTitle)" "${PRODUCT_EXE}" "${PRODUCT_BAT}"
${CreateFileAssociation} "${PRODUCT_EXT}" "${PRODUCT_NAME}" "${PRODUCT_MIME_TYPE}"
${endif}
; create the LyX Application Data folder for all users
; this folder is automatically created by LyX when it is first started but we want to start LyX with a specific session file,
; so we create this folder before LyX starts and copy there the session file
# create the LyX Application Data folder for all users
# this folder is automatically created by LyX when it is first started but we want to start LyX with a specific session file,
# so we create this folder before LyX starts and copy there the session file
Call CreateAppPathSub ; function from LyXUtils.nsh
; delete unnecessary files
# delete unnecessary files
${if} $DelPythonFiles == "True"
Delete $INSTDIR\bin\python.exe
Delete $INSTDIR\bin\python25.dll
@ -321,16 +321,16 @@ Section "-Installation actions" SecInstallation
${endif}
RMDir /r $INSTDIR\external
; create Uninstaller
# create Uninstaller
WriteUninstaller "${PRODUCT_UNINSTALL_EXE}"
; run LyX's configure script
; create a bat-file to start configure in a console window so that the user see the progress
; of the configuration and to have a signal when the configuration is ready to start LyX
; this is important when LyX is installed together with MiKTeX or when LyX is installed for the first
; time on a computer, because the installation of missing LaTeX-files required by LyX could last minutes
; a batch file is needed because simply calling ExecWait '"$INSTDIR\bin\python.exe" "$INSTDIR\Resources\configure.py"'
; creates the config files in $INSTDIR\bin
# run LyX's configure script
# create a bat-file to start configure in a console window so that the user see the progress
# of the configuration and to have a signal when the configuration is ready to start LyX
# this is important when LyX is installed together with MiKTeX or when LyX is installed for the first
# time on a computer, because the installation of missing LaTeX-files required by LyX could last minutes
# a batch file is needed because simply calling ExecWait '"$INSTDIR\bin\python.exe" "$INSTDIR\Resources\configure.py"'
# creates the config files in $INSTDIR\bin
StrCpy $1 $INSTDIR 2 ; get drive letter
FileOpen $R1 "$INSTDIR\Resources\configLyX.bat" w
FileWrite $R1 'cd $INSTDIR\Resources\$\r$\n\
@ -341,7 +341,7 @@ Section "-Installation actions" SecInstallation
ExecWait '"$INSTDIR\Resources\configLyX.bat"'
Delete "$INSTDIR\Resources\configLyX.bat"
; ask to update MiKTeX
# ask to update MiKTeX
${if} $MiKTeXInstalled == "yes"
MessageBox MB_YESNO|MB_ICONINFORMATION "$(MiKTeXInfo)" IDYES UpdateNow IDNO UpdateLater
UpdateNow:
@ -350,7 +350,7 @@ Section "-Installation actions" SecInstallation
UpdateLater:
${endif}
; save MiKTeX's install path to be able to remove LyX's LaTeX-files in the uninstaller
# save MiKTeX's install path to be able to remove LyX's LaTeX-files in the uninstaller
FileOpen $R1 "$INSTDIR\Resources\uninstallPaths.dat" w
FileWrite $R1 '$LaTeXPath'
FileClose $R1

View File

@ -1,27 +1,27 @@
; The '-' makes the section invisible.
; Sections are entered in order, so the settings above are all
; available to SecInstallation
# The '-' makes the section invisible.
# Sections are entered in order, so the settings above are all
# available to SecInstallation
Section "-Installation actions" SecInstallation
; extract all files
# extract all files
SetOutPath "$INSTDIR"
File /r "${PRODUCT_SOURCEDIR}\bin"
File /r "${PRODUCT_SOURCEDIR}\etc"
File /r "${PRODUCT_SOURCEDIR}\Resources"
${if} $GhostscriptPath == ""
; register Ghostscript
# register Ghostscript
WriteRegStr HKLM "SOFTWARE\GPL Ghostscript\${GhostscriptVersion}" "GS_DLL" "${GhostscriptDir}\bin\gsdll32.dll"
WriteRegStr HKLM "SOFTWARE\GPL Ghostscript\${GhostscriptVersion}" "GS_LIB" "${GhostscriptDir}\lib;${GhostscriptDir}\fonts;${GhostscriptDir}\Resource"
WriteRegStr HKLM "SOFTWARE\GPL Ghostscript" "OnlyWithLyX" "Yes" ; special entry to tell the uninstaller that it was installed with LyX
StrCpy $GhostscriptPath "${GhostscriptDir}\bin"
${else}
; delete unnecessary files
# delete unnecessary files
RMDir /r ${GhostscriptDir}
${endif}
${if} $ImageMagickPath == ""
; register ImageMagick
# register ImageMagick
WriteRegStr HKLM "SOFTWARE\Classes\Applications" "AutoRun" "${ImageMagickDir}\convert.exe $$"
WriteRegStr HKLM "SOFTWARE\ImageMagick\${ImageMagickVersion}\Q:16" "BinPath" "${ImageMagickDir}"
WriteRegStr HKLM "SOFTWARE\ImageMagick\${ImageMagickVersion}\Q:16" "CoderModulesPath" "${ImageMagickDir}\modules\coders"
@ -40,15 +40,15 @@ Section "-Installation actions" SecInstallation
WriteRegStr HKLM "Software\ImageMagick" "OnlyWithLyX" "Yes" ; special entry to tell the uninstaller that it was installed with LyX
StrCpy $ImageMagickPath ${ImageMagickDir}
${else}
; delete unnecessary files
# delete unnecessary files
RMDir /r ${ImageMagickDir}
${endif}
${if} $AspellPath == ""
; extract Aspell's program files
# extract Aspell's program files
SetOutPath "$INSTDIR\external"
File /r "${PRODUCT_SOURCEDIR}\${AspellInstall}"
; copy the files and register Aspell
# copy the files and register Aspell
CopyFiles "$INSTDIR\${AspellInstall}" "$APPDATA"
WriteRegStr HKLM "SOFTWARE\Aspell" "Base Path" "${AspellDir}"
@ -64,16 +64,16 @@ Section "-Installation actions" SecInstallation
${endif}
${if} $AiksaurusPath == ""
; extract Aiksaurus' program files
# extract Aiksaurus' program files
SetOutPath "$INSTDIR\external"
File /r "${PRODUCT_SOURCEDIR}\${AiksaurusInstall}"
; copy the files and register Aiksaurus
# copy the files and register Aiksaurus
CopyFiles "$INSTDIR\${AiksaurusInstall}" "$APPDATA"
; WriteRegStr HKLM "Software\Aiksaurus" "OnlyWithLyX" "Yes" ; special entry to tell the uninstaller that it was installed with LyX
; WriteRegStr HKLM "Software\Aiksaurus" "Data Path" "${AiksaurusDir}"
# WriteRegStr HKLM "Software\Aiksaurus" "OnlyWithLyX" "Yes" ; special entry to tell the uninstaller that it was installed with LyX
# WriteRegStr HKLM "Software\Aiksaurus" "Data Path" "${AiksaurusDir}"
${endif}
; create the PathPrefix
# create the PathPrefix
StrCpy $PathPrefix "$INSTDIR\bin"
${if} $PythonPath != ""
StrCpy $PathPrefix "$PathPrefix;$PythonPath"
@ -97,8 +97,8 @@ Section "-Installation actions" SecInstallation
StrCpy $PathPrefix "$PathPrefix;$ImageEditorPath"
${endif}
; install the LaTeX class files that are delivered with LyX
; and enable MiKTeX's automatic package installation
# install the LaTeX class files that are delivered with LyX
# and enable MiKTeX's automatic package installation
StrCpy $String $LatexPath
StrCpy $Search "miktex\bin"
StrLen $3 $String
@ -106,7 +106,7 @@ Section "-Installation actions" SecInstallation
${if} $Pointer != "-1" ; if something was found
IntOp $Pointer $Pointer - 1 ; jump before the first "\" of "\miktex\bin"
StrCpy $String $String "$Pointer" ; $String is now the part before "\miktex\bin"
; install LaTeX class files
# install LaTeX class files
SetOutPath "$String\tex\latex"
File "${ClassFileDir}\cv.cls"
CreateDirectory "$String\tex\latex\lyx"
@ -122,48 +122,48 @@ Section "-Installation actions" SecInstallation
CreateDirectory "$String\tex\latex\broadway"
SetOutPath "$String\tex\latex\broadway"
File "${ClassFileDir}\broadway.cls"
; install LaTeX-package dvipost (dvipost is not available for MiKTeX)
# install LaTeX-package dvipost (dvipost is not available for MiKTeX)
SetOutPath "$String\tex\latex\"
File /r "${DVIPostFileDir}"
${if} $MiKTeXVersion == "2.4"
; refresh MiKTeX's file name database
# refresh MiKTeX's file name database
ExecWait "$String\miktex\bin\initexmf --update-fndb"
; delete MiKTeX 2.4's dvipng executable as it is an old broken version. Then install a working one.
# delete MiKTeX 2.4's dvipng executable as it is an old broken version. Then install a working one.
Delete "$String\miktex\bin\dvipng.exe"
; Install a new one
# Install a new one
SetOutPath "$String\miktex\bin"
File "${PRODUCT_DIR}\LyX\external\dvipng.exe"
; enable package installation without asking (1=Yes, 0=No, 2=Always Ask Before Installing)
# enable package installation without asking (1=Yes, 0=No, 2=Always Ask Before Installing)
WriteRegStr HKCU "SOFTWARE\MiK\MiKTeX\CurrentVersion\MiKTeX" "InstallPackagesOnTheFly" "1"
WriteRegStr HKCU "SOFTWARE\MiK\MiKTeX\CurrentVersion\MPM\Settings" "" ""
; Setting package repository (MiKTeX's primary package repository)
# Setting package repository (MiKTeX's primary package repository)
WriteRegStr HKCU "SOFTWARE\MiK\MiKTeX\CurrentVersion\MPM" "RemotePackageRepository" "${MiKTeXRepo}"
${else} ; if MiKTeX 2.5
; refresh MiKTeX's file name database
# refresh MiKTeX's file name database
ExecWait "$LaTeXPath\initexmf --update-fndb"
; enable package installation without asking (t = Yes, f = No)
# enable package installation without asking (t = Yes, f = No)
WriteRegStr HKCU "SOFTWARE\MiKTeX.org\MiKTeX\2.5\MPM" "AutoInstall" "1" ; if only for curent user
WriteRegStr HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "MIKTEX_AUTOINSTALL" "t"
; set package repository (MiKTeX's primary package repository)
# set package repository (MiKTeX's primary package repository)
WriteRegStr HKCU "SOFTWARE\MiKTeX.org\MiKTeX\2.5\MPM" "RemoteRepository" "${MiKTeXRepo}" ; if only for curent user
WriteRegStr HKCU "SOFTWARE\MiKTeX.org\MiKTeX\2.5\MPM" "RepositoryType" "remote" ; if only for curent user
WriteRegStr HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "MIKTEX_REPOSITORY" "${MiKTeXRepo}"
${endif}
; enable MiKTeX's automatic package installation
# enable MiKTeX's automatic package installation
ExecWait '$LaTeXPath\mpm.com --update-fndb'
${endif} ; end ${if} $Pointer
; install Aspell dictionaries
# install Aspell dictionaries
${if} $LangCode == "nb_NO"
StrCpy $LangCode "no_NO" ; we only have a norwegian dictionary available
${endif}
Call InstallAspellDictionary ; function from aspell.nsh
; configure LyX
; Set a path prefix in lyxrc.dist
# configure LyX
# Set a path prefix in lyxrc.dist
ClearErrors
${if} "$PathPrefix" != ""
Delete "$INSTDIR\Resources\lyxrc.dist"
@ -174,7 +174,7 @@ Section "-Installation actions" SecInstallation
MessageBox MB_OK|MB_ICONEXCLAMATION "$(ModifyingConfigureFailed)"
${endif}
; Create a batch file to start LyX with the environment variables set
# Create a batch file to start LyX with the environment variables set
ClearErrors
Delete "${PRODUCT_BAT}"
FileOpen $R1 "${PRODUCT_BAT}" w
@ -186,17 +186,17 @@ Section "-Installation actions" SecInstallation
IfErrors 0 +2
MessageBox MB_OK|MB_ICONEXCLAMATION "$(CreateCmdFilesFailed)"
; set the preferences file
; having one preferences file that is modified to fit the needs isn't possible because the command
; ${LineFind} "$INSTDIR\Resources\preferences" "" "-16:-11" "DeleteLines" ; macro from TextFunc.nsh
; removes the file permissions for Users, so that it can later not be read (bug in ${LineFind} of TextFunc.nsh)
; if not Acrobat or Adobe Reader is used
# set the preferences file
# having one preferences file that is modified to fit the needs isn't possible because the command
# ${LineFind} "$INSTDIR\Resources\preferences" "" "-16:-11" "DeleteLines" ; macro from TextFunc.nsh
# removes the file permissions for Users, so that it can later not be read (bug in ${LineFind} of TextFunc.nsh)
# if not Acrobat or Adobe Reader is used
${if} $Acrobat == "None" ; clear the entries in the preferences file that define PDFViewWin7 or 8 as viewer
Rename "$INSTDIR\Resources\preferencesGSview" "$INSTDIR\Resources\preferences"
Delete "$INSTDIR\Resources\preferences7"
Delete "$INSTDIR\Resources\preferences8"
${endif}
; if Acrobat or Adobe Reader is used
# if Acrobat or Adobe Reader is used
${if} $Acrobat == "7" ; clear the entries in the preferences file that define PDFViewWin8 as viewer
Rename "$INSTDIR\Resources\preferences7" "$INSTDIR\Resources\preferences"
Delete "$INSTDIR\Resources\preferences8"
@ -208,7 +208,7 @@ Section "-Installation actions" SecInstallation
Delete "$INSTDIR\Resources\preferencesGSview"
${endif}
; register LyX
# register LyX
WriteRegStr HKLM "${PRODUCT_DIR_REGKEY}" "" "${PRODUCT_EXE}"
WriteRegStr ${PRODUCT_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "RootKey" "$ProductRootKey"
WriteRegStr ${PRODUCT_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayName" "${PRODUCT_NAME} ${PRODUCT_VERSION}"
@ -234,18 +234,18 @@ Section "-Installation actions" SecInstallation
CreateShortCut "$DESKTOP\${PRODUCT_NAME}.lnk" "${PRODUCT_BAT}" "" "${PRODUCT_EXE}"
${endif}
; register the extension .lyx
# register the extension .lyx
${if} $CreateFileAssociations == "true"
${CreateApplicationAssociation} "${PRODUCT_NAME}" "${PRODUCT_NAME}" "$(FileTypeTitle)" "${PRODUCT_EXE}" "${PRODUCT_BAT}"
${CreateFileAssociation} "${PRODUCT_EXT}" "${PRODUCT_NAME}" "${PRODUCT_MIME_TYPE}"
${endif}
; create the LyX Application Data folder for all users
; this folder is automatically created by LyX when it is first started but we want to start LyX with a specific session file,
; so we create this folder before LyX starts and copy there the session file
# create the LyX Application Data folder for all users
# this folder is automatically created by LyX when it is first started but we want to start LyX with a specific session file,
# so we create this folder before LyX starts and copy there the session file
Call CreateAppPathSub ; function from LyXUtils.nsh
; delete unnecessary files
# delete unnecessary files
${if} $DelPythonFiles == "True"
Delete $INSTDIR\bin\python.exe
Delete $INSTDIR\bin\python25.dll
@ -255,16 +255,16 @@ Section "-Installation actions" SecInstallation
${endif}
RMDir /r $INSTDIR\external
; create Uninstaller
# create Uninstaller
WriteUninstaller "${PRODUCT_UNINSTALL_EXE}"
; run LyX's configure script
; create a bat-file to start configure in a console window so that the user see the progress
; of the configuration and to have a signal when the configuration is ready to start LyX
; this is important when LyX is installed together with MiKTeX or when LyX is installed for the first
; time on a computer, because the installation of missing LaTeX-files required by LyX could last minutes
; a batch file is needed because simply calling ExecWait '"$INSTDIR\bin\python.exe" "$INSTDIR\Resources\configure.py"'
; creates the config files in $INSTDIR\bin
# run LyX's configure script
# create a bat-file to start configure in a console window so that the user see the progress
# of the configuration and to have a signal when the configuration is ready to start LyX
# this is important when LyX is installed together with MiKTeX or when LyX is installed for the first
# time on a computer, because the installation of missing LaTeX-files required by LyX could last minutes
# a batch file is needed because simply calling ExecWait '"$INSTDIR\bin\python.exe" "$INSTDIR\Resources\configure.py"'
# creates the config files in $INSTDIR\bin
StrCpy $1 $INSTDIR 2 ; get drive letter
FileOpen $R1 "$INSTDIR\Resources\configLyX.bat" w
FileWrite $R1 'cd $INSTDIR\Resources\$\r$\n\
@ -275,7 +275,7 @@ Section "-Installation actions" SecInstallation
ExecWait '"$INSTDIR\Resources\configLyX.bat"'
Delete "$INSTDIR\Resources\configLyX.bat"
; ask to update MiKTeX
# ask to update MiKTeX
${if} $MiKTeXInstalled == "yes"
MessageBox MB_YESNO|MB_ICONINFORMATION "$(MiKTeXInfo)" IDYES UpdateNow IDNO UpdateLater
UpdateNow:
@ -284,7 +284,7 @@ Section "-Installation actions" SecInstallation
UpdateLater:
${endif}
; save MiKTeX's install path to be able to remove LyX's LaTeX-files in the uninstaller
# save MiKTeX's install path to be able to remove LyX's LaTeX-files in the uninstaller
FileOpen $R1 "$INSTDIR\Resources\uninstallPaths.dat" w
FileWrite $R1 '$LaTeXPath'
FileClose $R1

View File

@ -1,7 +1,7 @@
Function LatexFolder
!insertmacro MUI_INSTALLOPTIONS_EXTRACT "io_latex.ini"
; generate the installer page
# generate the installer page
!insertmacro MUI_HEADER_TEXT "$(EnterLaTeXHeader1)" "$(EnterLaTeXHeader2)"
${if} $LatexName != ""
!insertmacro MUI_INSTALLOPTIONS_WRITE "io_latex.ini" "Field 1" "Text" "$(EnterLaTeXFolder)"
@ -24,7 +24,7 @@ Function LatexFolder
Goto ReadyFolder
${endif}
!insertmacro MUI_INSTALLOPTIONS_READ "$LatexPath" "io_latex.ini" "Field 3" "State"
; check if the latex.exe exists in the $LatexPath folder
# check if the latex.exe exists in the $LatexPath folder
!insertmacro FileCheck $5 "latex.exe" "$LatexPath"
${if} $5 == "False"
MessageBox MB_RETRYCANCEL "$(InvalidLaTeXFolder)" IDRETRY AgainFolder

View File

@ -1,10 +1,10 @@
; Language settings for the installer
; create language code for the Windows system language
# Language settings for the installer
# create language code for the Windows system language
; LangNme is the language name when there exists a LyX translation for this language; used for the menu language dialog and for the Aspell installation
; LangNmeSys is the Windows system language; used for the Aspell installation
; LangCdeSys is the ISO 630 language code of the language; used for the Aspell installation
; LangSysEnc is the Windows codepage for the character encoding of the language; used in lyx.bat to assure that scripts are correctly executed
# LangNme is the language name when there exists a LyX translation for this language; used for the menu language dialog and for the Aspell installation
# LangNmeSys is the Windows system language; used for the Aspell installation
# LangCdeSys is the ISO 630 language code of the language; used for the Aspell installation
# LangSysEnc is the Windows codepage for the character encoding of the language; used in lyx.bat to assure that scripts are correctly executed
!macro TranslateLangCode LangNme LangNmeSys LangCdeSys LangISOCode LangSysEnc
StrCpy ${LangCdeSys} ""
@ -27,11 +27,11 @@
StrCpy ${LangSysEnc} "1252"
${endif}
; currently no dictionary available
; ${if} ${LangISOCode} = 1028
; StrCpy ${LangCdeSys} "zh"
; StrCpy ${LangNmeSys} "Chinese"
; ${endif}
# currently no dictionary available
# ${if} ${LangISOCode} = 1028
# StrCpy ${LangCdeSys} "zh"
# StrCpy ${LangNmeSys} "Chinese"
# ${endif}
${if} ${LangISOCode} = 1029
StrCpy ${LangNme} "Ceština"
@ -114,17 +114,17 @@
StrCpy ${LangSysEnc} "1252"
${endif}
; currently no dictionary available
; ${if} ${LangISOCode} = 1041
; StrCpy ${LangCdeSys} "ja"
; StrCpy ${LangNmeSys} "Japanese"
; ${endif}
# currently no dictionary available
# ${if} ${LangISOCode} = 1041
# StrCpy ${LangCdeSys} "ja"
# StrCpy ${LangNmeSys} "Japanese"
# ${endif}
; currently no dictionary available
; ${if} ${LangISOCode} = 1042
; StrCpy ${LangCdeSys} "ko"
; StrCpy ${LangNmeSys} "Korean"
; ${endif}
# currently no dictionary available
# ${if} ${LangISOCode} = 1042
# StrCpy ${LangCdeSys} "ko"
# StrCpy ${LangNmeSys} "Korean"
# ${endif}
${if} ${LangISOCode} = 1043
StrCpy ${LangNme} "Nederlands"
@ -181,12 +181,12 @@
StrCpy ${LangSysEnc} "1250"
${endif}
; currently no dictionary available
; ${if} ${LangISOCode} = 1052
; StrCpy ${LangCdeSys} "sq"
; StrCpy ${LangNmeSys} "Shqip"
; StrCpy ${LangSysEnc} "1252"
; ${endif}
# currently no dictionary available
# ${if} ${LangISOCode} = 1052
# StrCpy ${LangCdeSys} "sq"
# StrCpy ${LangNmeSys} "Shqip"
# StrCpy ${LangSysEnc} "1252"
# ${endif}
${if} ${LangISOCode} = 1053
StrCpy ${LangNme} "Svenska"
@ -195,12 +195,12 @@
StrCpy ${LangSysEnc} "1252"
${endif}
; currently no dictionary available
; ${if} ${LangISOCode} = 1054
; StrCpy ${LangCdeSys} "th"
; StrCpy ${LangNmeSys} "Thai"
; StrCpy ${LangSysEnc} "874"
; ${endif}
# currently no dictionary available
# ${if} ${LangISOCode} = 1054
# StrCpy ${LangCdeSys} "th"
# StrCpy ${LangNmeSys} "Thai"
# StrCpy ${LangSysEnc} "874"
# ${endif}
${if} ${LangISOCode} = 1055
StrCpy ${LangNme} "Türkçe"
@ -240,7 +240,7 @@
StrCpy ${LangSysEnc} "1257"
${endif}
; currently no dictionary available
# currently no dictionary available
${if} ${LangISOCode} = 1069
StrCpy ${LangNme} "Euskara"
StrCpy ${LangCdeSys} "eu"
@ -254,11 +254,11 @@
StrCpy ${LangSysEnc} "1252"
${endif}
; currently no dictionary available
; ${if} ${LangISOCode} = 1081
; StrCpy ${LangCdeSys} "hi"
; StrCpy ${LangNmeSys} "Hindi"
; ${endif}
# currently no dictionary available
# ${if} ${LangISOCode} = 1081
# StrCpy ${LangCdeSys} "hi"
# StrCpy ${LangNmeSys} "Hindi"
# ${endif}
${if} ${LangISOCode} = 1110
StrCpy ${LangNme} "Galego"
@ -267,11 +267,11 @@
StrCpy ${LangSysEnc} "1252"
${endif}
; currently no dictionary available
; ${if} ${LangISOCode} = 2052
; StrCpy ${LangCdeSys} "zh"
; StrCpy ${LangNmeSys} "Chinese"
; ${endif}
# currently no dictionary available
# ${if} ${LangISOCode} = 2052
# StrCpy ${LangCdeSys} "zh"
# StrCpy ${LangNmeSys} "Chinese"
# ${endif}
${if} ${LangISOCode} = 2055
StrCpy ${LangCdeSys} "de"
@ -421,9 +421,9 @@
!macroend
;------------------------------------------
#------------------------------------------
; Setting LyX's menu language
# Setting LyX's menu language
!macro GetLangCode LangCde Name LangEnc
@ -529,13 +529,13 @@
!macroend
;--------------------
#--------------------
Function SelectMenuLanguage
!insertmacro MUI_INSTALLOPTIONS_EXTRACT "io_ui_language.ini"
${if} $LangName == ""
; translate NSIS's language code to the language name; macro from lyx_utils.nsh
# translate NSIS's language code to the language name; macro from lyx_utils.nsh
!insertmacro TranslateLangCode $LangName $LangNameSys $LangCodeSys $Language $LangSysEncoding
${endif}
@ -555,7 +555,7 @@ FunctionEnd
Function SelectMenuLanguage_LeaveFunction
!insertmacro MUI_INSTALLOPTIONS_READ $LangName "io_ui_language.ini" "Field 2" "State"
; Get the language code; macro from lyx_utils.nsh
# Get the language code; macro from lyx_utils.nsh
StrCpy $LangCode ""
!insertmacro GetLangCode $LangCode $LangName $LangEncoding

View File

@ -1,28 +1,28 @@
; Lyx for Windows, NSIS v2 series installer script
# Lyx for Windows, NSIS v2 series installer script
; File LyXWinInstaller.nsi
; This file is part of LyX, the document processor.
; http://www.lyx.org/
; Licence details can be found in the file COPYING or copy at
; http://www.lyx.org/about/license.php3
# File LyXWinInstaller.nsi
# This file is part of LyX, the document processor.
# http://www.lyx.org/
# Licence details can be found in the file COPYING or copy at
# http://www.lyx.org/about/license.php3
; Author Uwe Stöhr based on the work of Angus Leeming and Joost Verburg
; Full author contact details are available in file CREDITS or copy at
; http://www.lyx.org/about/credits.php
# Author Uwe Stöhr based on the work of Angus Leeming and Joost Verburg
# Full author contact details are available in file CREDITS or copy at
# http://www.lyx.org/about/credits.php
; This script requires NSIS 2.22 and newer
; http://nsis.sourceforge.net/
;--------------------------------
# This script requires NSIS 2.22 and newer
# http://nsis.sourceforge.net/
#--------------------------------
; Do a Cyclic Redundancy Check to make sure the installer
; was not corrupted by the download.
# Do a Cyclic Redundancy Check to make sure the installer
# was not corrupted by the download.
CRCCheck force
; Make the installer as small as possible.
; SetCompressor lzma
# Make the installer as small as possible.
# SetCompressor lzma
;--------------------------------
; You should need to change only these macros...
#--------------------------------
# You should need to change only these macros...
!define PRODUCT_DIR "D:\LyXPackage1.5"
!define PRODUCT_NAME "LyX"
@ -46,7 +46,7 @@ BrandingText "LyXWinInstaller v3.09 - Complete"
!define INSTALLER2_EXE "LyXWin150beta1Small-3-09.exe" ; to check later if this installer version is running at the same time
!define VERSION_BITMAP "${PRODUCT_DIR}\icons\lyx_logo_vert${PRODUCT_VERSION_SHORT}.bmp"
; Replaced by HKLM or HKCU depending on SetShellVarContext.
# Replaced by HKLM or HKCU depending on SetShellVarContext.
!define PRODUCT_ROOT_KEY "SHCTX"
!define PRODUCT_DIR_REGKEY "Software\Microsoft\Windows\CurrentVersion\App Paths\lyx.exe"
@ -72,22 +72,22 @@ BrandingText "LyXWinInstaller v3.09 - Complete"
!define JabRefInstall "external\JabRef-2.2-Setup.exe"
!define JabRefVersion "JabRef 2.2"
!define DVIPostFileDir "${PRODUCT_SOURCEDIR}\external\dvipost"
; the following variable is needed for a possible CD-version, see InstallActions.nsh, around line 213
;!define LaTeXPackagesDir "${PRODUCT_SOURCEDIR}\latex"
# the following variable is needed for a possible CD-version, see InstallActions.nsh, around line 213
#!define LaTeXPackagesDir "${PRODUCT_SOURCEDIR}\latex"
!define MiKTeXRepo "ftp://ftp.tu-chemnitz.de/pub/tex/systems/win32/miktex/tm/packages/"
!define MiKTeXConfigFolder "MiKTeX\2.5\miktex\config"
!define MiKTeXDeliveredVersion "MiKTeX 2.5"
!define MiKTeXInstall "$INSTDIR\external\basic-miktex-2.5.2580.exe"
;--------------------------------
; Make some of the information above available to NSIS.
#--------------------------------
# Make some of the information above available to NSIS.
Name "${PRODUCT_NAME}"
OutFile "${INSTALLER_EXE}"
InstallDir "$PROGRAMFILES\${PRODUCT_NAME} ${PRODUCT_VERSION}"
;--------------------------------
; Variables
#--------------------------------
# Variables
Var LatexPath
Var PythonPath
@ -136,36 +136,36 @@ Var Pointer
Var UserList
Var RunNumber
;--------------------------------
; load some NSIS libraries
#--------------------------------
# load some NSIS libraries
!include "MUI.nsh"
!include "LogicLib.nsh"
!include "FileFunc.nsh"
!include "StrFunc.nsh"
;!include "TextFunc.nsh"
;!insertmacro LineFind
#!include "TextFunc.nsh"
#!insertmacro LineFind
; Set of various macros and functions
# Set of various macros and functions
!include "LyXUtils.nsh"
; Function to check if needed programs are missing or not
# Function to check if needed programs are missing or not
!include "MissingPrograms.nsh"
; Functions for page to set installer language
; and LyX's menu language
# Functions for page to set installer language
# and LyX's menu language
!include "LanguageSettings.nsh"
; Function for page to install Aspell dictionaries
# Function for page to install Aspell dictionaries
!include "Aspell.nsh"
; Use the Abiword macros to help set up associations with the file extension in the Registry.
; Grabbed from
; http://abiword.pchasm.org/source/cvs/abiword-cvs/abi/src/pkg/win/setup/NSISv2/abi_util_fileassoc.nsh
# Use the Abiword macros to help set up associations with the file extension in the Registry.
# Grabbed from
# http://abiword.pchasm.org/source/cvs/abiword-cvs/abi/src/pkg/win/setup/NSISv2/abi_util_fileassoc.nsh
!include "abi_util_fileassoc.nsh"
;--------------------------------
#--------------------------------
; Remember the installer language
# Remember the installer language
!define MUI_LANGDLL_REGISTRY_ROOT "HKCU"
!define MUI_LANGDLL_REGISTRY_KEY "${PRODUCT_UNINST_KEY}"
!define MUI_LANGDLL_REGISTRY_VALUENAME "Installer Language"
@ -177,48 +177,48 @@ Var RunNumber
!define MUI_UNICON "${PRODUCT_DIR}\icons\lyx.ico"
!define MUI_WELCOMEFINISHPAGE_BITMAP "${VERSION_BITMAP}"
; Welcome page
# Welcome page
!define MUI_WELCOMEPAGE_TEXT "$(WelcomePageText)"
!insertmacro MUI_PAGE_WELCOME
; Show the license.
# Show the license.
!insertmacro MUI_PAGE_LICENSE "${PRODUCT_LICENSE_FILE}"
; Specify the installation directory.
# Specify the installation directory.
!insertmacro MUI_PAGE_DIRECTORY
; Specify LyX's menu language.
# Specify LyX's menu language.
Page custom SelectMenuLanguage SelectMenuLanguage_LeaveFunction
; Define which components to install.
# Define which components to install.
!insertmacro MUI_PAGE_COMPONENTS
; Specify where to install program shortcuts.
# Specify where to install program shortcuts.
!define MUI_STARTMENUPAGE_REGISTRY_ROOT "${PRODUCT_ROOT_KEY}"
!define MUI_STARTMENUPAGE_REGISTRY_KEY "${PRODUCT_UNINST_KEY}"
!define MUI_STARTMENUPAGE_REGISTRY_VALUENAME "Start Menu Folder"
!define MUI_STARTMENUPAGE_DEFAULTFOLDER "LyX ${PRODUCT_VERSION}"
!insertmacro MUI_PAGE_STARTMENU ${PRODUCT_NAME} $StartmenuFolder
; Check for needed programs
# Check for needed programs
Page custom MissingProgramsPage MissingProgramsPage_LeaveFunction
; Watch the components being installed.
# Watch the components being installed.
!insertmacro MUI_PAGE_INSTFILES
; Finish page
# Finish page
!define MUI_FINISHPAGE_RUN
!define MUI_FINISHPAGE_TEXT "$(FinishPageMessage)"
!define MUI_FINISHPAGE_RUN_TEXT "$(FinishPageRun)"
!define MUI_FINISHPAGE_RUN_FUNCTION "LaunchProduct"
!insertmacro MUI_PAGE_FINISH
; The uninstaller.
# The uninstaller.
!insertmacro MUI_UNPAGE_COMPONENTS
!insertmacro MUI_UNPAGE_INSTFILES
;--------------------------------
; Languages
#--------------------------------
# Languages
!insertmacro MUI_LANGUAGE "English" # first language is the default language
!insertmacro MUI_LANGUAGE "Danish"
@ -254,16 +254,16 @@ Page custom MissingProgramsPage MissingProgramsPage_LeaveFunction
LicenseData "$(LyXLicenseData)"
;--------------------------------
; Reserve Files
#--------------------------------
# Reserve Files
; These files are inserted before other files in the data block
# These files are inserted before other files in the data block
!insertmacro MUI_RESERVEFILE_LANGDLL
ReserveFile "io_ui_language.ini"
!insertmacro MUI_RESERVEFILE_INSTALLOPTIONS
;--------------------------------
; Installer sections
#--------------------------------
# Installer sections
Section "!${PRODUCT_NAME}" SecCore
SectionIn RO
@ -287,7 +287,7 @@ Section /o "$(SecInstJabRefTitle)" SecInstJabRef
StrCpy $InstallJabRef "true"
SectionEnd
; Section descriptions
# Section descriptions
!insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
!insertmacro MUI_DESCRIPTION_TEXT ${SecCore} "$(SecCoreDescription)"
!insertmacro MUI_DESCRIPTION_TEXT ${SecAllUsers} "$(SecAllUsersDescription)"
@ -299,14 +299,14 @@ SectionEnd
!include "InstallActions-complete.nsh"
;--------------------------------
; This hook function is called internally by NSIS on installer startup
#--------------------------------
# This hook function is called internally by NSIS on installer startup
Function .onInit
; set the installer language to the Windows locale language
# set the installer language to the Windows locale language
System::Call "kernel32::GetUserDefaultLangID()i.a"
; Check that the installer is not currently running
# Check that the installer is not currently running
System::Call 'kernel32::CreateMutexA(i 0, i 0, t "${INSTALLER_EXE}.Instance") i .r1 ?e'
Pop $R0
${if} $R0 != "0"
@ -319,23 +319,23 @@ Function .onInit
Abort
${endif}
; Check if LyX is already installed
# Check if LyX is already installed
ReadRegStr $0 HKLM "${PRODUCT_UNINST_KEY}" "Publisher"
${if} $0 != ""
MessageBox MB_OK|MB_ICONSTOP "$(StillInstalled)"
Abort
${endif}
; Default settings
; These can be reset to "all" in section SecAllUsers.
# Default settings
# These can be reset to "all" in section SecAllUsers.
SetShellVarContext current
StrCpy $ProductRootKey "HKCU"
; This can be reset to "true" in section SecDesktop.
# This can be reset to "true" in section SecDesktop.
StrCpy $CreateDesktopIcon "false"
StrCpy $CreateFileAssociations "false"
; If the user does *not* have administrator privileges, abort
# If the user does *not* have administrator privileges, abort
StrCpy $Answer ""
StrCpy $UserName ""
!insertmacro IsUserAdmin $Answer $UserName ; macro from LyXUtils.nsh
@ -350,10 +350,10 @@ Function .onInit
Abort
${endif}
; check which programs are installed or not
# check which programs are installed or not
Call MissingPrograms ; function from MissingPrograms.nsh
; don't let the installer sections appear when the programs are already installed
# don't let the installer sections appear when the programs are already installed
${if} $PSVPath != ""
SectionSetText 4 "" ; hides the corresponding uninstaller section, ${SecInstGSview}
${endif}
@ -364,32 +364,32 @@ Function .onInit
ClearErrors
FunctionEnd
;--------------------------------
#--------------------------------
Function LaunchProduct
Exec ${PRODUCT_BAT}
FunctionEnd
;--------------------------------
#--------------------------------
;Function DeleteLines
; StrCpy $0 SkipWrite
; Push $0
;FunctionEnd
#Function DeleteLines
# StrCpy $0 SkipWrite
# Push $0
#FunctionEnd
;--------------------------------
; The Uninstaller
#--------------------------------
# The Uninstaller
Function un.onInit
; Check that LyX is not currently running
# Check that LyX is not currently running
FindProcDLL::FindProc "lyx.exe"
${if} $R0 == "1"
MessageBox MB_OK|MB_ICONSTOP "$(UnInstallRunning)"
Abort
${endif}
; Ascertain whether the user has sufficient privileges to uninstall.
# Ascertain whether the user has sufficient privileges to uninstall.
SetShellVarContext current
ReadRegStr $0 HKCU "${PRODUCT_UNINST_KEY}" "RootKey"
@ -400,7 +400,7 @@ Function un.onInit
${endif}
${endif}
; If the user does *not* have administrator privileges, abort
# If the user does *not* have administrator privileges, abort
StrCpy $Answer ""
!insertmacro IsUserAdmin $Answer $UserName ; macro from LyXUtils.nsh
${if} $Answer == "yes"
@ -410,10 +410,10 @@ Function un.onInit
Abort
${endif}
; Macro to investigate name of LyX's preferences folders to be able remove them
# Macro to investigate name of LyX's preferences folders to be able remove them
!insertmacro UnAppPreSuff $AppPre $AppSuff ; macro from LyXUtils.nsh
; test if Aspell was installed together with LyX
# test if Aspell was installed together with LyX
ReadRegStr $0 HKLM "Software\Aspell" "OnlyWithLyX" ; special entry to test if it was installed with LyX
${if} $0 == "Yes"
SectionSetText 2 "Aspell" ; names the corersponding uninstaller section (has the index "2" as it is the third section in Uninstall.nsh)
@ -422,7 +422,7 @@ Function un.onInit
SectionSetText 2 "" ; hides the corresponding uninstaller section
${endif}
; test if MiKTeX was installed together with LyX
# test if MiKTeX was installed together with LyX
ReadRegStr $0 HKLM "SOFTWARE\MiKTeX.org\MiKTeX" "OnlyWithLyX"
${if} $0 == "Yes"
SectionSetText 3 "MiKTeX" ; names the corersponding uninstaller section
@ -431,7 +431,7 @@ Function un.onInit
SectionSetText 3 "" ; hides the corresponding uninstaller section
${endif}
; test if JabRef was installed together with LyX
# test if JabRef was installed together with LyX
ReadRegStr $0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${JabRefVersion}" "OnlyWithLyX"
${if} $0 == "Yes"
SectionSetText 4 "JabRef" ; names the corersponding uninstaller section
@ -452,8 +452,8 @@ Function un.onUninstSuccess
FunctionEnd
;----------------------
;Installer sections
#----------------------
#Installer sections
!include "Uninstall.nsh"
; eof
# eof

View File

@ -1,28 +1,28 @@
; Lyx for Windows, NSIS v2 series installer script
# Lyx for Windows, NSIS v2 series installer script
; File LyXWinInstaller.nsi
; This file is part of LyX, the document processor.
; http://www.lyx.org/
; Licence details can be found in the file COPYING or copy at
; http://www.lyx.org/about/license.php3
# File LyXWinInstaller.nsi
# This file is part of LyX, the document processor.
# http://www.lyx.org/
# Licence details can be found in the file COPYING or copy at
# http://www.lyx.org/about/license.php3
; Author Uwe Stöhr based on the work of Angus Leeming and Joost Verburg
; Full author contact details are available in file CREDITS or copy at
; http://www.lyx.org/about/credits.php
# Author Uwe Stöhr based on the work of Angus Leeming and Joost Verburg
# Full author contact details are available in file CREDITS or copy at
# http://www.lyx.org/about/credits.php
; This script requires NSIS 2.22 and newer
; http://nsis.sourceforge.net/
;--------------------------------
# This script requires NSIS 2.22 and newer
# http://nsis.sourceforge.net/
#--------------------------------
; Do a Cyclic Redundancy Check to make sure the installer
; was not corrupted by the download.
# Do a Cyclic Redundancy Check to make sure the installer
# was not corrupted by the download.
CRCCheck force
; Make the installer as small as possible.
; SetCompressor lzma
# Make the installer as small as possible.
# SetCompressor lzma
;--------------------------------
; You should need to change only these macros...
#--------------------------------
# You should need to change only these macros...
!define PRODUCT_DIR "D:\LyXPackage1.5"
!define PRODUCT_NAME "LyX"
@ -46,7 +46,7 @@ BrandingText "LyXWinInstaller v3.09 - Small"
!define INSTALLER2_EXE "LyXWin150beta1Complete-3-09.exe" ; to check later if this installer version is running at the same time
!define VERSION_BITMAP "${PRODUCT_DIR}\icons\lyx_logo_vert${PRODUCT_VERSION_SHORT}.bmp"
; Replaced by HKLM or HKCU depending on SetShellVarContext.
# Replaced by HKLM or HKCU depending on SetShellVarContext.
!define PRODUCT_ROOT_KEY "SHCTX"
!define PRODUCT_DIR_REGKEY "Software\Microsoft\Windows\CurrentVersion\App Paths\lyx.exe"
@ -74,15 +74,15 @@ BrandingText "LyXWinInstaller v3.09 - Small"
!define MiKTeXConfigFolder "MiKTeX\2.5\miktex\config"
!define MiKTeXDeliveredVersion "MiKTeX not included"
;--------------------------------
; Make some of the information above available to NSIS.
#--------------------------------
# Make some of the information above available to NSIS.
Name "${PRODUCT_NAME}"
OutFile "${INSTALLER_EXE}"
InstallDir "$PROGRAMFILES\${PRODUCT_NAME} ${PRODUCT_VERSION}"
;--------------------------------
; Variables
#--------------------------------
# Variables
Var LatexPath
Var PythonPath
@ -129,39 +129,39 @@ Var Pointer
Var UserList
Var RunNumber
;--------------------------------
; load some NSIS libraries
#--------------------------------
# load some NSIS libraries
!include "MUI.nsh"
!include "LogicLib.nsh"
!include "FileFunc.nsh"
!include "StrFunc.nsh"
;!include "TextFunc.nsh"
;!insertmacro LineFind
#!include "TextFunc.nsh"
#!insertmacro LineFind
; Set of various macros and functions
# Set of various macros and functions
!include "LyXUtils.nsh"
; Function to check if needed programs are missing or not
# Function to check if needed programs are missing or not
!include "MissingPrograms.nsh"
; Function for page to manually select LaTeX's installation folder
# Function for page to manually select LaTeX's installation folder
!include "LaTeXFolder.nsh"
; Functions for page to set installer language
; and LyX's menu language
# Functions for page to set installer language
# and LyX's menu language
!include "LanguageSettings.nsh"
; Function for page to install Aspell dictionaries
# Function for page to install Aspell dictionaries
!include "Aspell.nsh"
; Use the Abiword macros to help set up associations with the file extension in the Registry.
; Grabbed from
; http://abiword.pchasm.org/source/cvs/abiword-cvs/abi/src/pkg/win/setup/NSISv2/abi_util_fileassoc.nsh
# Use the Abiword macros to help set up associations with the file extension in the Registry.
# Grabbed from
# http://abiword.pchasm.org/source/cvs/abiword-cvs/abi/src/pkg/win/setup/NSISv2/abi_util_fileassoc.nsh
!include "abi_util_fileassoc.nsh"
;--------------------------------
#--------------------------------
; Remember the installer language
# Remember the installer language
!define MUI_LANGDLL_REGISTRY_ROOT "HKCU"
!define MUI_LANGDLL_REGISTRY_KEY "${PRODUCT_UNINST_KEY}"
!define MUI_LANGDLL_REGISTRY_VALUENAME "Installer Language"
@ -173,51 +173,51 @@ Var RunNumber
!define MUI_UNICON "${PRODUCT_DIR}\icons\lyx.ico"
!define MUI_WELCOMEFINISHPAGE_BITMAP "${VERSION_BITMAP}"
; Welcome page
# Welcome page
!define MUI_WELCOMEPAGE_TEXT "$(WelcomePageText)"
!insertmacro MUI_PAGE_WELCOME
; Show the license.
# Show the license.
!insertmacro MUI_PAGE_LICENSE "${PRODUCT_LICENSE_FILE}"
; Specify the installation directory.
# Specify the installation directory.
!insertmacro MUI_PAGE_DIRECTORY
; Specify LyX's menu language.
# Specify LyX's menu language.
Page custom SelectMenuLanguage SelectMenuLanguage_LeaveFunction
; Define which components to install.
# Define which components to install.
!insertmacro MUI_PAGE_COMPONENTS
; Specify where to install program shortcuts.
# Specify where to install program shortcuts.
!define MUI_STARTMENUPAGE_REGISTRY_ROOT "${PRODUCT_ROOT_KEY}"
!define MUI_STARTMENUPAGE_REGISTRY_KEY "${PRODUCT_UNINST_KEY}"
!define MUI_STARTMENUPAGE_REGISTRY_VALUENAME "Start Menu Folder"
!define MUI_STARTMENUPAGE_DEFAULTFOLDER "LyX ${PRODUCT_VERSION}"
!insertmacro MUI_PAGE_STARTMENU ${PRODUCT_NAME} $StartmenuFolder
; Select latex.exe manually
# Select latex.exe manually
Page custom LatexFolder LatexFolder_LeaveFunction
; Check for needed programs
# Check for needed programs
Page custom MissingProgramsPage MissingProgramsPage_LeaveFunction
; Watch the components being installed.
# Watch the components being installed.
!insertmacro MUI_PAGE_INSTFILES
; Finish page
# Finish page
!define MUI_FINISHPAGE_RUN
!define MUI_FINISHPAGE_TEXT "$(FinishPageMessage)"
!define MUI_FINISHPAGE_RUN_TEXT "$(FinishPageRun)"
!define MUI_FINISHPAGE_RUN_FUNCTION "LaunchProduct"
!insertmacro MUI_PAGE_FINISH
; The uninstaller.
# The uninstaller.
!insertmacro MUI_UNPAGE_COMPONENTS
!insertmacro MUI_UNPAGE_INSTFILES
;--------------------------------
; Languages
#--------------------------------
# Languages
!insertmacro MUI_LANGUAGE "English" # first language is the default language
!insertmacro MUI_LANGUAGE "Danish"
@ -253,16 +253,16 @@ Page custom MissingProgramsPage MissingProgramsPage_LeaveFunction
LicenseData "$(LyXLicenseData)"
;--------------------------------
; Reserve Files
#--------------------------------
# Reserve Files
; These files are inserted before other files in the data block
# These files are inserted before other files in the data block
!insertmacro MUI_RESERVEFILE_LANGDLL
ReserveFile "io_ui_language.ini"
!insertmacro MUI_RESERVEFILE_INSTALLOPTIONS
;--------------------------------
; Installer sections
#--------------------------------
# Installer sections
Section "!${PRODUCT_NAME}" SecCore
SectionIn RO
@ -278,7 +278,7 @@ Section "$(SecDesktopTitle)" SecDesktop
StrCpy $CreateDesktopIcon "true"
SectionEnd
; Section descriptions
# Section descriptions
!insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
!insertmacro MUI_DESCRIPTION_TEXT ${SecCore} "$(SecCoreDescription)"
!insertmacro MUI_DESCRIPTION_TEXT ${SecAllUsers} "$(SecAllUsersDescription)"
@ -288,14 +288,14 @@ SectionEnd
!include "InstallActions-small.nsh"
;--------------------------------
; This hook function is called internally by NSIS on installer startup
#--------------------------------
# This hook function is called internally by NSIS on installer startup
Function .onInit
; set the installer language to the Windows locale language
# set the installer language to the Windows locale language
System::Call "kernel32::GetUserDefaultLangID()i.a"
; Check that the installer is not currently running
# Check that the installer is not currently running
System::Call 'kernel32::CreateMutexA(i 0, i 0, t "${INSTALLER_EXE}.Instance") i .r1 ?e'
Pop $R0
${if} $R0 != "0"
@ -308,23 +308,23 @@ Function .onInit
Abort
${endif}
; Check if LyX is already installed
# Check if LyX is already installed
ReadRegStr $0 HKLM "${PRODUCT_UNINST_KEY}" "Publisher"
${if} $0 != ""
MessageBox MB_OK|MB_ICONSTOP "$(StillInstalled)"
Abort
${endif}
; Default settings
; These can be reset to "all" in section SecAllUsers.
# Default settings
# These can be reset to "all" in section SecAllUsers.
SetShellVarContext current
StrCpy $ProductRootKey "HKCU"
; This can be reset to "true" in section SecDesktop.
# This can be reset to "true" in section SecDesktop.
StrCpy $CreateDesktopIcon "false"
StrCpy $CreateFileAssociations "false"
; If the user does *not* have administrator privileges, abort
# If the user does *not* have administrator privileges, abort
StrCpy $Answer ""
StrCpy $UserName ""
!insertmacro IsUserAdmin $Answer $UserName ; macro from LyXUtils.nsh
@ -339,41 +339,41 @@ Function .onInit
Abort
${endif}
; check which programs are installed or not
# check which programs are installed or not
Call MissingPrograms ; function from MissingPrograms.nsh
; used later in the function LatexFolder
# used later in the function LatexFolder
StrCpy $State "0"
ClearErrors
FunctionEnd
;--------------------------------
#--------------------------------
Function LaunchProduct
Exec ${PRODUCT_BAT}
FunctionEnd
;--------------------------------
#--------------------------------
;Function DeleteLines
; StrCpy $0 SkipWrite
; Push $0
;FunctionEnd
#Function DeleteLines
# StrCpy $0 SkipWrite
# Push $0
#FunctionEnd
;--------------------------------
; The Uninstaller
#--------------------------------
# The Uninstaller
Function un.onInit
; Check that LyX is not currently running
# Check that LyX is not currently running
FindProcDLL::FindProc "lyx.exe"
${if} $R0 == "1"
MessageBox MB_OK|MB_ICONSTOP "$(UnInstallRunning)"
Abort
${endif}
; Ascertain whether the user has sufficient privileges to uninstall.
# Ascertain whether the user has sufficient privileges to uninstall.
SetShellVarContext current
ReadRegStr $0 HKCU "${PRODUCT_UNINST_KEY}" "RootKey"
@ -384,7 +384,7 @@ Function un.onInit
${endif}
${endif}
; If the user does *not* have administrator privileges, abort
# If the user does *not* have administrator privileges, abort
StrCpy $Answer ""
!insertmacro IsUserAdmin $Answer $UserName ; macro from LyXUtils.nsh
${if} $Answer == "yes"
@ -394,10 +394,10 @@ Function un.onInit
Abort
${endif}
; Macro to investigate name of LyX's preferences folders to be able remove them
# Macro to investigate name of LyX's preferences folders to be able remove them
!insertmacro UnAppPreSuff $AppPre $AppSuff ; macro from LyXUtils.nsh
; test if Aspell was installed together with LyX
# test if Aspell was installed together with LyX
ReadRegStr $0 HKLM "Software\Aspell" "OnlyWithLyX" ; special entry to test if it was installed with LyX
${if} $0 == "Yes"
SectionSetText 2 "Aspell" ; names the corersponding uninstaller section (has the index "2" as it is the third section in Uninstall.nsh)
@ -406,7 +406,7 @@ Function un.onInit
SectionSetText 2 "" ; hides the corresponding uninstaller section
${endif}
; test if MiKTeX was installed together with LyX
# test if MiKTeX was installed together with LyX
ReadRegStr $0 HKLM "SOFTWARE\MiKTeX.org\MiKTeX" "OnlyWithLyX"
${if} $0 == "Yes"
SectionSetText 3 "MiKTeX" ; names the corersponding uninstaller section
@ -415,7 +415,7 @@ Function un.onInit
SectionSetText 3 "" ; hides the corresponding uninstaller section
${endif}
; ignore JabRef because this could only be installed with the complete installer version
# ignore JabRef because this could only be installed with the complete installer version
SectionSetText 4 "" ; hides the corresponding uninstaller section
StrCpy $JabRefInstalled ""
@ -431,8 +431,8 @@ Function un.onUninstSuccess
FunctionEnd
;----------------------
;Installer sections
#----------------------
#Installer sections
!include "Uninstall.nsh"
; eof
# eof

View File

@ -1,38 +1,38 @@
; This script contains the following functions:
;
; - LaTeXCheck (check installed LaTeX-system), uses:
; StrPointer
; StrPoint
; RevStrPointer
; RevStrPoint
;
; - un.DelAppPathSub and UnAppPreSuff, (delete the folder ~\Documents and Settings\username\Application Data\LyX for all users), uses:
; un.GetParent
; un.GetUsers
; un.StrPoint
; StrPointer
; StrPoint
; UnAppPreSuff
;
; - CreateAppPathSub and AppPreSuff, (creates the folder ~\Documents and Settings\username\Application Data\LyX for all users), uses:
; GetParent
; GetUsers
; StrPointer
; StrPoint
; UnAppPreSuff
;
; - IsUserAdmin (checks if user is admin)
;
; - FileCheck (checks if a given file exists)
;
; - EditorCheck (check for installed editors)
;
;--------------------------
# This script contains the following functions:
#
# - LaTeXCheck (check installed LaTeX-system), uses:
# StrPointer
# StrPoint
# RevStrPointer
# RevStrPoint
#
# - un.DelAppPathSub and UnAppPreSuff, (delete the folder ~\Documents and Settings\username\Application Data\LyX for all users), uses:
# un.GetParent
# un.GetUsers
# un.StrPoint
# StrPointer
# StrPoint
# UnAppPreSuff
#
# - CreateAppPathSub and AppPreSuff, (creates the folder ~\Documents and Settings\username\Application Data\LyX for all users), uses:
# GetParent
# GetUsers
# StrPointer
# StrPoint
# UnAppPreSuff
#
# - IsUserAdmin (checks if user is admin)
#
# - FileCheck (checks if a given file exists)
#
# - EditorCheck (check for installed editors)
#
#--------------------------
!macro StrPointer FindStr SearchStr Pointer
; searches for a string/character (SearchStr) in another string (FindStr)
; and returns the number of the character in the FindStr where the SearchStr was found (Pointer)
; if nothing was found or the search is impossible the Pointer is set to -1
# searches for a string/character (SearchStr) in another string (FindStr)
# and returns the number of the character in the FindStr where the SearchStr was found (Pointer)
# if nothing was found or the search is impossible the Pointer is set to -1
StrLen $R2 ${SearchStr}
StrLen $R4 ${FindStr}
@ -57,18 +57,18 @@
!macroend
;--------------------------------
#--------------------------------
Function StrPoint
!insertmacro StrPointer $String $Search $Pointer
FunctionEnd
;--------------------------------
#--------------------------------
!macro RevStrPointer FindStr SearchStr Pointer
; searches for a string/character (SearchStr) in another string (FindStr) in reverse order
; and returns the number of the character in the FindStr where the SearchStr was found (Pointer)
; if nothing was found or the search is impossible the Pointer is set to +1
# searches for a string/character (SearchStr) in another string (FindStr) in reverse order
# and returns the number of the character in the FindStr where the SearchStr was found (Pointer)
# if nothing was found or the search is impossible the Pointer is set to +1
StrLen $R2 ${SearchStr}
StrLen $R4 ${FindStr}
@ -93,19 +93,19 @@ FunctionEnd
!macroend
;--------------------------------
#--------------------------------
Function RevStrPoint
!insertmacro RevStrPointer $String $Search $Pointer
FunctionEnd
;--------------------------------
#--------------------------------
!macro AppPreSuff AppPre AppSuff
; the APPDATA path has always the following structure:
; C:\Documents and Settings\username\Application Data
; this macro saves the "C:\Documents and Settings\" substring into the variable "AppPre"
; and the "Application Data" substring into the variable "AppSuff"
# the APPDATA path has always the following structure:
# C:\Documents and Settings\username\Application Data
# this macro saves the "C:\Documents and Settings\" substring into the variable "AppPre"
# and the "Application Data" substring into the variable "AppSuff"
StrCpy $String "$APPDATA"
StrCpy $Search "\"
@ -124,11 +124,11 @@ FunctionEnd
!macroend
;--------------------------------
#--------------------------------
Function GetParent
; deletes a subfolder of the APPDATA path for all users
; used by the function "un.getUsers"
# deletes a subfolder of the APPDATA path for all users
# used by the function "un.getUsers"
Exch $R0
Push $R1
@ -151,10 +151,10 @@ Function GetParent
FunctionEnd
;--------------------------------
#--------------------------------
Function GetUsers
; reads the subfolders of the "Documents and Settings" folder to get a list of the users
# reads the subfolders of the "Documents and Settings" folder to get a list of the users
StrCpy $R3 ""
Push "$PROFILE"
@ -181,11 +181,11 @@ Function GetUsers
FunctionEnd
;--------------------------------
#--------------------------------
Function un.GetParent
; deletes a subfolder of the APPDATA path for all users
; used by the function "un.getUsers"
# deletes a subfolder of the APPDATA path for all users
# used by the function "un.getUsers"
Exch $R0
Push $R1
@ -208,10 +208,10 @@ Function un.GetParent
FunctionEnd
;--------------------------------
#--------------------------------
Function un.GetUsers
; reads the subfolders of the "Documents and Settings" folder to get a list of the users
# reads the subfolders of the "Documents and Settings" folder to get a list of the users
StrCpy $R3 ""
Push "$PROFILE"
@ -238,19 +238,19 @@ Function un.GetUsers
FunctionEnd
;--------------------------------
#--------------------------------
Function un.StrPoint
!insertmacro StrPointer $String $Search $Pointer
FunctionEnd
;--------------------------------
#--------------------------------
!macro UnAppPreSuff AppPre AppSuff
; the APPDATA path has always the following structure:
; C:\Documents and Settings\username\Application Data
; this macro saves the "C:\Documents and Settings\" substring into the variable "AppPre"
; and the "Application Data" substring into the variable "AppSuff"
# the APPDATA path has always the following structure:
# C:\Documents and Settings\username\Application Data
# this macro saves the "C:\Documents and Settings\" substring into the variable "AppPre"
# and the "Application Data" substring into the variable "AppSuff"
StrCpy $String "$APPDATA"
StrCpy $Search "\"
@ -269,12 +269,12 @@ FunctionEnd
!macroend
;--------------------------------
#--------------------------------
Function un.DelAppPathSub
; deletes a subfolder of the APPDATA path for all users
# deletes a subfolder of the APPDATA path for all users
; get list of all users
# get list of all users
Push $R0
Push $R1
Push $R2
@ -286,7 +286,7 @@ Function un.DelAppPathSub
Pop $R1
Pop $R0
; the usernames in the list of all users is separated by "|"
# the usernames in the list of all users is separated by "|"
loop:
StrCpy $String "$UserList"
StrCpy $Search "|"
@ -295,8 +295,8 @@ Function un.DelAppPathSub
StrCpy $0 $UserList $Pointer ; $0 contains now the username
IntOp $Pointer $Pointer + 1 ; jump after the "|"
StrCpy $UserList $UserList "" $Pointer ; cut off the first username in the list
; generate the string for the current user
; AppPre and AppSuff are generated in the macro "AppPreSuff"
# generate the string for the current user
# AppPre and AppSuff are generated in the macro "AppPreSuff"
StrCpy $AppPath "$AppPre\$0\$AppSuff\${PRODUCT_SUBFOLDER}"
RMDir /r $AppPath ; delete the folder
Goto loop
@ -307,15 +307,15 @@ Function un.DelAppPathSub
FunctionEnd
;--------------------------------
#--------------------------------
Function CreateAppPathSub
; creates a subfolder of the APPDATA path for all users
# creates a subfolder of the APPDATA path for all users
; get folder names
# get folder names
!insertmacro AppPreSuff $AppPre $AppSuff
; get list of all users
# get list of all users
Push $R0
Push $R1
Push $R2
@ -327,7 +327,7 @@ Function CreateAppPathSub
Pop $R1
Pop $R0
; the usernames in the list of all users is separated by "|"
# the usernames in the list of all users is separated by "|"
loop:
StrCpy $String "$UserList"
StrCpy $Search "|"
@ -336,8 +336,8 @@ Function CreateAppPathSub
StrCpy $0 $UserList $Pointer ; $0 contains now the username
IntOp $Pointer $Pointer + 1 ; jump after the "|"
StrCpy $UserList $UserList "" $Pointer ; cut off the first username in the list
; generate the string for the current user
; AppPre and AppSuff are generated in the macro "AppPreSuff"
# generate the string for the current user
# AppPre and AppSuff are generated in the macro "AppPreSuff"
StrCpy $AppPath "$AppPre\$0\$AppSuff\${PRODUCT_SUBFOLDER}"
CreateDirectory $AppPath ; create the folder
CopyFiles "$INSTDIR\Resources\session" "$AppPath"
@ -351,7 +351,7 @@ Function CreateAppPathSub
FunctionEnd
;--------------------------------
#--------------------------------
!macro IsUserAdmin Result Name
@ -375,10 +375,10 @@ FunctionEnd
!macroend
;--------------------------------
#--------------------------------
!macro FileCheck Result FileName FilePath
; checks if a file exists, returns "True" or "False"
# checks if a file exists, returns "True" or "False"
Push $0
Push $1
@ -397,11 +397,11 @@ FunctionEnd
!macroend
;------------------------------------------
#------------------------------------------
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
# 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
StartCheck:
StrLen $3 $String
@ -425,7 +425,7 @@ Function LaTeXCheck
StrCpy $String $String $Pointer
${endif}
StrCpy $LatexPath "$LatexPath$String"
; check if the latex.exe exists in the $LatexPath folder
# check if the latex.exe exists in the $LatexPath folder
!insertmacro FileCheck $5 "latex.exe" "$LatexPath"
${if} $5 == "False" ; delete the entry with the wrong path to the latex.exe and try again
StrCpy $LatexPath ""
@ -441,88 +441,88 @@ Function LaTeXCheck
FunctionEnd
;------------------------------------------
#------------------------------------------
Function EditorCheck
; test if an editor with syntax-highlighting for LaTeX-files is installed
; (check for jEdit, PSPad, WinShell, ConTEXT, Crimson Editor, Vim, TeXnicCenter, LaTeXEditor, WinEdt, LEd, WinTeX)
# test if an editor with syntax-highlighting for LaTeX-files is installed
# (check for jEdit, PSPad, WinShell, ConTEXT, Crimson Editor, Vim, TeXnicCenter, LaTeXEditor, WinEdt, LEd, WinTeX)
StrCpy $EditorPath ""
StrCpy $0 ""
; check for jEdit
# check for jEdit
ReadRegStr $EditorPath HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\jEdit_is1" "InstallLocation"
${if} $EditorPath != ""
StrCpy $EditorPath $EditorPath -1 ; remove "\" from the end of the string
${endif}
; check for PSPad
# check for PSPad
StrCpy $0 ""
ReadRegStr $0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\PSPad editor_is1" "InstallLocation"
${if} $0 != ""
StrCpy $0 $0 -1
StrCpy $EditorPath "$EditorPath;$0"
${endif}
; check for WinShell
# check for WinShell
StrCpy $0 ""
ReadRegStr $0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\WinShell_is1" "InstallLocation"
${if} $0 != ""
StrCpy $0 $0 -1
StrCpy $EditorPath "$EditorPath;$0"
${endif}
; check for ConTEXT
# check for ConTEXT
StrCpy $0 ""
ReadRegStr $0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\ConTEXTEditor_is1" "InstallLocation"
${if} $0 != ""
StrCpy $0 $0 -1
StrCpy $EditorPath "$EditorPath;$0"
${endif}
; check for Crimson Editor
# check for Crimson Editor
StrCpy $0 ""
ReadRegStr $0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Crimson Editor" "UninstallString"
${if} $0 != ""
StrCpy $0 $0 -14 ; remove "\uninstall.exe"
StrCpy $EditorPath "$EditorPath;$0"
${endif}
; check for Vim 6.x
# check for Vim 6.x
StrCpy $0 ""
ReadRegStr $0 HKLM "Software\Classes\Applications\gvim.exe\shell\edit\command" ""
${if} $0 != ""
StrCpy $0 $0 -13 ; remove "gvim.exe "%1""
StrCpy $EditorPath "$EditorPath;$0"
${endif}
; check for Vim 7.0
# check for Vim 7.0
StrCpy $0 ""
ReadRegStr $0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Vim 7.0" "UninstallString"
${if} $0 != ""
StrCpy $0 $0 -18 ; remove "\uninstall-gui.exe"
StrCpy $EditorPath "$EditorPath;$0"
${endif}
; check for TeXnicCenter
# check for TeXnicCenter
StrCpy $0 ""
ReadRegStr $0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\TeXnicCenter_is1" "Inno Setup: App Path"
${if} $0 != ""
StrCpy $EditorPath "$EditorPath;$0"
${endif}
; check for LaTeXEditor
# check for LaTeXEditor
StrCpy $0 ""
ReadRegStr $0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\LaTeX Editor" "InstallLocation"
${if} $0 != ""
StrCpy $EditorPath "$EditorPath;$0"
${endif}
; check for WinEdt
# check for WinEdt
StrCpy $0 ""
ReadRegStr $0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\WinEdt_is1" "InstallLocation"
${if} $0 != ""
StrCpy $0 $0 -1
StrCpy $EditorPath "$EditorPath;$0"
${endif}
; check for LEd
# check for LEd
StrCpy $0 ""
ReadRegStr $0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\LEd_is1" "InstallLocation"
${if} $0 != ""
StrCpy $0 $0 -1
StrCpy $EditorPath "$EditorPath;$0"
${endif}
; check for WinTeX
# check for WinTeX
StrCpy $0 ""
ReadRegStr $0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\WinTeX XP" "DisplayIcon"
${if} $0 != ""

View File

@ -2,12 +2,12 @@ Function MissingPrograms
StrCpy $MissedProg "False"
; test if MiKTeX is installed
; read the PATH variable via the registry because NSIS' "$%Path%" variable is not updated when the PATH changes
# test if MiKTeX is installed
# read the PATH variable via the registry because NSIS' "$%Path%" variable is not updated when the PATH changes
ReadRegStr $String HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "Path"
StrCpy $Search "miktex"
Call LaTeXCheck ; sets the path to the latex.exe to $LatexPath ; function from LyXUtils.nsh
; check if MiKTeX 2.4 or 2.5 is installed
# check if MiKTeX 2.4 or 2.5 is installed
StrCpy $String ""
ReadRegStr $String HKLM "Software\MiK\MiKTeX\CurrentVersion\MiKTeX" "Install Root"
${if} $String != ""
@ -16,14 +16,14 @@ Function MissingPrograms
${endif}
${if} $LatexPath == "" ; check if MiKTeX is installed only for the current user
; check for MiKTeX 2.5
# check for MiKTeX 2.5
ReadRegStr $String HKCU "Environment" "Path"
StrCpy $Search "miktex"
Call LaTeXCheck ; function from LyXUtils.nsh
${if} $LatexPath != ""
StrCpy $MiKTeXUser "HKCU" ; needed later to for a message about MiKTeX's install folder write permissions, see InstallActions-*.nsh
${endif}
; check for MiKTeX 2.4
# check for MiKTeX 2.4
StrCpy $String ""
ReadRegStr $String HKCU "Software\MiK\MiKTeX\CurrentVersion\MiKTeX" "Install Root"
${if} $String != ""
@ -39,28 +39,28 @@ Function MissingPrograms
${endif}
${endif}
; test if TeXLive is installed
; as described at TeXLives' homepage there should be an entry in the PATH
# test if TeXLive is installed
# as described at TeXLives' homepage there should be an entry in the PATH
${if} $LatexPath == ""
ReadRegStr $String HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "Path"
StrCpy $Search "TeXLive"
Call LaTeXCheck ; function from LyXUtils.nsh
${endif}
; check for the current user Path variable (the case when it is a live CD/DVD)
# check for the current user Path variable (the case when it is a live CD/DVD)
${if} $LatexPath == ""
ReadRegStr $String HKCU "Environment" "Path"
StrCpy $Search "texlive"
StrCpy $2 "TeXLive"
Call LaTeXCheck ; function from LyXUtils.nsh
${endif}
; check if the variable TLroot exists (the case when it is installed using the program "tlpmgui")
# check if the variable TLroot exists (the case when it is installed using the program "tlpmgui")
${if} $LatexPath == ""
ReadRegStr $String HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "TLroot"
${if} $String == ""
ReadRegStr $String HKCU "Environment" "TLroot" ; the case when installed without admin permissions
${endif}
StrCpy $LatexPath "$String\bin\win32"
; check if the latex.exe exists in the $LatexPath folder
# check if the latex.exe exists in the $LatexPath folder
!insertmacro FileCheck $5 "latex.exe" "$LatexPath" ; macro from LyXUtils.nsh
${if} $5 == "False"
StrCpy $LatexPath ""
@ -72,7 +72,7 @@ Function MissingPrograms
StrCpy $LaTeXName "TeXLive"
${endif}
; test if Ghostscript is installed
# test if Ghostscript is installed
GSloop:
EnumRegKey $1 HKLM "Software\AFPL Ghostscript" 0
${if} $1 == ""
@ -108,20 +108,20 @@ Function MissingPrograms
StrCpy $MissedProg "True"
${endif}
; test if Imagemagick is installed
# test if Imagemagick is installed
ReadRegStr $ImageMagickPath HKLM "Software\ImageMagick\Current" "BinPath"
${if} $ImageMagickPath == ""
StrCpy $MissedProg "True"
${endif}
; test if Aiksaurus is installed
# test if Aiksaurus is installed
!insertmacro FileCheck $5 "meanings.dat" "${AiksaurusDir}" ; macro from LyXUtils.nsh
${if} $5 == "True"
StrCpy $AiksaurusPath "${AiksaurusDir}"
${endif}
; ReadRegStr $AiksaurusPath HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "AIK_DATA_DIR"
# ReadRegStr $AiksaurusPath HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "AIK_DATA_DIR"
; test if Aspell is installed
# test if Aspell is installed
StrCpy $5 ""
ReadRegStr $5 HKCU "SOFTWARE\Aspell" "Base Path"
${if} $5 == ""
@ -136,16 +136,16 @@ Function MissingPrograms
StrCpy $AspellPath "$5"
${endif}
; test if Python is installed
; only use an existing python when it is version 2.5 because many Compaq and Dell PC are delivered
; with outdated Python interpreters
# test if Python is installed
# only use an existing python when it is version 2.5 because many Compaq and Dell PC are delivered
# with outdated Python interpreters
ReadRegStr $PythonPath HKLM "Software\Python\PythonCore\2.5\InstallPath" ""
${if} $PythonPath != ""
StrCpy $0 $PythonPath "" -1 ; remove the "\" at the end
StrCpy $DelPythonFiles "True"
${endif}
; test if Acrobat or Adobe Reader is used as PDF-viewer
# test if Acrobat or Adobe Reader is used as PDF-viewer
ReadRegStr $String HKCR ".pdf" ""
${if} $String != "AcroExch.Document" ; this name is only used by Acrobat and Adobe Reader
StrCpy $Acrobat "None"
@ -161,20 +161,20 @@ Function MissingPrograms
${endif}
${endif}
; test if a PostScript-viewer is installed, only check for GSview32
# test if a PostScript-viewer is installed, only check for GSview32
StrCpy $PSVPath ""
ReadRegStr $PSVPath HKLM "Software\Microsoft\Windows\CurrentVersion\App Paths\gsview32.exe" "Path"
; test if an editor with syntax-highlighting for LaTeX-files is installed (function in LyXUtils.nsh)
# test if an editor with syntax-highlighting for LaTeX-files is installed (function in LyXUtils.nsh)
Call EditorCheck ; function from LyXUtils.nsh
; test if an image editor is installed (due to LyX's bug 2654 first check for GIMP)
# test if an image editor is installed (due to LyX's bug 2654 first check for GIMP)
StrCpy $ImageEditorPath ""
ReadRegStr $ImageEditorPath HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\WinGimp-2.0_is1" "DisplayIcon"
${if} $ImageEditorPath != ""
StrCpy $ImageEditorPath "$ImageEditorPath" -13 ; delete "\gimp-2.x.exe"
${endif}
; check for Photoshop
# check for Photoshop
ReadRegStr $0 HKLM "Software\Microsoft\Windows\CurrentVersion\App Paths\Photoshop.exe" "Path"
${if} $0 != ""
StrCpy $0 "$0" -1 ; delete the last "\"
@ -185,7 +185,7 @@ Function MissingPrograms
${endif}
${endif}
; test if the BibTeX-editor JabRef is installed
# test if the BibTeX-editor JabRef is installed
StrCpy $BibTeXEditorPath ""
ReadRegStr $BibTeXEditorPath HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\JabRef 2.1" "UninstallString"
${if} $BibTeXEditorPath == ""
@ -196,7 +196,7 @@ FunctionEnd
Function MissingProgramsPage
; generate the installer page - re-read empty page first
# generate the installer page - re-read empty page first
StrCpy $0 "2"
!insertmacro MUI_INSTALLOPTIONS_EXTRACT "io_missing_progs.ini"
!insertmacro MUI_HEADER_TEXT "$(MissProgHeader)" ""

View File

@ -1,10 +1,10 @@
; Uninstall sections
# Uninstall sections
Section "un.LyX" un.SecUnProgramFiles
SectionIn RO
; delete LaTeX class files that were installed together with LyX
# delete LaTeX class files that were installed together with LyX
FileOpen $R5 "$INSTDIR\Resources\uninstallPaths.dat" r
FileRead $R5 $LatexPath
FileClose $R5
@ -23,54 +23,54 @@ Section "un.LyX" un.SecUnProgramFiles
ExecWait "$LatexPath\initexmf --update-fndb"
${endif}
; delete LyX's installation folder
# delete LyX's installation folder
RMDir /r $INSTDIR
; delete start menu folder
# delete start menu folder
ReadRegStr $0 ${PRODUCT_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "StartMenu"
RMDir /r "$0"
; delete desktop icon
# delete desktop icon
Delete "$DESKTOP\${PRODUCT_NAME}.lnk"
; delete registry entries
# delete registry entries
DeleteRegKey HKCU "${PRODUCT_UNINST_KEY}"
DeleteRegKey ${PRODUCT_ROOT_KEY} "${PRODUCT_UNINST_KEY}"
DeleteRegKey HKLM "${PRODUCT_DIR_REGKEY}"
DeleteRegKey HKCR "Applications\lyx.exe"
DeleteRegKey HKCR "Applications\lyx.bat"
; Aiksaurus
# Aiksaurus
!insertmacro FileCheck $5 "meanings.dat" "${AiksaurusDir}" ; macro from LyXUtils.nsh
${if} $5 == "True"
RMDir /r "${AiksaurusDir}"
${endif}
; StrCpy $0 ""
; ReadRegStr $0 HKLM "Software\Aiksaurus" "OnlyWithLyX" ; special entry to test if it was installed with LyX
; ${if} $0 == "Yes"
; ; unregister Aiksaurus
; ReadRegStr $1 HKLM "Software\Aiksaurus" "Data Path"
; RMDir /r "$1"
; DeleteRegKey HKLM "SOFTWARE\Aiksaurus"
; ${endif}
# StrCpy $0 ""
# ReadRegStr $0 HKLM "Software\Aiksaurus" "OnlyWithLyX" ; special entry to test if it was installed with LyX
# ${if} $0 == "Yes"
# ; unregister Aiksaurus
# ReadRegStr $1 HKLM "Software\Aiksaurus" "Data Path"
# RMDir /r "$1"
# DeleteRegKey HKLM "SOFTWARE\Aiksaurus"
# ${endif}
; ImageMagick
# ImageMagick
StrCpy $0 ""
ReadRegStr $0 HKLM "Software\ImageMagick" "OnlyWithLyX" ; special entry to test if it was installed with LyX
${if} $0 == "Yes"
; unregister ImageMagick
# unregister ImageMagick
DeleteRegValue HKLM "SOFTWARE\Classes\Applications" "AutoRun"
DeleteRegKey HKLM "SOFTWARE\ImageMagick"
${endif}
; Ghostscript and GSview
# Ghostscript and GSview
StrCpy $0 ""
StrCpy $5 ""
ReadRegStr $0 HKLM "SOFTWARE\GPL Ghostscript" "OnlyWithLyX" ; special entry to test if it was installed with LyX
${if} $0 == "Yes"
; unregister Ghostscript
# unregister Ghostscript
DeleteRegKey HKLM "SOFTWARE\GPL Ghostscript"
; test if GSview is installed
# test if GSview is installed
EnumRegValue $5 HKLM "Software\Ghostgum\GSview" 0
${if} $5 != ""
; unregister GSview
# unregister GSview
MessageBox MB_ICONINFORMATION|MB_OK "$(UnGSview)"
ReadRegStr $3 HKLM "Software\Ghostgum\GSview" "$5"
ReadRegStr $4 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\GSview $5" "UninstallString"
@ -78,15 +78,15 @@ Section "un.LyX" un.SecUnProgramFiles
${endif}
${endif}
; MiKTeX specific LyX setting
# MiKTeX specific LyX setting
DeleteRegValue HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "MIKTEX_AUTOINSTALL"
DeleteRegValue HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" "MIKTEX_REPOSITORY"
; remove extension .lyx
# remove extension .lyx
${RemoveFileAssociation} "${PRODUCT_EXT}" "${PRODUCT_NAME}"
DeleteRegKey HKCR "${PRODUCT_NAME}"
; clear info that programs were installed together with LyX
# clear info that programs were installed together with LyX
DeleteRegValue HKLM "SOFTWARE\MiKTeX.org\MiKTeX" "OnlyWithLyX"
DeleteRegValue HKLM "Software\Aspell" "OnlyWithLyX"
DeleteRegValue HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${JabRefVersion}" "OnlyWithLyX"
@ -95,17 +95,17 @@ Section "un.LyX" un.SecUnProgramFiles
SectionEnd
;---------------------------------
; user preferences
#---------------------------------
# user preferences
Section "un.$(UnLyXPreferencesTitle)" un.SecUnPreferences
; remove LyX's config files
# remove LyX's config files
Call un.DelAppPathSub ; function from LyXUtils.nsh
SectionEnd
;---------------------------------
; Aspell
#---------------------------------
# Aspell
Section "un.Aspell" un.SecUnAspell
${if} $AspellInstallYes == "Aspell" ; only uninstall Aspell when it was installed together with LyX
@ -114,8 +114,8 @@ Section "un.Aspell" un.SecUnAspell
SectionEnd
;---------------------------------
; MiKTeX
#---------------------------------
# MiKTeX
Section "un.MiKTeX" un.SecUnMiKTeX
${if} $MiKTeXInstalled == "MiKTeX" ; only uninstall MiKTeX when it was installed together with LyX
@ -125,8 +125,8 @@ Section "un.MiKTeX" un.SecUnMiKTeX
SectionEnd
;---------------------------------
; JabRef
#---------------------------------
# JabRef
Section "un.JabRef" un.SecUnJabRef
${if} $JabRefInstalled == "JabRef" ; only uninstall JabRef when it was installed together with LyX
@ -136,8 +136,8 @@ Section "un.JabRef" un.SecUnJabRef
SectionEnd
;---------------------------------
; Section descriptions
#---------------------------------
# Section descriptions
!insertmacro MUI_UNFUNCTION_DESCRIPTION_BEGIN
!insertmacro MUI_DESCRIPTION_TEXT ${un.SecUnAspell} "$(SecUnAspellDescription)"
!insertmacro MUI_DESCRIPTION_TEXT ${un.SecUnMiKTeX} "$(SecUnMiKTeXDescription)"

View File

@ -1,5 +1,5 @@
;Title AbiWord for Windows, NSIS v2 series installer script
;FileDesc Utility functions to set and save/restore file extension to application associations
#Title AbiWord for Windows, NSIS v2 series installer script
#FileDesc Utility functions to set and save/restore file extension to application associations
!ifndef _ABI_UTIL_FILEASSOC_NSH_
@ -7,10 +7,10 @@
!ifdef HAVE_SYSTEM_PLUGIN
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; RefreshShellIcons based on
;; http://nsis.sourceforge.net/archive/nsisweb.php?page=236&instances=0
;; by jerome tremblay - april 2003
#;;;;;;;;;;;;;;;;;;;;;;;;;;;;
#; RefreshShellIcons based on
#; http://nsis.sourceforge.net/archive/nsisweb.php?page=236&instances=0
#; by jerome tremblay - april 2003
!define SHCNE_ASSOCCHANGED 0x08000000
!define SHCNF_IDLIST 0
@ -26,29 +26,29 @@ FunctionEnd
!endif ; HAVE_SYSTEM_PLUGIN
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; parts from http://nsis.sourceforge.net/archive/viewpage.php?pageid=282 by Vytautas
;; Will add the registry entries to associate the given file extension with the
;; previously set (see CreateApplicationAssociation) appType. I.e. indicate to
;; open documents with this extension using the application specified by appType
;; registry entry. If the extension is currently associated with a different
;; appType, it will store the current association in the "prior_appType" key.
#;;;;;;;;;;;;;;;;;;;;;;;;;;;;
#; parts from http://nsis.sourceforge.net/archive/viewpage.php?pageid=282 by Vytautas
#; Will add the registry entries to associate the given file extension with the
#; previously set (see CreateApplicationAssociation) appType. I.e. indicate to
#; open documents with this extension using the application specified by appType
#; registry entry. If the extension is currently associated with a different
#; appType, it will store the current association in the "prior_appType" key.
!macro CreateFileAssociation extension appType contentType
!define skipBackupLbl "skipBackup_${__LINE__}"
push $0
; back up old value of extension (.ext) if it exists
# back up old value of extension (.ext) if it exists
ReadRegStr $0 HKCR "${extension}" "" ; read current value
StrCmp $0 "" "${skipBackupLbl}" ; nothing, then skip storing old value
StrCmp $0 "${appType}" "${skipBackupLbl}" ; only store if old is different than current
WriteRegStr HKCR "${extension}" "prior_value" "$0" ; actually store the old association
"${skipBackupLbl}:"
; Write File Associations
# Write File Associations
WriteRegStr HKCR "${extension}" "" "${appType}"
WriteRegStr HKCR "${extension}" "Content Type" "${contentType}"
; Force shell refresh (so icons updated as needed)
# Force shell refresh (so icons updated as needed)
${RefreshShellIcons}
pop $0
@ -62,27 +62,27 @@ FunctionEnd
WriteRegStr HKCR "${appType}\shell" "" "open"
WriteRegStr HKCR "${appType}\DefaultIcon" "" "${defIcon}"
; Basic command to open the file (pass filename as argv[1] to program executable)
# Basic command to open the file (pass filename as argv[1] to program executable)
WriteRegStr HKCR "${appType}\shell\open\command" "" '"${exeCmd}" "%1"'
; To open file via DDE (OLE, ie via already active instance) instead of in a new process
; Here for those who want to locally enable, not normally used as having each document
; open in a new process while more resource intensive means a crash with one document
; won't cause loss of work with other open documents.
; WriteRegStr HKCR "${appType}\shell\open\command" "" "${exeCmd}"
; WriteRegStr HKCR "${appType}\shell\open\ddeexec" "" '[Open("%1")]'
; WriteRegStr HKCR "${appType}\shell\open\ddeexec\application" "" "${appName}"
; WriteRegStr HKCR "${appType}\shell\open\ddeexec\topic" "" "System"
# To open file via DDE (OLE, ie via already active instance) instead of in a new process
# Here for those who want to locally enable, not normally used as having each document
# open in a new process while more resource intensive means a crash with one document
# won't cause loss of work with other open documents.
# WriteRegStr HKCR "${appType}\shell\open\command" "" "${exeCmd}"
# WriteRegStr HKCR "${appType}\shell\open\ddeexec" "" '[Open("%1")]'
# WriteRegStr HKCR "${appType}\shell\open\ddeexec\application" "" "${appName}"
# WriteRegStr HKCR "${appType}\shell\open\ddeexec\topic" "" "System"
; If editing file is a different action than simply opening file
; WriteRegStr HKCR "${appType}\shell\edit" "" "Edit Options File"
; WriteRegStr HKCR "${appType}\shell\edit\command" "" '"${exeCmd}" "%1"'
# If editing file is a different action than simply opening file
# WriteRegStr HKCR "${appType}\shell\edit" "" "Edit Options File"
# WriteRegStr HKCR "${appType}\shell\edit\command" "" '"${exeCmd}" "%1"'
!macroend
!define CreateApplicationAssociation "!insertmacro CreateApplicationAssociation"
; check if a file extension is associated with us and if so delete it
# check if a file extension is associated with us and if so delete it
!macro RemoveFileAssociation extension appType
push $0
push $1

View File

@ -1,10 +1,10 @@
;NSIS Modern User Interface - Language File
;Compatible with Modern UI 1.68
#NSIS Modern User Interface - Language File
#Compatible with Modern UI 1.68
;Language: Galician (1110)
;Ramon Flores <fa2ramon@usc.es>
#Language: Galician (1110)
#Ramon Flores <fa2ramon@usc.es>
;--------------------------------
#--------------------------------
!insertmacro MUI_LANGUAGEFILE_BEGIN "Galician"

View File

@ -6,14 +6,14 @@ Create uninstaller, file associations and configure LyX
!define SHORTCUT '${APP_NAME} ${APP_SERIES_NAME}.lnk" "$INSTDIR\${APP_RUN}" "" "$INSTDIR\${APP_RUN}" "" "" "" "${APP_INFO}"'
;--------------------------------
;Sections
#--------------------------------
#Sections
Section -FileAssociations
;Associate .lyx files with LyX for current user of all users
#Associate .lyx files with LyX for current user of all users
;Write information about file type
#Write information about file type
!define REG_FILETYPE 'WriteRegStr SHELL_CONTEXT "Software\Classes\${APP_REGNAME_DOC}'
${REG_FILETYPE}" "" "${APP_NAME} Document"
@ -25,14 +25,14 @@ Section -FileAssociations
${REG_FILEEXT} "" "${APP_REGNAME_DOC}"
${REG_FILEEXT} "Content Type" "${APP_MIME_TYPE}"
;Refresh shell
#Refresh shell
System::Call 'shell32.dll::SHChangeNotify(i, i, i, i) (${SHCNE_ASSOCCHANGED}, ${SHCNF_IDLIST}, 0, 0)'
SectionEnd
Section -InstallData
;Registry information
#Registry information
WriteRegStr SHELL_CONTEXT ${APP_REGKEY} "" $INSTDIR
WriteRegStr SHELL_CONTEXT ${APP_REGKEY} "Version" "${APP_VERSION}"
@ -41,11 +41,11 @@ Section -InstallData
WriteRegStr SHELL_CONTEXT ${APP_REGKEY_SETUP} "Ghostscript Path" $PathGhostscript
WriteRegStr SHELL_CONTEXT ${APP_REGKEY_SETUP} "LyX Language" $LangName
;Start Menu shortcut
;There is only one shortcut to the application, so it should be in the main group
#Start Menu shortcut
#There is only one shortcut to the application, so it should be in the main group
CreateShortCut "$SMPROGRAMS\${SHORTCUT}
;Uninstaller information
#Uninstaller information
!define REG_UNINSTALL 'WriteRegStr SHELL_CONTEXT "Software\Microsoft\Windows\CurrentVersion\Uninstall\${SETUP_UNINSTALLER_KEY}"'
${if} $CurrentUserInstall == ${TRUE}
@ -66,9 +66,9 @@ SectionEnd
Section -LaTeX
;Let MiKTeX ask the user again to download packages if needed
#Let MiKTeX ask the user again to download packages if needed
;MiKTeX 2.5
#MiKTeX 2.5
ReadRegStr $R0 HKCU "Software\MiKTeX.org\MiKTeX\2.5\MPM" "AutoInstall"
@ -76,7 +76,7 @@ Section -LaTeX
WriteRegStr HKCU "Software\MiKTeX.org\MiKTeX\2.5\MPM" "AutoInstall" 2
${endif}
;MiKTeX 2.4
#MiKTeX 2.4
ReadRegStr $R0 HKCU "Software\MiK\MiKTeX\CurrentVersion\MiKTeX" "InstallPackagesOnTheFly"
@ -84,7 +84,7 @@ Section -LaTeX
WriteRegStr HKCU "Software\MiK\MiKTeX\CurrentVersion\MiKTeX" "InstallPackagesOnTheFly" 2
${endif}
;dvipost package
#dvipost package
Call SearchLaTeXLocalRoot
Pop $R0
@ -94,7 +94,7 @@ Section -LaTeX
File "${FILES_DVIPOST_PKG}\dvipost.sty"
${endif}
;Update file name database
#Update file name database
${if} $PathLaTeX != ""
nsExec::Exec '"$PathLaTeX\initexmf.exe" --update-fndb'
@ -105,42 +105,42 @@ SectionEnd
Section -Configure
;Windows specific configuration in lyxrc.dist
#Windows specific configuration in lyxrc.dist
Delete "$INSTDIR\Resources\lyxrc.dist"
FileOpen $R1 "$INSTDIR\Resources\lyxrc.dist" w
;Path prefix
#Path prefix
Call GetPathPrefix
Pop $R0
FileWrite $R1 '\path_prefix "$R0"$\r$\n'
;Default screen fonts
#Default screen fonts
FileWrite $R1 '\screen_font_roman "Times New Roman"$\r$\n'
FileWrite $R1 '\screen_font_sans "Arial"$\r$\n'
FileWrite $R1 '\screen_font_typewriter "Courier New"$\r$\n'
FileWrite $R1 '\preview_scale_factor 1.0$\r$\n' ;Fit instant preview font size to screen fonts
;PDF view helper
#PDF view helper
FileWrite $R1 '\format "pdf" "pdf" "PDF (ps2pdf)" "P" "pdfview" "" "document,vector"$\r$\n'
FileWrite $R1 '\format "pdf2" "pdf" "PDF (pdflatex)" "F" "pdfview" "" "document,vector"$\r$\n'
FileWrite $R1 '\format "pdf3" "pdf" "PDF (dvipdfm)" "m" "pdfview" "" "document,vector"$\r$\n'
FileClose $R1
;Information in the registry for the launcher
#Information in the registry for the launcher
;Set language
#Set language
WriteRegStr SHELL_CONTEXT ${APP_REGKEY_SETTINGS} "Language" $LangISOCode
SectionEnd
;--------------------------------
;Functions
#--------------------------------
#Functions
Function CheckDesktopShortcut
;Enable desktop icon creation when there is an icon already
;Old shortcuts need to be updated
#Enable desktop icon creation when there is an icon already
#Old shortcuts need to be updated
${if} ${fileexists} "$DESKTOP\${APP_NAME} ${APP_SERIES_NAME}.lnk"
!insertmacro MUI_INSTALLOPTIONS_WRITE "ioSpecial.ini" "Field 5" "State" "1"
@ -150,7 +150,7 @@ FunctionEnd
Function CreateDesktopShortcut
;Creating a desktop shortcut is an option on the finish page
#Creating a desktop shortcut is an option on the finish page
CreateShortCut "$DESKTOP\${SHORTCUT}

View File

@ -5,16 +5,16 @@ Binaries, Resources, Python, Aspell
*/
;--------------------------------
;Sections
#--------------------------------
#Sections
Section -Core SecCore
;Install and register the core LyX files
#Install and register the core LyX files
InitPluginsDir
;Binaries
#Binaries
SetOutPath "$INSTDIR\bin"
@ -34,19 +34,19 @@ 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"
File /r "${FILES_LYX}\Resources"
SetOutPath "$INSTDIR\Resources\fonts"
!insertmacro FileListFonts File "${FILES_FONTS}\"
;Components of Python
#Components of Python
SetOutPath "$INSTDIR\python"
!insertmacro FileListPythonBin File "${FILES_PYTHON}\"
@ -58,7 +58,7 @@ Section -Core SecCore
SetOutPath "$INSTDIR\python\Lib\encodings"
!insertmacro FileListPythonLibEncodings File "${FILES_PYTHON}\Lib\encodings\"
;Aspell
#Aspell
File /oname=$PLUGINSDIR\AspellData.exe "${FILES_ASPELLDATA}\AspellData.exe"
@ -70,18 +70,18 @@ Section -Core SecCore
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

View File

@ -4,8 +4,8 @@ Aspell dictionaries
*/
;--------------------------------
;Macros
#--------------------------------
#Macros
!macro Dictionary FILE LANGNAME LANGCODE SIZE
@ -23,8 +23,8 @@ Aspell dictionaries
!macroend
;--------------------------------
;Sections
#--------------------------------
#Sections
Section -AspellDicts
@ -71,13 +71,13 @@ ${DICT} tr-0.50-0 "T
${DICT} uk-1.1-0 "Ukrainian" uk 582
${DICT} cy-0.50-3 "Welsh" cy 1770
;--------------------------------
;Functions
#--------------------------------
#Functions
Function GetAspellHive
;Check whether the system or local version of Aspell should be used
;The patched Aspell uses the same logic
#Check whether the system or local version of Aspell should be used
#The patched Aspell uses the same logic
Push $R0
@ -104,12 +104,12 @@ Function DownloadDictionary
dict_download:
;Download
#Download
InetLoad::load "${DOWNLOAD_ASPELLDICTS}/aspell6-$R0.exe" "$PLUGINSDIR\aspell6-$R0.exe" /END
Pop $R3
${if} $R3 != "OK"
;Download failed
#Download failed
MessageBox MB_YESNO|MB_ICONEXCLAMATION "$(TEXT_DOWNLOAD_FAILED_DICT) ($R3)" IDYES dict_download
Goto dict_noinstall
${endif}

View File

@ -4,8 +4,8 @@ External Components: MiKTeX, ImageMagick, Ghostscript
*/
;--------------------------------
;Macros
#--------------------------------
#Macros
!macro SetComponentState VAR COMPONENT
@ -16,7 +16,7 @@ External Components: MiKTeX, ImageMagick, Ghostscript
StrCpy $R1 $Size${COMPONENT}
${if} $Path${COMPONENT} == ""
;Add size of component itself
#Add size of component itself
IntOp $R1 $R1 + ${SIZE_${COMPONENT}}
${endif}
@ -33,7 +33,7 @@ External Components: MiKTeX, ImageMagick, Ghostscript
!macro ExternalComponent COMPONENT
;Action depending on type of installer
#Action depending on type of installer
${if} $Setup${component} == ${TRUE}
@ -51,7 +51,7 @@ External Components: MiKTeX, ImageMagick, Ghostscript
!macro SetupComponent COMPONENT
;Run the setup application for a component
#Run the setup application for a component
install_${COMPONENT}:
@ -73,12 +73,12 @@ External Components: MiKTeX, ImageMagick, Ghostscript
download_${COMPONENT}:
;Download using HTTP
#Download using HTTP
InetLoad::load "${DOWNLOAD_${COMPONENT}}" "$PLUGINSDIR\${COMPONENT}Setup.exe" /END
Pop $R0
${if} $R0 != "OK"
;Download failed
#Download failed
MessageBox MB_YESNO|MB_ICONEXCLAMATION "$(TEXT_DOWNLOAD_FAILED_${COMPONENT}) ($R0)" IDYES download_${COMPONENT}
Goto noinstall_${COMPONENT}
${endif}
@ -93,7 +93,7 @@ External Components: MiKTeX, ImageMagick, Ghostscript
!macro InstallComponent COMPONENT
;Extract
#Extract
File /oname=$PLUGINSDIR\${COMPONENT}Setup.exe ${FILES_BUNDLE}\${INSTALL_${COMPONENT}}
!insertmacro SetupComponent ${COMPONENT}
@ -104,7 +104,7 @@ External Components: MiKTeX, ImageMagick, Ghostscript
!macro DialogExternalControl component
;Enable/disable the DirRequest control
#Enable/disable the DirRequest control
!insertmacro MUI_INSTALLOPTIONS_READ $R0 "external_${component}.ini" "Field 3" "State"
!insertmacro MUI_INSTALLOPTIONS_READ $R1 "external_${component}.ini" "Field 4" "HWND"
EnableWindow $R1 $R0
@ -127,18 +127,18 @@ External Components: MiKTeX, ImageMagick, Ghostscript
Push $R0
Push $R1
;Next button pressed?
#Next button pressed?
!insertmacro MUI_INSTALLOPTIONS_READ $R0 "external_${COMPONENT}.ini" "Settings" "State"
${if} $R0 != "0"
!insertmacro DialogExternalControl ${COMPONENT}
Abort
${endif}
;Download?
#Download?
!insertmacro MUI_INSTALLOPTIONS_READ $R0 "external_${COMPONENT}.ini" "Field 2" "State"
!insertmacro SetComponentState $R0 ${COMPONENT}
;Folder?
#Folder?
!insertmacro MUI_INSTALLOPTIONS_READ $R0 "external_${COMPONENT}.ini" "Field 3" "State"
${if} $R0 == "1"
@ -155,8 +155,8 @@ External Components: MiKTeX, ImageMagick, Ghostscript
!macroend
;--------------------------------
;Sections
#--------------------------------
#Sections
Section -LaTeX ExternalLaTeX
!insertmacro ExternalComponent LaTeX
@ -170,19 +170,19 @@ Section -Ghostscript ExternalGhostscript
!insertmacro ExternalComponent Ghostscript
SectionEnd
;--------------------------------
;Functions
#--------------------------------
#Functions
Function InitSizeExternal
;Get sizes of external component installers
#Get sizes of external component installers
SectionGetSize ${ExternalLaTeX} $SizeLaTeX
SectionGetSize ${ExternalImageMagick} $SizeImageMagick
SectionGetSize ${ExternalGhostscript} $SizeGhostscript
!ifndef SETUPTYPE_BUNDLE
;Add download size
#Add download size
IntOp $SizeLaTeX $SizeLaTeX + ${SIZE_DOWNLOAD_LATEX}
IntOp $SizeImagemagick $SizeImagemagick + ${SIZE_DOWNLOAD_IMAGEMAGICK}
IntOp $SizeGhostscript $SizeGhostscript + ${SIZE_DOWNLOAD_GHOSTSCRIPT}
@ -190,8 +190,8 @@ Function InitSizeExternal
FunctionEnd
;--------------------------------
;Page functions
#--------------------------------
#Page functions
Function PageExternalLaTeX
!insertmacro DialogExternalShow LaTeX

View File

@ -4,8 +4,8 @@ Selection of language for LyX interface
*/
;--------------------------------
;Macros
#--------------------------------
#Macros
!macro SetSystemLangItem VAR LANGNAME LANGISOCODE LANGID
@ -31,26 +31,26 @@ Selection of language for LyX interface
!macro GetISOLangCode VAR_LANGNAME VAR_LANGISOCODE
;Get the language code for the selected language name
#Get the language code for the selected language name
!insertmacro LanguageList '!insertmacro GetISOLangCodeItem ${VAR_LANGNAME} ${VAR_LANGISOCODE}'
!macroend
;--------------------------------
;Functions
#--------------------------------
#Functions
Function InitLanguage
;Set the default for the language selection dialog to the Windows language
#Set the default for the language selection dialog to the Windows language
System::Call "kernel32::GetUserDefaultUILanguage()i.R0"
!insertmacro SetSystemLang $R0
FunctionEnd
;--------------------------------
;Page functions
#--------------------------------
#Page functions
Function PageLanguage

View File

@ -4,12 +4,12 @@ Reinstall options
*/
;--------------------------------
;Page functions
#--------------------------------
#Page functions
Function PageReinstall
;Check whether this version is already installed
#Check whether this version is already installed
ReadRegStr $R0 SHELL_CONTEXT ${APP_REGKEY} "Version"

View File

@ -4,12 +4,12 @@ Uninstaller
*/
;--------------------------------
;Sections
#--------------------------------
#Sections
Section "un.Program Files" un.SecProgramFiles
;Binaries
#Binaries
Delete "$INSTDIR\bin\lyx.exe"
Delete "$INSTDIR\bin\lyxc.exe"
@ -26,51 +26,51 @@ Section "un.Program Files" un.SecProgramFiles
!insertmacro FileListPDFToolsBin Delete "$INSTDIR\bin\"
!insertmacro FileListPDFViewBin Delete "$INSTDIR\bin\"
;Icons
#Icons
!insertmacro FileListLyXIcons Delete "$INSTDIR\bin\"
;Resources
#Resources
RMDir /r "$INSTDIR\Resources"
;Components of Python
#Components of Python
RMDir /r "$INSTDIR\python"
;Aiksaurus Data
#Aiksaurus Data
!insertmacro FileListAiksaurusData Delete "$INSTDIR\aiksaurus\"
RMDir "$INSTDIR\aiksaurus"
;Helper DLLs for NSIS-based tools
#Helper DLLs for NSIS-based tools
!insertmacro FileListNSISPluginsStandard Delete "$INSTDIR\bin\"
!insertmacro FileListNSISPlugins Delete "$INSTDIR\bin\"
;Shortcuts
#Shortcuts
Delete "$SMPROGRAMS\${APP_NAME} ${APP_SERIES_NAME}.lnk"
Delete "$DESKTOP\${APP_NAME} ${APP_SERIES_NAME}.lnk"
;Uninstaller itself
#Uninstaller itself
Delete "$INSTDIR\${SETUP_UNINSTALLER}"
RMDir "$INSTDIR\bin"
;Application folder
#Application folder
SetOutPath "$PROGRAMFILES"
RMDir "$INSTDIR"
;Registry keys
#Registry keys
DeleteRegKey SHELL_CONTEXT "${APP_REGKEY_SETUP}"
DeleteRegKey SHELL_CONTEXT "${APP_REGKEY}"
DeleteRegKey SHELL_CONTEXT "Software\Classes\${APP_REGNAME_DOC}"
DeleteRegKey SHELL_CONTEXT "Software\Microsoft\Windows\CurrentVersion\Uninstall\${SETUP_UNINSTALLER_KEY}"
;File associations
#File associations
ReadRegStr $R0 SHELL_CONTEXT "Software\Classes\${APP_EXT}" ""

View File

@ -4,8 +4,8 @@ Install type setting (current user/all users)
*/
;--------------------------------
;Macros
#--------------------------------
#Macros
!macro GetDirExternal COMPONENT
@ -21,12 +21,12 @@ Install type setting (current user/all users)
!macroend
;--------------------------------
;Functions
#--------------------------------
#Functions
Function InitUser
;Get directories from registry
#Get directories from registry
ReadRegStr $R0 SHELL_CONTEXT "${APP_REGKEY}" ""
@ -38,13 +38,13 @@ Function InitUser
!insertmacro GetDirExternal ImageMagick
!insertmacro GetDirExternal Ghostscript
;Set directories in dialogs
#Set directories in dialogs
!insertmacro InitDialogExternalDir latex ${TRUE}
!insertmacro InitDialogExternalDir imagemagick ${FALSE}
!insertmacro InitDialogExternalDir ghostscript ${FALSE}
;Get LyX language
#Get LyX language
ReadRegStr $R0 SHELL_CONTEXT "${APP_REGKEY_SETUP}" "LyX Language"
@ -54,12 +54,12 @@ Function InitUser
FunctionEnd
;--------------------------------
;Page functions
#--------------------------------
#Page functions
Function PageUser
;Only show page if installing for all users is possible
#Only show page if installing for all users is possible
${if} $AdminOrPowerUser == ${FALSE}
Call InitUser
Abort

View File

@ -4,36 +4,36 @@ Option to download GSView (PDF/Postscript viewer)
*/
;--------------------------------
;Sections
#--------------------------------
#Sections
Section -Viewer ExternalViewer
!insertmacro ExternalComponent Viewer
SectionEnd
;--------------------------------
;Functions
#--------------------------------
#Functions
Function InitSizeViewer
;Get size of viewer installer
#Get size of viewer installer
SectionGetSize ${ExternalViewer} $SizeViewer
!ifndef SETUPTYPE_BUNDLE
;Add download size
#Add download size
IntOp $SizeViewer $SizeViewer + ${SIZE_DOWNLOAD_VIEWER}
!endif
FunctionEnd
;--------------------------------
;Page functions
#--------------------------------
#Page functions
Function PageViewer
;Show page if no viewer is installed, the user has Power User or Administrator priviledges and
;Ghostscript is installed or will be installed
#Show page if no viewer is installed, the user has Power User or Administrator priviledges and
#Ghostscript is installed or will be installed
${if} $AdminOrPowerUser == ${FALSE}
${orif} $PathViewer == "associated"
@ -53,7 +53,7 @@ FunctionEnd
Function PageViewerValidate
;Download?
#Download?
!insertmacro MUI_INSTALLOPTIONS_READ $R0 "viewer.ini" "Field 2" "State"
!insertmacro SetComponentState $R0 Viewer

View File

@ -7,8 +7,8 @@ Declarations
!include "settings.user.nsh"
!include "settings.nsh"
;--------------------------------
;Defines based on settings
#--------------------------------
#Defines based on settings
!ifndef SETUPTYPE_BUNDLE
!define SETUPTYPE_NAME DOWNLOAD
@ -16,8 +16,8 @@ Declarations
!define SETUPTYPE_NAME INSTALL
!endif
;--------------------------------
;Standard header files
#--------------------------------
#Standard header files
!include "MUI.nsh"
!include "LogicLib.nsh"
@ -27,15 +27,15 @@ Declarations
!include "Sections.nsh"
!include "WinVer.nsh"
;--------------------------------
;Windows constants
#--------------------------------
#Windows constants
!define SHCNE_ASSOCCHANGED 0x08000000
!define SHCNF_IDLIST 0x0000
;--------------------------------
;Reserve Files
;These files should come first in the compressed data (for faster GUI)
#--------------------------------
#Reserve Files
#These files should come first in the compressed data (for faster GUI)
ReserveFile "${NSISDIR}\Plugins\UserInfo.dll"
ReserveFile "dialogs\user.ini"
@ -45,8 +45,8 @@ ReserveFile "dialogs\langselect.ini"
!insertmacro MUI_RESERVEFILE_INSTALLOPTIONS
ReserveFile "${FILES_DVIPOST_PKG}\dvipost.sty"
;--------------------------------
;Variables
#--------------------------------
#Variables
Var AdminOrPowerUser
Var CurrentUserInstall
@ -71,8 +71,8 @@ Var LangISOCode
Var AspellHive
;--------------------------------
;Include standard functions
#--------------------------------
#Include standard functions
!insertmacro FUNCTION_STRING_StrStr
@ -80,12 +80,12 @@ Var AspellHive
!insertmacro VersionCompare
!insertmacro WordFind2X
;--------------------------------
;Macros
#--------------------------------
#Macros
!macro ReDef NAME VALUE
;Redefine a pre-processor definition
#Redefine a pre-processor definition
!ifdef `${NAME}`
!undef `${NAME}`
@ -97,7 +97,7 @@ Var AspellHive
!macro CallFunc FUNCTION INPUT VAROUT
;Calls a function that modifies a single value on the stack
#Calls a function that modifies a single value on the stack
Push ${INPUT}
Call ${FUNCTION}
@ -105,8 +105,8 @@ Var AspellHive
!macroend
;--------------------------------
;LyX installer header files
#--------------------------------
#LyX installer header files
!include "include\init.nsh"
!include "include\windows.nsh"

View File

@ -4,12 +4,12 @@ Detection functions for all components
*/
;--------------------------------
;Macros
#--------------------------------
#Macros
!macro SearchMiKTeX25
;Detect location of MiKTeX installation using initexmf
#Detect location of MiKTeX installation using initexmf
Push $R0
@ -44,19 +44,19 @@ Detection functions for all components
StrCpy $R1 0
"${Index}-Loop:"
;Check for key
#Check for key
EnumRegKey $R0 ${ROOT} "${MAIN_KEY}" "$R1"
StrCmp $R0 "" "${Index}-False"
IntOp $R1 $R1 + 1
StrCmp $R0 "${KEY}" "${Index}-True" "${Index}-Loop"
"${Index}-True:"
;Found
#Found
Push ${TRUE}
Goto "${Index}-End"
"${Index}-False:"
;Not found
#Not found
Push ${FALSE}
goto "${Index}-End"
@ -69,8 +69,8 @@ Detection functions for all components
!macroend
;--------------------------------
;Functions
#--------------------------------
#Functions
Function SearchAll
@ -85,7 +85,7 @@ FunctionEnd
Function TrimBackslash
;Trim a trailing backslash of a directory
#Trim a trailing backslash of a directory
Exch $R0
Push $R1
@ -148,7 +148,7 @@ FunctionEnd
Function DetectViewerByExtension
;Input on stack: file extension without dot
#Input on stack: file extension without dot
Exch $R0
Push $R1
@ -174,7 +174,7 @@ FunctionEnd
Function SearchLaTeX
;Search where MikTeX is installed
#Search where MikTeX is installed
!insertmacro SearchMiKTeX25
@ -194,12 +194,12 @@ FunctionEnd
Function SearchLaTeXLocalRoot
;Search for the MikTeX local root
;Returns value on stack
#Search for the MikTeX local root
#Returns value on stack
Push $R0
;MikTeX 2.5
#MikTeX 2.5
!insertmacro IfKeyExists HKCU "Software\MiKTeX.org\MiKTeX" "2.5"
Pop $R0
@ -213,7 +213,7 @@ Function SearchLaTeXLocalRoot
StrCpy $R0 "$APPDATA\MiKTeX\2.5"
${else}
;MiKTeX 2.4
#MiKTeX 2.4
ReadRegStr $R0 HKCU "Software\MiK\MiKTeX\CurrentVersion\MiKTeX" "Local Root"
@ -229,7 +229,7 @@ FunctionEnd
Function SearchGhostscript
;Search where Ghostscript is installed
#Search where Ghostscript is installed
Push $R0 ;Temp
Push $R1 ;Counter
@ -240,7 +240,7 @@ Function SearchGhostscript
StrCpy $R3 ""
StrCpy $R4 ""
;Check the latest version of AFPL Ghostscript installed
#Check the latest version of AFPL Ghostscript installed
StrCpy $R1 0
@ -258,7 +258,7 @@ Function SearchGhostscript
${loopuntil} $R2 == ""
;The same for GPL Ghostscript
#The same for GPL Ghostscript
StrCpy $R1 0
@ -276,18 +276,18 @@ Function SearchGhostscript
${loopuntil} $R2 == ""
;Take the latest one
#Take the latest one
${VersionCompare} $R3 $R4 $R0
${if} $R0 == "1"
;AFPL is newer
#AFPL is newer
ReadRegStr $PathGhostscript HKLM "Software\AFPL Ghostscript\$R3" "GS_DLL"
${else}
;GPL is newer or equal
#GPL is newer or equal
ReadRegStr $PathGhostscript HKLM "Software\GPL Ghostscript\$R4" "GS_DLL"
${endif}
;Trim the DLL filename to get the path
#Trim the DLL filename to get the path
${GetParent} $PathGhostscript $PathGhostscript
${unless} ${FileExists} "$PathGhostscript\${BIN_GHOSTSCRIPT}"
@ -304,7 +304,7 @@ FunctionEnd
Function SearchImageMagick
;Search where ImageMagick is installed
#Search where ImageMagick is installed
ReadRegStr $PathImageMagick HKLM "Software\ImageMagick\Current" "BinPath"
${unless} ${FileExists} "$PathImageMagick\${BIN_IMAGEMAGICK}"

View File

@ -4,17 +4,17 @@ Installer User Interface
*/
;--------------------------------
;General
#--------------------------------
#General
Name "${APP_NAME} ${APP_VERSION}"
BrandingText " "
;Default installation folder
#Default installation folder
InstallDir "${SETUP_DEFAULT_DIRECTORY}"
;--------------------------------
;Interface settings
#--------------------------------
#Interface settings
!define MUI_ABORTWARNING
!define MUI_ICON "${SETUP_ICON}"
@ -27,10 +27,10 @@ InstallDir "${SETUP_DEFAULT_DIRECTORY}"
!define MUI_CUSTOMFUNCTION_GUIINIT InitInterface
!define MUI_COMPONENTSPAGE_NODESC
;--------------------------------
;Pages
#--------------------------------
#Pages
;Installer
#Installer
!define MUI_WELCOMEPAGE_TITLE_3LINES
!define MUI_WELCOMEPAGE_TEXT $(TEXT_WELCOME_${SETUPTYPE_NAME})
@ -64,7 +64,7 @@ Page custom PageLanguage PageLanguageValidate
!define MUI_PAGE_CUSTOMFUNCTION_PRE CheckDesktopShortcut
!insertmacro MUI_PAGE_FINISH
;Uninstaller
#Uninstaller
!define MUI_WELCOMEPAGE_TITLE_3LINES
!define MUI_WELCOMEPAGE_TEXT $(UNTEXT_WELCOME)
@ -75,16 +75,16 @@ Page custom PageLanguage PageLanguageValidate
!insertmacro MUI_UNPAGE_FINISH
;--------------------------------
;Installer Languages
#--------------------------------
#Installer Languages
!insertmacro IncludeLang "english"
!insertmacro IncludeLang "french"
!insertmacro IncludeLang "german"
!insertmacro IncludeLang "italian"
;--------------------------------
;Version information
#--------------------------------
#Version information
VIProductVersion "${APP_VERSION_NUMBER}"
VIAddVersionKey /LANG=${LANG_ENGLISH} "ProductName" "${APP_NAME}"
@ -92,8 +92,8 @@ VIAddVersionKey /LANG=${LANG_ENGLISH} "FileDescription" "${APP_INFO}"
VIAddVersionKey /LANG=${LANG_ENGLISH} "FileVersion" "${APP_VERSION}"
VIAddVersionKey /LANG=${LANG_ENGLISH} "LegalCopyright" "${APP_COPYRIGHT}"
;--------------------------------
;Macros
#--------------------------------
#Macros
!macro InitDialogExternal COMPONENT CURRENTUSER_POSSIBLE
@ -143,14 +143,14 @@ VIAddVersionKey /LANG=${LANG_ENGLISH} "LegalCopyright" "${APP_COPYRIGHT}"
!macroend
;--------------------------------
;Functions
#--------------------------------
#Functions
Function InitDialogs
Push $R0
;Extract dialogs
#Extract dialogs
!insertmacro MUI_INSTALLOPTIONS_EXTRACT_AS "dialogs\user.ini" "user.ini"
!insertmacro MUI_INSTALLOPTIONS_EXTRACT_AS "dialogs\reinstall.ini" "reinstall.ini"
@ -160,7 +160,7 @@ Function InitDialogs
!insertmacro MUI_INSTALLOPTIONS_EXTRACT_AS "dialogs\viewer.ini" "viewer.ini"
!insertmacro MUI_INSTALLOPTIONS_EXTRACT_AS "dialogs\langselect.ini" "langselect.ini"
;Write texts
#Write texts
!insertmacro MUI_INSTALLOPTIONS_WRITE "user.ini" "Field 1" "Text" $(TEXT_USER_INFO)
!insertmacro MUI_INSTALLOPTIONS_WRITE "user.ini" "Field 2" "Text" $(TEXT_USER_ALL)
@ -182,7 +182,7 @@ Function InitDialogs
!insertmacro MUI_INSTALLOPTIONS_WRITE "langselect.ini" "Field 2" "ListItems" $R0
!insertmacro MUI_INSTALLOPTIONS_WRITE "langselect.ini" "Field 2" "State" "English" ;Default language
;Set state of user dialog
#Set state of user dialog
${if} $CurrentUserInstall == ${TRUE}
!insertmacro MUI_INSTALLOPTIONS_WRITE "user.ini" "Field 2" "State" "0"
!insertmacro MUI_INSTALLOPTIONS_WRITE "user.ini" "Field 3" "State" "1"

View File

@ -4,8 +4,8 @@ Installer and uninstaller initialization
*/
;--------------------------------
;Functions
#--------------------------------
#Functions
Function CommandLineParameter
@ -40,7 +40,7 @@ Function .onInit
Banner::show /NOUNLOAD "Checking system"
${endif}
;Check all dependencies
#Check all dependencies
Call CheckWindows
Call CheckPrivileges
@ -62,8 +62,8 @@ FunctionEnd
Function LoadInstaller
;Set the correct shell context depending on command line parameter
;and priviledges
#Set the correct shell context depending on command line parameter
#and priviledges
Push $R0
@ -83,8 +83,8 @@ Function LoadInstaller
${else}
;Display an error when the /AllUsers command line parameter is used
;by a user without Administrator or Power User priviledges
#Display an error when the /AllUsers command line parameter is used
#by a user without Administrator or Power User priviledges
Push "/AllUsers"
Call CommandLineParameter
@ -112,8 +112,8 @@ FunctionEnd
Function un.LoadUnInstaller
;Set the correct shell context depending on whether LyX has been installed
;for the current user or all users
#Set the correct shell context depending on whether LyX has been installed
#for the current user or all users
ReadRegStr $R0 HKCU ${APP_REGKEY} ""

View File

@ -6,8 +6,8 @@ Translations for installer and LyX itself
!macro LanguageList COMMAND
;List of supported LyX languages with ISO code and language identifier
;To be used as input for other macros
#List of supported LyX languages with ISO code and language identifier
#To be used as input for other macros
${COMMAND} "Bokmål" nb_NO 1044
${COMMAND} "Ceština" cs_CZ 1029
@ -38,7 +38,7 @@ Translations for installer and LyX itself
!macro LanguageStringAdd lang_name name
;Takes a define and puts that into a language string
#Takes a define and puts that into a language string
LangString "${name}" "${LANG_${lang_name}}" "${${name}}"
!undef "${name}"
@ -59,7 +59,7 @@ Translations for installer and LyX itself
!macro LanguageStringCreate lang_name
;Creates all language strings
#Creates all language strings
!insertmacro ReDef LanguageStringAdd '!insertmacro LanguageStringAdd "${lang_name}"'
${LanguageStringAdd} TEXT_NO_PRIVILEDGES
@ -126,7 +126,7 @@ Translations for installer and LyX itself
!define DICT_NAME $R1
!endif
;Include both NSIS/LyX language file
#Include both NSIS/LyX language file
!insertmacro MUI_LANGUAGE "${langname}"

View File

@ -4,8 +4,8 @@ Checks for Windows version
*/
;--------------------------------
;Macros
#--------------------------------
#Macros
!macro CheckPrivileges
@ -26,8 +26,8 @@ Checks for Windows version
!macroend
;--------------------------------
;Functions
#--------------------------------
#Functions
Function CheckPrivileges
!insertmacro CheckPrivileges
@ -39,7 +39,7 @@ FunctionEnd
Function CheckWindows
;Check for Windows NT 5.0 or later (2000, XP, 2003 etc.)
#Check for Windows NT 5.0 or later (2000, XP, 2003 etc.)
${unless} ${IsNT}
${andunless} ${AtLeastWin2000}
@ -55,7 +55,7 @@ Function UpdatePathEnvironment
Push $R0
Push $R1
;Updates the path environment variable of the instaler process to the latest system value
#Updates the path environment variable of the instaler process to the latest system value
ReadRegStr $R0 HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment" Path
ReadRegStr $R1 HKCU "Environment" Path

View File

@ -13,19 +13,19 @@ SetCompressor /SOLID lzma
!include "include\declarations.nsh"
;--------------------------------
;Compile the launcher
#--------------------------------
#Compile the launcher
!system '"${NSISDIR}\makensis.exe" "${FILES_LAUNCHER}\launcher.nsi"'
;--------------------------------
;Compile Windows PDF view helper
#--------------------------------
#Compile Windows PDF view helper
!system '"${NSISDIR}\makensis.exe" "${FILES_PDFVIEW}\pdfview.nsi"'
;--------------------------------
;LyX Installer, output file can be specified using command line option
; /DExeFile=/path/to/installer
#--------------------------------
#LyX Installer, output file can be specified using command line option
# /DExeFile=/path/to/installer
!ifdef ExeFile
!ifdef SETUPTYPE_BUNDLE
@ -37,8 +37,8 @@ OutFile "${ExeFile}"
Outfile "${SETUP_EXE}"
!endif
;--------------------------------
;Components
#--------------------------------
#Components
!include "components\core.nsh"
!include "components\user.nsh"

View File

@ -4,8 +4,8 @@ Settings for LyX installer
*/
;--------------------------------
;File locations
#--------------------------------
#File locations
!define FILES_LICENSE "license.rtf"
@ -28,8 +28,8 @@ Settings for LyX installer
!define FILES_NSISPLUGINS "${FILES_DEPS}\nsis"
;--------------------------------
;Locations of components to download
#--------------------------------
#Locations of components to download
!define DOWNLOAD_LATEX "http://superb-west.dl.sourceforge.net/sourceforge/miktex/basic-miktex-2.5.2580.exe"
!define DOWNLOAD_IMAGEMAGICK "http://superb-west.dl.sourceforge.net/sourceforge/imagemagick/ImageMagick-6.3.2-5-Q16-windows-dll.exe"
!define DOWNLOAD_GHOSTSCRIPT "http://superb-west.dl.sourceforge.net/sourceforge/ghostscript/gs854w32-gpl.exe"
@ -37,32 +37,32 @@ Settings for LyX installer
!define DOWNLOAD_ASPELLDICTS "ftp://ftp.lyx.org/pub/lyx/contrib/aspell6-windows"
;--------------------------------
;Download size (in KB)
#--------------------------------
#Download size (in KB)
!define SIZE_DOWNLOAD_LATEX 47271
!define SIZE_DOWNLOAD_IMAGEMAGICK 7096
!define SIZE_DOWNLOAD_GHOSTSCRIPT 12669
!define SIZE_DOWNLOAD_VIEWER 1459
;--------------------------------
;Approximations of space required for components (in KB)
#--------------------------------
#Approximations of space required for components (in KB)
!define SIZE_LATEX 120000
!define SIZE_IMAGEMAGICK 17000
!define SIZE_GHOSTSCRIPT 26000
!define SIZE_VIEWER 4000
;--------------------------------
;Locations of setup files for components (for bundled setup)
#--------------------------------
#Locations of setup files for components (for bundled setup)
!define INSTALL_LATEX "basic-miktex-2.5.2580.exe"
!define INSTALL_IMAGEMAGICK "ImageMagick-6.3.2-5-Q16-windows-dll.exe"
!define INSTALL_GHOSTSCRIPT "gs854w32-gpl.exe"
!define INSTALL_VIEWER "gsv48w32.exe"
;--------------------------------
;Names and version
#--------------------------------
#Names and version
!define APP_NAME "LyX"
!define /date APP_VERSION "1.5svn %Y%m%d"
@ -84,8 +84,8 @@ Settings for LyX installer
!define APP_EXT ".lyx"
!define APP_MIME_TYPE "application/lyx"
;--------------------------------
;Setup settings
#--------------------------------
#Setup settings
!ifndef SETUPTYPE_BUNDLE
!define /date SETUP_EXE "lyx-15svn-%Y%m%d.exe"
@ -100,14 +100,14 @@ Settings for LyX installer
!define SETUP_UNINSTALLER "Uninstall-${APP_NAME}.exe"
!define SETUP_UNINSTALLER_KEY "${APP_NAME}"
;--------------------------------
;Names of binaries to identify compontents
#--------------------------------
#Names of binaries to identify compontents
!define BIN_LATEX "tex.exe"
!define BIN_IMAGEMAGICK "convert.exe"
!define BIN_GHOSTSCRIPT "gswin32c.exe"
;--------------------------------
;Custom NSIS plug-ins
#--------------------------------
#Custom NSIS plug-ins
!addplugindir "${FILES_NSISPLUGINS}"

View File

@ -1,8 +1,8 @@
;LyX Windows Installer
;User Settings, all these macros can be redefined from command line,
;using options like /DFilesLyX="..\..\..\..\lyx-install"
#LyX Windows Installer
#User Settings, all these macros can be redefined from command line,
#using options like /DFilesLyX="..\..\..\..\lyx-install"
;Location of LyX files and dependencies
#Location of LyX files and dependencies
!ifdef FilesLyX
!define FILES_LYX "${FilesLyX}"
@ -22,7 +22,7 @@
!define FILES_BUNDLE "..\..\..\..\lyx-windows-bundle-deps"
!endif
;Location of Windows installation
#Location of Windows installation
!ifdef FilesWindows
!define FILES_WINDOWS "${FilesWindows}"
@ -30,7 +30,7 @@
!define FILES_WINDOWS "C:\WINDOWS"
!endif
;Location of Python 2.5
#Location of Python 2.5
!ifdef FilesPython
!define FILES_PYTHON "${FilesPython}"