Skip to contentSkip to conversation

nsis: Add QEMU version information to Windows registry

PATCH New Stefan Weil 1 participant 1 message May 14, 2015 Kbuild

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 nsis: Add QEMU version information to Windows registry

The uninstall keys include an option key "DisplayVersion" which we set now. By default the version value is read from file VERSION, but it is also possible to pass VERSION=#.#.# to make.

---
 Makefile | 1 +
 qemu.nsi | 3 +++
 2 files changed, 4 insertions(+)
Makefile +1 -0
index f032158..367be32 100644
@@ -574,6 +574,7 @@ endif # SIGNCODE
                 $(if $(DLL_PATH),-DDLLDIR="$(DLL_PATH)") \
                 -DSRCDIR="$(SRC_PATH)" \
                 -DOUTFILE="$(INSTALLER)" \
+                -DDISPLAYVERSION="$(VERSION)" \
                 $(SRC_PATH)/qemu.nsi
 	rm -r ${INSTDIR}
 ifdef SIGNCODE
qemu.nsi +3 -0
index cc5fafd..a20f6ef 100644
@@ -139,6 +139,9 @@ Section "${PRODUCT} (required)"
 
     ; Write the uninstall keys for Windows
     WriteRegStr HKLM "${UNINST_KEY}" "DisplayName" "QEMU"
+!ifdef DISPLAYVERSION
+    WriteRegStr HKLM "${UNINST_KEY}" "DisplayVersion" "${DISPLAYVERSION}"
+!endif
     WriteRegStr HKLM "${UNINST_KEY}" "UninstallString" '"${UNINST_EXE}"'
     WriteRegDWORD HKLM "${UNINST_KEY}" "NoModify" 1
     WriteRegDWORD HKLM "${UNINST_KEY}" "NoRepair" 1
Signature · 1 line
2.1.4