This is my first time using NSIS and I'm trying to make an installer that uses MUI2, but it's not going too smoothly. When I compile my code I don't get any errors, so it compiles, but I get a truckload of warnings. First it happened with a slightly complex installer, but I even made a super-simple one (still using MUI2) and I still get the same errors.
This is the resulting log:
MakeNSIS v2.46 - Copyright 1995-2009 Contributors
See the file COPYING for license details.
Credits can be found in the Users Manual.
Processing config:
Processing plugin dlls: "F:\Sami\Applications\NSIS\Plugins\*.dll"
- AdvSplash::show
- Banner::destroy
- Banner::getWindow
- Banner::show
- BgImage::AddImage
- BgImage::AddText
- BgImage::Clear
- BgImage::Destroy
- BgImage::Redraw
- BgImage::SetBg
- BgImage::SetReturn
- BgImage::Sound
- Dialer::AttemptConnect
- Dialer::AutodialHangup
- Dialer::AutodialOnline
- Dialer::AutodialUnattended
- Dialer::GetConnectedState
- InstallOptions::dialog
- InstallOptions::initDialog
- InstallOptions::show
- LangDLL::LangDialog
- Math::Script
- NSISdl::download
- NSISdl::download_quiet
- Splash::show
- StartMenu::Init
- StartMenu::Select
- StartMenu::Show
- System::Alloc
- System::Call
- System::Copy
- System::Free
- System::Get
- System::Int64Op
- System::Store
- TypeLib::GetLibVersion
- TypeLib::Register
- TypeLib::UnRegister
- UserInfo::GetAccountType
- UserInfo::GetName
- UserInfo::GetOriginalAccountType
- VPatch::GetFileCRC32
- VPatch::GetFileMD5
- VPatch::vpatchfile
- nsDialogs::Create
- nsDialogs::CreateControl
- nsDialogs::CreateItem
- nsDialogs::CreateTimer
- nsDialogs::GetUserData
- nsDialogs::KillTimer
- nsDialogs::OnBack
- nsDialogs::OnChange
- nsDialogs::OnClick
- nsDialogs::OnNotify
- nsDialogs::SelectFileDialog
- nsDialogs::SelectFolderDialog
- nsDialogs::SetRTL
- nsDialogs::SetUserData
- nsDialogs::Show
- nsExec::Exec
- nsExec::ExecToLog
- nsExec::ExecToStack
!define: "MUI_INSERT_NSISCONF"=""
Changing directory to: "F:\Sami\Games\Mightier\Even Mightier Installer"
Processing script file: "F:\Sami\Games\Mightier\Even Mightier Installer\Even Mightier.nsi"
!include: "F:\Sami\Applications\NSIS\Include\MUI2.nsh"
!include: "F:\Sami\Applications\NSIS\Contrib\Modern UI 2\MUI2.nsh"
NSIS Modern User Interface version 2.0 - Copyright 2002-2009 Joost Verburg (F:\Sami\Applications\NSIS\Contrib\Modern UI 2\MUI2.nsh:8)
!define: "MUI_INCLUDED"=""
!define: "MUI_SYSVERSION"="2.0"
!define: "MUI_VERBOSE"="3"
!include: closed: "F:\Sami\Applications\NSIS\Contrib\Modern UI 2\MUI2.nsh"
!include: closed: "F:\Sami\Applications\NSIS\Include\MUI2.nsh"
!include: "F:\Sami\Applications\NSIS\Include\LogicLib.nsh"
!include: closed: "F:\Sami\Applications\NSIS\Include\LogicLib.nsh"
!include: "F:\Sami\Applications\NSIS\Include\Sections.nsh"
!include: closed: "F:\Sami\Applications\NSIS\Include\Sections.nsh"
Name: "Even Mightier Setup"
OutFile: "EvenMightier_v1.0Setup.exe"
InstallDir: "$PROGRAMFILES\Mightier\"
!define: "MUI_FINISHPAGE_NOAUTOCLOSE"=""
!define: "MUI_UNFINISHPAGE_NOAUTOCLOSE"=""
!define: "MUI_ABORTWARNING"=""
!define: "MUI_ABORTWARNING_TEXT"="Are you sure you want to stop installing Even Mightier?"
!define: "MUI_ABORTWARNING_CANCEL_DEFAULT"=""
!define: "MUI_UNABORTWARNING"=""
!define: "MUI_UNABORTWARNING_TEXT"="Are you sure you want to stop uninstalling Even Mightier?"
!define: "MUI_UNABORTWARNING_CANCEL_DEFAULT"=""
!define: "MUI_DIRECTORYPAGE_VERIFYONLEAVE"=""
!define: "MUI_WELCOMEPAGE_TEXT"="This installer will install Even Mightier, an expansion for Mightier. It is recommended that you do not have Mightier open during the installation."
!insertmacro: MUI_PAGE_WELCOME
!insertmacro: end of MUI_PAGE_WELCOME
!insertmacro: MUI_PAGE_COMPONENTS
!insertmacro: end of MUI_PAGE_COMPONENTS
!define: "MUI_PAGE_CUSTOMFUNCTION_LEAVE"="LeaveDirectory"
!insertmacro: MUI_PAGE_DIRECTORY
!insertmacro: end of MUI_PAGE_DIRECTORY
!insertmacro: MUI_PAGE_INSTFILES
!insertmacro: end of MUI_PAGE_INSTFILES
!insertmacro: MUI_PAGE_FINISH
!insertmacro: end of MUI_PAGE_FINISH
!insertmacro: MUI_UNPAGE_WELCOME
!insertmacro: end of MUI_UNPAGE_WELCOME
!define: "MUI_UNCONFIRMPAGE_TEXT_LOCATION"="Please select the directory where Mightier is installed."
!insertmacro: MUI_UNPAGE_CONFIRM
!insertmacro: end of MUI_UNPAGE_CONFIRM
!insertmacro: MUI_UNPAGE_INSTFILES
!insertmacro: end of MUI_UNPAGE_INSTFILES
!insertmacro: MUI_UNPAGE_FINISH
!insertmacro: end of MUI_UNPAGE_FINISH
Section: "Separate Install" ->(SepInstall)
WriteUninstaller: "Uninstall.exe"
SectionEnd
Section: "Overwrite Install" ->(OverInstall)
WriteUninstaller: "Uninstall.exe"
SectionEnd
Function: "LeaveDirectory"
!insertmacro: _Switch
!insertmacro: end of _Switch
!insertmacro: _Case
!insertmacro: end of _Case
MessageBox: 0: "Directory does not exist!"
Abort: ""
!insertmacro: _Goto
!insertmacro: end of _Goto
!insertmacro: _Case
!insertmacro: end of _Case
MessageBox: 0: "There is not enough free space on the drive."
Abort: ""
!insertmacro: _Goto
!insertmacro: end of _Goto
!insertmacro: _EndSwitch
!insertmacro: end of _EndSwitch
FunctionEnd
Function: ".onInit"
StrCpy $1 "0" () ()
FunctionEnd
Function: ".onSelChange"
!insertmacro: StartRadioButtons
!define: "StartRadioButtons_Var"="$1"
Push: $R0
SectionGetFlags: $1->$R0
IntOp: $R0=$R0&0xFFFFFFFE
SectionSetFlags: $1->$R0
Push: $R1
StrCpy $R1 "$1" () ()
!insertmacro: end of StartRadioButtons
!insertmacro: RadioButton
SectionGetFlags: 0->$R0
IntOp: $R0=$R0&1
IntCmp $R0:1 equal=0, < +2, > +2
StrCpy $1 "0" () ()
!insertmacro: end of RadioButton
!insertmacro: RadioButton
SectionGetFlags: 1->$R0
IntOp: $R0=$R0&1
IntCmp $R0:1 equal=0, < +2, > +2
StrCpy $1 "1" () ()
!insertmacro: end of RadioButton
!insertmacro: EndRadioButtons
StrCmp "$R1" "$1" equal=0, nonequal=+4
SectionGetFlags: $1->$R0
IntOp: $R0=$R0|1
SectionSetFlags: $1->$R0
Pop: $R1
Pop: $R0
!undef: "StartRadioButtons_Var"
!insertmacro: end of EndRadioButtons
FunctionEnd
Processed 1 file, writing output:
Adding plug-ins initializing function... Done!
warning: uninstall function "un.mui.FinishPage.GUIInit" not referenced - zeroing code (165-170) out
warning: install function "mui.FinishPage.GUIInit" not referenced - zeroing code (188-193) out
Processing pages... Done!
Removing unused resources... Done!
Generating language tables... warning: LangString "MUI_TEXT_WELCOME_INFO_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_COMPONENTS_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_COMPONENTS_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_INNERTEXT_COMPONENTS_DESCRIPTION_TITLE" is not set in language table of language 1033
warning: LangString "MUI_INNERTEXT_COMPONENTS_DESCRIPTION_INFO" is not set in language table of language 1033
warning: LangString "MUI_TEXT_DIRECTORY_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_DIRECTORY_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_INSTALLING_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_INSTALLING_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_ABORT_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_ABORT_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_BUTTONTEXT_FINISH" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_INFO_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_INFO_REBOOT" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_REBOOTNOW" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_REBOOTLATER" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_INFO_TEXT" is not set in language table of language 1033
warning: LangString "MUI_TEXT_WELCOME_INFO_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_COMPONENTS_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_COMPONENTS_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_INNERTEXT_COMPONENTS_DESCRIPTION_TITLE" is not set in language table of language 1033
warning: LangString "MUI_INNERTEXT_COMPONENTS_DESCRIPTION_INFO" is not set in language table of language 1033
warning: LangString "MUI_TEXT_DIRECTORY_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_DIRECTORY_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_INSTALLING_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_INSTALLING_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_ABORT_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_ABORT_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_BUTTONTEXT_FINISH" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_INFO_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_INFO_REBOOT" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_REBOOTNOW" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_REBOOTLATER" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_INFO_TEXT" is not set in language table of language 1033
warning: LangString "MUI_TEXT_WELCOME_INFO_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_COMPONENTS_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_COMPONENTS_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_INNERTEXT_COMPONENTS_DESCRIPTION_TITLE" is not set in language table of language 1033
warning: LangString "MUI_INNERTEXT_COMPONENTS_DESCRIPTION_INFO" is not set in language table of language 1033
warning: LangString "MUI_TEXT_DIRECTORY_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_DIRECTORY_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_INSTALLING_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_INSTALLING_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_ABORT_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_ABORT_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_BUTTONTEXT_FINISH" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_INFO_TITLE" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_INFO_REBOOT" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_REBOOTNOW" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_REBOOTLATER" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_INFO_TEXT" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_WELCOME_INFO_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_WELCOME_INFO_TEXT" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_CONFIRM_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_CONFIRM_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_UNINSTALLING_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_UNINSTALLING_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_FINISH_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_FINISH_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_ABORT_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_ABORT_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_BUTTONTEXT_FINISH" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_FINISH_INFO_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_FINISH_INFO_REBOOT" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_REBOOTNOW" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_REBOOTLATER" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_FINISH_INFO_TEXT" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_WELCOME_INFO_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_WELCOME_INFO_TEXT" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_CONFIRM_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_CONFIRM_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_UNINSTALLING_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_UNINSTALLING_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_FINISH_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_FINISH_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_ABORT_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_ABORT_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_BUTTONTEXT_FINISH" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_FINISH_INFO_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_FINISH_INFO_REBOOT" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_REBOOTNOW" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_REBOOTLATER" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_FINISH_INFO_TEXT" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_WELCOME_INFO_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_WELCOME_INFO_TEXT" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_CONFIRM_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_CONFIRM_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_UNINSTALLING_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_UNINSTALLING_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_FINISH_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_FINISH_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_ABORT_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_ABORT_SUBTITLE" is not set in language table of language 1033
warning: LangString "MUI_BUTTONTEXT_FINISH" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_FINISH_INFO_TITLE" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_FINISH_INFO_REBOOT" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_REBOOTNOW" is not set in language table of language 1033
warning: LangString "MUI_TEXT_FINISH_REBOOTLATER" is not set in language table of language 1033
warning: LangString "MUI_UNTEXT_FINISH_INFO_TEXT" is not set in language table of language 1033
Done!
warning: Variable "mui.Header.Text" not referenced or never set, wasting memory!
warning: Variable "mui.Header.Text.Font" not referenced or never set, wasting memory!
warning: Variable "mui.Header.SubText" not referenced or never set, wasting memory!
warning: Variable "mui.Header.Background" not referenced or never set, wasting memory!
warning: Variable "mui.Header.Image" not referenced or never set, wasting memory!
warning: Variable "mui.Branding.Text" not referenced or never set, wasting memory!
warning: Variable "mui.Branding.Background" not referenced or never set, wasting memory!
warning: Variable "mui.Line.Standard" not referenced or never set, wasting memory!
warning: Variable "mui.Line.FullWindow" not referenced or never set, wasting memory!
warning: Variable "mui.Button.Next" not referenced or never set, wasting memory!
warning: Variable "mui.Button.Cancel" not referenced or never set, wasting memory!
warning: Variable "mui.Button.Back" not referenced or never set, wasting memory!
Generating uninstaller... Done!
Output: "F:\Sami\Games\Mightier\Even Mightier Installer\EvenMightier_v1.0Setup.exe"
Install: 6 pages (384 bytes), 2 sections (2096 bytes), 436 instructions (12208 bytes), 155 strings (2342 bytes), 1 language table (322 bytes).
Uninstall: 5 pages (320 bytes),
0 sections (0 bytes), 374 instructions (10472 bytes), 129 strings (1728 bytes), 1 language table (282 bytes).
Datablock optimizer saved 21677 bytes (~19.8%).
Using zlib compression.
EXE header size: 50176 / 35840 bytes
Install code: 3013 / 17704 bytes
Install data: 12605 / 114468 bytes
Uninstall code+data: 24559 / 28918 bytes
CRC (0x425A3F9F): 4 / 4 bytes
Total size: 90357 / 196934 bytes (45.8%)
46 warnings:
uninstall function "un.mui.FinishPage.GUIInit" not referenced - zeroing code (165-170) out
install function "mui.FinishPage.GUIInit" not referenced - zeroing code (188-193) out
LangString "MUI_TEXT_WELCOME_INFO_TITLE" is not set in language table of language 1033
LangString "MUI_TEXT_COMPONENTS_TITLE" is not set in language table of language 1033
LangString "MUI_TEXT_COMPONENTS_SUBTITLE" is not set in language table of language 1033
LangString "MUI_INNERTEXT_COMPONENTS_DESCRIPTION_TITLE" is not set in language table of language 1033
LangString "MUI_INNERTEXT_COMPONENTS_DESCRIPTION_INFO" is not set in language table of language 1033
LangString "MUI_TEXT_DIRECTORY_TITLE" is not set in language table of language 1033
LangString "MUI_TEXT_DIRECTORY_SUBTITLE" is not set in language table of language 1033
LangString "MUI_TEXT_INSTALLING_TITLE" is not set in language table of language 1033
LangString "MUI_TEXT_INSTALLING_SUBTITLE" is not set in language table of language 1033
LangString "MUI_TEXT_FINISH_TITLE" is not set in language table of language 1033
LangString "MUI_TEXT_FINISH_SUBTITLE" is not set in language table of language 1033
LangString "MUI_TEXT_ABORT_TITLE" is not set in language table of language 1033
LangString "MUI_TEXT_ABORT_SUBTITLE" is not set in language table of language 1033
LangString "MUI_BUTTONTEXT_FINISH" is not set in language table of language 1033
LangString "MUI_TEXT_FINISH_INFO_TITLE" is not set in language table of language 1033
LangString "MUI_TEXT_FINISH_INFO_REBOOT" is not set in language table of language 1033
LangString "MUI_TEXT_FINISH_REBOOTNOW" is not set in language table of language 1033
LangString "MUI_TEXT_FINISH_REBOOTLATER" is not set in language table of language 1033
LangString "MUI_TEXT_FINISH_INFO_TEXT" is not set in language table of language 1033
LangString "MUI_UNTEXT_WELCOME_INFO_TITLE" is not set in language table of language 1033
LangString "MUI_UNTEXT_WELCOME_INFO_TEXT" is not set in language table of language 1033
LangString "MUI_UNTEXT_CONFIRM_TITLE" is not set in language table of language 1033
LangString "MUI_UNTEXT_CONFIRM_SUBTITLE" is not set in language table of language 1033
LangString "MUI_UNTEXT_UNINSTALLING_TITLE" is not set in language table of language 1033
LangString "MUI_UNTEXT_UNINSTALLING_SUBTITLE" is not set in language table of language 1033
LangString "MUI_UNTEXT_FINISH_TITLE" is not set in language table of language 1033
LangString "MUI_UNTEXT_FINISH_SUBTITLE" is not set in language table of language 1033
LangString "MUI_UNTEXT_ABORT_TITLE" is not set in language table of language 1033
LangString "MUI_UNTEXT_ABORT_SUBTITLE" is not set in language table of language 1033
LangString "MUI_UNTEXT_FINISH_INFO_TITLE" is not set in language table of language 1033
LangString "MUI_UNTEXT_FINISH_INFO_REBOOT" is not set in language table of language 1033
LangString "MUI_UNTEXT_FINISH_INFO_TEXT" is not set in language table of language 1033
Variable "mui.Header.Text" not referenced or never set, wasting memory!
Variable "mui.Header.Text.Font" not referenced or never set, wasting memory!
Variable "mui.Header.SubText" not referenced or never set, wasting memory!
Variable "mui.Header.Background" not referenced or never set, wasting memory!
Variable "mui.Header.Image" not referenced or never set, wasting memory!
Variable "mui.Branding.Text" not referenced or never set, wasting memory!
Variable "mui.Branding.Background" not referenced or never set, wasting memory!
Variable "mui.Line.Standard" not referenced or never set, wasting memory!
Variable "mui.Line.FullWindow" not referenced or never set, wasting memory!
Variable "mui.Button.Next" not referenced or never set, wasting memory!
Variable "mui.Button.Cancel" not referenced or never set, wasting memory!
Variable "mui.Button.Back" not referenced or never set, wasting memory!
In addition, no image displays on the left side of either the welcome or finish page, although I suspect that's connected to the above warnings.
Basically, I'd like to know what the problem is and how I should fix it. If anybody needs the code of my .nsi file please say and I'll add it to the question.
I'm running Windows 7 Home Premium (if that helps) and using the latest version of NSIS (2.46).
Well, I took a careful look at an example and saw that I hadn't inserted the MUI_LANGUAGE macro in my code, which I didn't know was required. It fixed both the warnings and the disappearing welcome/finish images.
In my opinion it's kind of strange that it's required, but that's how it is anyway. Hope this helps anyone with the same problem.
Related
I create Windows installers under Linux with the help of the program "makensis". Recently I updated the Linux machine from Debian 9 to Debian 11, which brought an upgrade of NSIS from version 2.51 to 3.04..
Since then my script to create the installer does not compile anymore. The script is generated from a build environment and I know that other people have it running on Debian 11, so it seems to be due to my environment rather than syntactical errors in the script.
If I test install NSIS 2.51 from Debian 9, the script runs without problems.
The script should create installers in English and German, if I comment out the German entries, it also works.
I have checked the syntax several times and am now at a loss.
Output of the error (shortened):
makensis -V4 ./work/XXX/XXX.nsi
MakeNSIS v3.06.1-1 - Copyright 1999-2020 Contributors
See the file COPYING for license details.
Credits can be found in the Users Manual.
Processing config: /etc/nsisconf.nsh
....
!insertmacro: MUI_LANGUAGE
!insertmacro: end of MUI_LANGUAGE
LangString: "INWpTitle" 1033 "Installation of XXX"
LangString: "INWpTitle" 1031 "Installation der XXX"
LangString: "INWpText" 1033 "This Wizard will be guiding you through the installation of XXX.
Before installation BaseCamp must be closed for allowing installation of the map data.
Choose Next for starting the installation."
LangString: "INWpText" 1031 "Dieser Assistent wird Sie durch die Installation der XXX begleiten.
Vor der Installation muss das Programm BaseCamp geschlossen werden damit Kartendateien ersetzt werden koennen.
Klicken Sie auf Weiter um mit der Installation zu beginnen."
LicenseLangString: "licenseFile" 1033 "XXX.nsis.license.en"
LicenseLangString: wchar_t conversion failed!
Error in script "./work/XXX/XXX.nsi" on line 114 -- aborting creation process
Content of XXX.nsi
105 !insertmacro MUI_LANGUAGE "English"
106 !insertmacro MUI_LANGUAGE "German"
...
113 LicenseLangString licenseFile ${LANG_ENGLISH} "XXX.nsis.license.en"
114 LicenseLangString licenseFile ${LANG_GERMAN} "XXX.nsis.license.de"
On non-Windows systems, iconv is used to convert the license file in NSIS 3 and there is something in that file it does not like.
You can
A) Convert the license file to RTF format.
B) Convert the license file to UTF-8 or UTF-16LE and make sure the file starts with a BOM/Signature.
How to show the End-User License Agreement ("EULA") in the license agreement screen based on the language or locale.
Below is the line of code to show the license agreement in the License Agreement screen. But it is showing only in English.
!insertmacro MUI_PAGE_LICENSE "C:\Program Files (x86)\NSIS\Docs\Modern UI\license.rtf"
I placed all other language license.rtf files in a common folder. And then when i am trying to write
${If} $Language == 1033
!insertmacro MUI_PAGE_LICENSE "C:\Program Files (x86)\NSIS\Docs\Modern UI\license.rtf"
${EndIf}
It is showing the compilation error "Error: command StrCmp not valid outside Section or Function"
The MUI documentation tells you what to do:
For a license text in multiple languages, LicenseLangString can be used. Refer the NSIS Users Manual for more information about installers with multiple languages.
And the NSIS Users Manual says:
LicenseLangString license ${LANG_ENGLISH} license-english.txt
LicenseLangString license ${LANG_FRENCH} license-french.txt
LicenseLangString license ${LANG_GERMAN} license-german.txt
LicenseData $(license)
For MUI you just point the MUI license page to your LicenseLangString:
!include MUI2.nsh
!insertmacro MUI_PAGE_WELCOME
!insertmacro MUI_PAGE_LICENSE $(translatedlicensefile)
!insertmacro MUI_PAGE_DIRECTORY
!insertmacro MUI_PAGE_INSTFILES
!insertmacro MUI_PAGE_FINISH
!insertmacro MUI_LANGUAGE English
LicenseLangString translatedlicensefile ${LANG_ENGLISH} "lic-eng.txt"
!insertmacro MUI_LANGUAGE Swedish
LicenseLangString translatedlicensefile ${LANG_SWEDISH} "lic-swe.txt"
Nsis 3 supports new commands like Unicode true. I want a script that works with makensis2 and makensis3. Is this possible? I use linux.
I tried to write a script. But the compiler doens't accept this
Update:
!if "${NSIS_PACKEDVERSION}" > 0x02ffffff ; NSIS 3+
Unicode true
ManifestSupportedOS all
!else
!warning "NSIS v2, compiling ANSI installer!"
!endif
I use this but get still the error message warning 7070: Invalid number: "${NSIS_PACKEDVERSION}".
${If} is a run-time command but you need to use preprocessor instructions and all of those start with !.
!if "${NSIS_PACKEDVERSION}" > 0x02ffffff ; NSIS 3+
Unicode true
!else
!warning "NSIS v2, compiling ANSI installer!"
!endif
This is the official way but might not work with unofficial releases if VER_PACKED was not passed to SCons when building MakeNSIS.
Here is something that relies on the improved number parser in NSIS v3 instead:
!if 0n1 > 0 ; >= 3.0b0 (Documented in chapter 5.1)
Unicode true
!else
!warning "NSIS v2, compiling ANSI installer!"
!endif
I have created my windows application installer using NSIS 3.02.1.
In language selection textbox, language is display 2 times.
EX.
English/English
Chinese (Simplified) / Hanyu (Jiantizi)
Russian / Russkij...
In my previous setup, which was build using NSIS 2.46 this language setup is looks like :
English
Chinese
Russian...
I don't want to change this in my language selection setup. How can I achieve language selection setup as define in NSIS 2.46 in NSIS 3.02.1?
If you still support Windows 95/98/ME then I would recommend that you use NSIS v2.51, it has all the security updates from NSIS v3 and better language support in the language selection dialog.
If you only support newer versions of Windows then you should add Unicode True to your script, this will display the native name of the language in the language selection dialog and all languages are supported on all systems.
If you insist on creating ANSI installers with NSIS v3 then you can use the undocumented LANGFILE_LANGDLL_FMT define:
OutFile test.exe
RequestExecutionLevel user
!define LANGFILE_LANGDLL_FMT "%NATIVEASCIINAME%" ; %NATIVENAME% can also be used but it will display ? in some cases.
!include "MUI2.nsh"
!insertmacro MUI_RESERVEFILE_LANGDLL
!insertmacro MUI_PAGE_COMPONENTS
!insertmacro MUI_PAGE_INSTFILES
!insertmacro MUI_LANGUAGE "English"
!insertmacro MUI_LANGUAGE "Swedish"
!insertmacro MUI_LANGUAGE "Russian"
!insertmacro MUI_LANGUAGE "SimpChinese"
Function .onInit
!insertmacro MUI_LANGDLL_DISPLAY
FunctionEnd
Section
SectionEnd
In my cabal file I have a bunch of language extensions enabled. Let's say I have
TemplateHaskell
QuasiQuotes
CPP
Is there a way to start GHCi with these enabled automatically? instead of manually doing
ghci -XTemplateHaskell -XQuasiQuotes -XCPP
Yes, you can use the .ghci file. See section 2.9 in the GHC manual.
~/.ghci
:set -XTemplateHaskell -XQuasiQuotes -XCPP
cabal-ghci was exactly what I wanted.
Specify the extensions in a pragma at the top of the source files:
{-# LANGUAGE TemplateHaskell, QuasiQuotes, CPP #-}
For ghc options that are not within the scope of the language pragma, you can also use the OPTIONS_GHC pragma (and you could write {-# OPTIONS_GHC -XTemplateHaskell -XQuasiQuotes -XCPP #-} (note the lack of commas), but the language pragma is preferred where possible, as it is portable to other compilers that support the extensions).