installer: updates for LyX 1.6.2 and some bug fixes and optimizations

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/branches/BRANCH_1_6_X@28668 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Uwe Stöhr 2009-03-02 02:38:12 +00:00
parent 9d133e4a54
commit d98a88e9c7
6 changed files with 55 additions and 18 deletions

View File

@ -2,6 +2,9 @@
- LyX 1.6.2
- updated to Ghostscript 8.64
- updated to ImageMagick 6.4.9-7
- fix bug that some programs that were installed together with
LyX are not uninstalled together with LyX when the update
installer was used in the meantime
Version 4.17

View File

@ -160,13 +160,14 @@ Function InstDirChange
StrCpy $INSTDIR_OLD $INSTDIR
StrCpy $INSTDIR $INSTDIR_NEW
# set new PATH_PREFIX in the file lyxrc.dist
FileOpen $R1 "$INSTDIR\Resources\lyxrc.dist" a
FileRead $R1 $PathPrefix # the whole file content is now in $PathPrefix
${WordReplace} $PathPrefix "${PRODUCT_VERSION_OLD}" "LyX ${PRODUCT_VERSION}" "+" $PathPrefix
FileSeek $R1 0 # set file pointer to the beginning
FileWrite $R1 '$PathPrefix' # overwrite the existing path with the actual one
FileClose $R1
# set new path_prefix in the file lyxrc.dist
StrCpy $OldString "${PRODUCT_VERSION_OLD}"
StrCpy $NewString "LyX ${PRODUCT_VERSION}"
# following macro from TextFunc.nsh # calls Function ReplaceLineContent from LyXUtils.nsh
${LineFind} "$INSTDIR\Resources\lyxrc.dist" "" "1:-1" "ReplaceLineContent"
# this is only needed for this installer version 4.18 (delete it afterwards!)
StrCpy $OldString "LyX 1.6.0"
${LineFind} "$INSTDIR\Resources\lyxrc.dist" "" "1:-1" "ReplaceLineContent"
# set the new path to the preferences file for all users
StrCpy $FileName "preferences"
@ -201,27 +202,57 @@ Function RefreshRegUninst
# Aspell
ReadRegStr $0 SHCTX "Software\Aspell" "OnlyWithLyX" # special entry to test if it was installed with LyX
${if} $0 == "Yes${PRODUCT_VERSION_SHORT}"
${if} $0 == "Yes${PRODUCT_VERSION_SHORT_OLD}"
# this is only needed for this installer version 4.18 (delete it afterwards!)
${orif} $0 == "Yes160"
WriteRegStr HKLM "SOFTWARE\Aspell" "OnlyWithLyX" "Yes${PRODUCT_VERSION_SHORT}"
${endif}
# Metafile2eps
Var /GLOBAL RegLocation
StrCpy $RegLocation "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Metafile to EPS Converter"
ReadRegStr $0 SHCTX "$RegLocation" "OnlyWithLyX"
${if} $0 == "Yes${PRODUCT_VERSION_SHORT_OLD}"
# this is only needed for this installer version 4.18 (delete it afterwards!)
${orif} $0 == "Yes160"
WriteRegStr HKLM "$RegLocation" "OnlyWithLyX" "Yes${PRODUCT_VERSION_SHORT}"
# set the new path
ReadRegStr $0 HKLM "SOFTWARE\InkNote Selector" ""
${WordReplace} $0 "${PRODUCT_VERSION_OLD}" "LyX ${PRODUCT_VERSION}" "+" $0 # macro from WordFunc.nsh
WriteRegStr HKLM "SOFTWARE\InkNote Selector" "" "$0"
ReadRegStr $0 HKLM "$RegLocation" "InstallLocation"
${WordReplace} $0 "${PRODUCT_VERSION_OLD}" "LyX ${PRODUCT_VERSION}" "+" $0
WriteRegStr HKLM "$RegLocation" "InstallLocation" "$0"
# this is only needed for this installer version 4.18 (delete it afterwards!)
ReadRegStr $0 HKLM "SOFTWARE\InkNote Selector" ""
${WordReplace} $0 "LyX 1.6.0" "LyX ${PRODUCT_VERSION}" "+" $0
WriteRegStr HKLM "SOFTWARE\InkNote Selector" "" "$0"
ReadRegStr $0 HKLM "$RegLocation" "InstallLocation"
${WordReplace} $0 "LyX 1.6.0" "LyX ${PRODUCT_VERSION}" "+" $0
WriteRegStr HKLM "$RegLocation" "InstallLocation" "$0"
${endif}
# MiKTeX
ReadRegStr $0 HKLM "SOFTWARE\MiKTeX.org\MiKTeX" "OnlyWithLyX"
${if} $0 == "Yes${PRODUCT_VERSION_SHORT}"
${if} $0 == "Yes${PRODUCT_VERSION_SHORT_OLD}"
# this is only needed for this installer version 4.18 (delete it afterwards!)
${orif} $0 == "Yes160"
WriteRegStr HKLM "SOFTWARE\MiKTeX.org\MiKTeX" "OnlyWithLyX" "Yes${PRODUCT_VERSION_SHORT}"
${endif}
# JabRef
ReadRegStr $0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\JabRef ${JabRefVersion}" "OnlyWithLyX"
${if} $0 == "Yes${PRODUCT_VERSION_SHORT}"
${if} $0 == "Yes${PRODUCT_VERSION_SHORT_OLD}"
# this is only needed for this installer version 4.18 (delete it afterwards!)
${orif} $0 == "Yes160"
WriteRegStr HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\JabRef ${JabRefVersion}" "OnlyWithLyX" "Yes${PRODUCT_VERSION_SHORT}"
${endif}
# Aiksaurus
ReadRegStr $0 SHCTX "Software\Aiksaurus" "OnlyWithLyX" # special entry to test if it was installed with LyX
${if} $0 == "Yes${PRODUCT_VERSION_SHORT_OLD}"
WriteRegStr HKLM "SOFTWARE\Aiksaurus" "OnlyWithLyX" "Yes${PRODUCT_VERSION_SHORT}"
${endif}
# Aiksaurus currently not needed
#ReadRegStr $0 SHCTX "Software\Aiksaurus" "OnlyWithLyX"
#${if} $0 == "Yes${PRODUCT_VERSION_SHORT_OLD}"
# WriteRegStr HKLM "SOFTWARE\Aiksaurus" "OnlyWithLyX" "Yes${PRODUCT_VERSION_SHORT}"
#${endif}
# ImageMagick
ReadRegStr $0 SHCTX "Software\ImageMagick" "OnlyWithLyX"

View File

@ -94,14 +94,16 @@ Function Metafile2eps
# restore DEVMODE with proper settings
ExecWait '$PrinterConf /q /Sr /n "Metafile to EPS Converter" /a "$INSTDIR\metafile2eps.dat" g'
# register printer
WriteRegStr HKLM "Software\InkNote Selector" "" ${Metafile2epsDir}
WriteRegStr HKLM "SOFTWARE\InkNote Selector" "" ${Metafile2epsDir}
# register Metafile2eps
Var /GLOBAL RegLocation
StrCpy $RegLocation "Software\Microsoft\Windows\CurrentVersion\Uninstall\Metafile to EPS Converter"
StrCpy $RegLocation "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Metafile to EPS Converter"
WriteRegStr HKLM "$RegLocation" "InstallLocation" "${Metafile2epsDir}"
WriteRegStr HKLM "$RegLocation" "DisplayName" "Metafile to EPS Converter"
WriteRegStr HKLM "$RegLocation" "OnlyWithLyX" "Yes${PRODUCT_VERSION_SHORT}" # special entry to tell the uninstaller that it was installed with LyX
StrCpy $WMFPath "${Metafile2epsDir}"
# delete temporary file
Delete "$INSTDIR\metafile2eps.dat"
${else}
# delete unnecessary files
RMDir /r "${Metafile2epsDir}"

View File

@ -55,6 +55,7 @@ Var MiKTeXVersion
Var MiKTeXUser
Var MiKTeXPath
Var MissedProg
Var PathPrefix
Var PSVPath
Var SVGPath
Var WMFPath

View File

@ -52,6 +52,7 @@ Var LaTeXName
Var MiKTeXVersion
Var MiKTeXUser
Var MissedProg
Var PathPrefix
Var PSVPath
Var State
Var SVGPath

View File

@ -20,7 +20,6 @@ Var LatexPath
Var MiKTeXInstalled
Var NewString
Var OldString
Var PathPrefix
Var Pointer
Var PrinterConf
Var ProductRootKey