dllmain
30th December 2007 19:20 UTC
Need help with NSIS 2.34 warning
I get this warning from NSIS 2.34:
Variable "mui.StartMenuPage.Create" not referenced or never set, wasting memory!
"StartMenuPage" is the page id I passed to MUI_PAGE_STARTMENU.
Any ideas what's wrong? Thanks in advance!
kichik
30th December 2007 20:10 UTC
What script caused that?
dllmain
30th December 2007 22:59 UTC
Originally posted by kichik
What script caused that?
Here's a minimal example giving this and only this warning.
OutFile not_referenced_case.exe
>!include "MUI2.nsh"
>var StartMenuFolder
>!insertmacro MUI_PAGE_STARTMENU "StartMenuPage" $StartMenuFolder
>!insertmacro MUI_PAGE_INSTFILES
>!insertmacro MUI_LANGUAGE "English"
>Section -dummy
SectionEnd
>
kichik
31st December 2007 18:15 UTC
Well, you don't use MUI_STARTMENU_WRITE_BEGIN, so it's a lacking script. But nonetheless, that warning could be avoided. Submit a bug report and I'll fix it for the next release.
dllmain
2nd January 2008 03:48 UTC
Originally posted by kichik
Well, you don't use MUI_STARTMENU_WRITE_BEGIN, so it's a lacking script.
Interesting, never heard of that before. I found it saves me manually writing $StartMenuFolder to the registry. Does it do anything more? I didn't find any documentation about it.
Is there a similar way to write $INSTALLDIR to the registry automatically?
Originally posted by kichik
But nonetheless, that warning could be avoided. Submit a bug report and I'll fix it for the next release.
Just opened a bug here:
http://sourceforge.net/tracker/index...49&atid=373085
Keep up the good work!
kichik
2nd January 2008 18:45 UTC
It's documented under the MUI documentation. If you define MUI_STARTMENUPAGE_REGISTRY_ROOT, MUI_STARTMENUPAGE_REGISTRY_KEY and
MUI_STARTMENUPAGE_REGISTRY_VALUENAME it will also write the selected value to the specified registry key.
dllmain
3rd January 2008 06:04 UTC
Originally posted by kichik
It's documented under the MUI documentation. If you define MUI_STARTMENUPAGE_REGISTRY_ROOT, MUI_STARTMENUPAGE_REGISTRY_KEY and
MUI_STARTMENUPAGE_REGISTRY_VALUENAME it will also write the selected value to the specified registry key.
Hm, I had that without MUI_STARTMENU_WRITE_BEGIN before and nothing was written to registry.
On
$INSTDIR again: I have to manually write it to the registry?
kichik
3rd January 2008 18:48 UTC
It'll be written and read for you, only if you use MUI_STARTMENU_WRITE_BEGIN and MUI_STARTMENU_WRITE_END.