installer: fix an issue

- also take care of emergency releases when updating LyX
- add some prerequisites for a new feature
This commit is contained in:
Uwe Stöhr 2013-05-03 01:11:32 +02:00
parent 9c749331a0
commit 81539ec435
2 changed files with 13 additions and 1 deletions

View File

@ -611,6 +611,15 @@ Function .onInit
Abort
${endif}
# FIXME: check that LyX is not currently running
#System::Call 'kernel32::CreateMutexA(i 0, i 0, t "LyX.exe.Instance") i .r1 ?e'
#Pop $R0
#MessageBox MB_OK "$R0"
#${if} $R0 != "0"
# MessageBox MB_OK|MB_ICONSTOP "$(LyXRunning)"
# Abort
#${endif}
!insertmacro MULTIUSER_INIT
# check if this LyX version is already installed
@ -653,6 +662,7 @@ Function .onInit
# we don't stop here because we want the latest installed version
${endif}
${next}
${if} $OldVersionNumber > ${APP_SERIES_KEY}
# store the version number and reformat it temporarily for the error message
StrCpy $R0 $OldVersionNumber

View File

@ -54,6 +54,8 @@ Section -InstallData
# if we install over an existing version, remove the old uninstaller information
${if} $OldVersionNumber != ""
DeleteRegKey SHCTX "Software\Microsoft\Windows\CurrentVersion\Uninstall\${APP_NAME}$OldVersionNumber"
# also delete in the case of an emergency release
DeleteRegKey SHCTX "Software\Microsoft\Windows\CurrentVersion\Uninstall\${APP_NAME}$OldVersionNumber1"
${endif}
SectionEnd