简体   繁体   中英

Adding License information to NSIS installer

We distribute the software created by my group via Windows installers generated via NSIS. We generate our NSIS configuration files from a python script written by a developer who no longer works with us, so we currently do not have anyone on staff who knows how to write NSIS config files. I have been tasked with modifying this script to add a section to the installer that displays our licensing information prior to performing the actual install.

What would such a section in a NSIS config file look like?

Depends on how the installer is structured and what NSIS functionality it uses.

For example, if it uses MUI ("modern user interface") macros, then it could be as simple as adding

!insertmacro MUI_PAGE_LICENSE "License.txt"

Somewhere in the text. Most likely between some other pages in MUI_PAGE stuff. For example, one installer I'm working on at the moment has this:

!insertmacro MUI_PAGE_WELCOME
!insertmacro MUI_PAGE_LICENSE "..\..\Licenses\License.txt"
!insertmacro MUI_PAGE_DIRECTORY

This results in welcome page, followed by license page, followed by "choose directory" page.

For more options, read NSIS MUI documentation.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM