multitheftauto / mtasa-blue

Multi Theft Auto is a game engine that incorporates an extendable network play element into a proprietary commercial single-player game.
https://multitheftauto.com
GNU General Public License v3.0
1.38k stars 426 forks source link

Upgrade NSIS #2158

Closed Dutchman101 closed 1 year ago

Dutchman101 commented 3 years ago

Describe the request MTA is using a really old version of NSIS (Nullsoft Scriptable Install System) for its installer. I propose that we update it to the latest version, NSIS 3.08 (or whatever is latest at time of implementation).

The reason we didn't update earlier was being blocked by a lack of proper unicode support (or related issues) but now that more modern NSIS versions support unicode natively and the exact blocker has been resolved in NSIS, it should no longer be a problem to upgrade.

Development discussions have taken place surrounding the specifics that i have lost & can't locate anymore, but i vaguely remember these possible aspects (it can be any of them):

At the time we discussed it (the lost development discussion I referred to), i determined that modern NSIS versions did tackle the exact issue that was keeping us from updating, during that discussion I was actually able to get the exact changelog that resolved the issue blocking us to upgrade. The newer builds also natively support unicode. This isn't something I vaguely remember, but something I am sure about.

The latter should motivate us to (try) update NSIS for MTA installer. If anyone else knows or can find context that i lost (or work it out from zero) that would be nice as well.

Lpsd commented 3 years ago

This should also resolve #435

patrikjuvonen commented 1 year ago

Resolved in r21722

Dutchman101 commented 1 year ago

NSIS upgrade has largely been done on build server, except for 423b55d

We may need to bump some plugins, scripts and includes to versions that were designed for NSIS 3 (best practise - even though it already works), i will come up with a list of candidates soon

Combined changelog since our previous version (2.46.5):


F.2 3.08 Released on September 25th, 2021

F.2.1 Release Notes This release is filled with features that a lot of people have been requesting for a while. Enjoy!

F.2.2 Changelog F.2.2.1 Major Changes Added !uninstfinalize (patch #280, bug #1241) F.2.2.2 Minor Changes Added $USER.. and $COMMON.. alias constants Added GetDLLVersion /ProductVersion switch Added GetWinVer instruction Disallow start maximized mode Added /LAUNCH compiler switch PEAddResource now supports the res:// protocol System::Store can push/pop the flags state F.3 3.07 Released on July 24th, 2021

F.3.1 Release Notes Unicode is now the default.

F.3.2 Changelog F.3.2.1 Major Changes Unicode now defaults to true F.3.2.2 Minor Changes Added nsExec /MBCS switch Memento now supports overridable storage macros Fixed Unicode compiler crash (bug #1254, patch #300) Fixed !addplugindir relative path bug (bug #1264) Fixed StrClb Unicode bug (patch #302) Fixed ${GetTime} hour padding (bug #980) F.3.2.3 Translations Updated Albanian (patch #303), Corsican and Japanese (maboroshin PR) Fixed clipped Chinese text (bug #1261) F.4 3.06.1 Released on July 31st, 2020

F.4.1 Release Notes 20th anniversary! The first public release of NSIS was v1.0f on July 31st, 2000.

F.4.2 Changelog F.4.2.1 Major Changes Fixed SetBrandingImage crash F.5 3.06 Released on July 31st, 2020

F.5.1 Changelog F.5.1.1 Major Changes DeleteRegKey /ifempty now also checks for values, not just subkeys. Use /ifnosubkeys for the old behavior. Added GetKnownFolderPath Added UnpinShortcut macro (Integration.nsh) F.5.1.2 Minor Changes Added IfShellVarContextAll and IfRtlLanguage Added !define /intfmt Added Date/Time nsDialogs controls and macros MultiUser: Fixed INSTALLMODE_FUNCTION and added INSTALLMODEPAGE_SHOWUSERNAME F.5.1.3 Translations Updated German (SebStange PR) and Simplified Chinese (patch #297) F.5.1.4 Build System Primitive SOURCE_DATE_EPOCH support (patch #294) Python 3 fixes (patch #296) GCC 10 memmove workaround (bug #1248) F.6 3.05 Released on December 15th, 2019

F.6.1 Release Notes ANSI targets are deprecated, consider moving to Unicode.

F.6.2 Changelog F.6.2.1 Major Changes Added PEAddResource and PERemoveResource Added LoadAndSetImage Allow quoted library path in System::Call (bug #546 and bug #1225) Improved nsExec Unicode and tab output parsing (bug #1232) F.6.2.2 Minor Changes Added experimental ManifestLongPathAware attribute %1 in !finalize command can be specified multiple times Fixed -O stderr stream issue (bug #1221) Fixed InstallLib .NSI space-in-path bug (bug #1222) StrFunc now supports a "using" idiom to help with forward-declaration of functions (bug #1229) Added SectionInstType Zero uninitialized data in icon group (bug #1230) Automatically doubles ampersands in the Name attribute Fixed nsDialogs CB/LB_Get/SetItemData macros (bug #1238) F.6.2.3 Translations Updated Hindi (patch #291) and Portuguese (bug #1219) F.7 3.04 Released on December 15th, 2018

F.7.1 Changelog F.7.1.1 Major Changes Added IsNativeMachineArchitecture helper macros to x64.nsh Added experimental WinVer "Windows as a Service" detection macros Added MakeNSISW window info "spy" tool F.7.1.2 Minor Changes Added MUI_TEXTCOLOR setting nsDialogs::OnNotify can now return values back to Windows Added LIBRARY_INSTALL_EQUAL_VERSION InstallLib option Added NTMARTA to preload list to fix rare Windows 7 security issue (bug #1204) AddBrandingImage now supports dialog units Fixed !macroundef of last defined macro bug Fixed MultiUser caption string bug (bug #1012) !undef issues warnings instead of errors MakeNSIS prints -CMDHELP to stdout (bug #1203) Removed LibraryLocal utility F.7.1.3 Translations Added Hindī (patch #289) Updated Belarusian, German (bug #1023), Mongolian and Spanish (bug #1205) F.8 3.03 Released on January 29th, 2018

F.8.1 Release Notes Building NSIS with Python 2.6 or older is no longer supported F.8.2 Changelog F.8.2.1 Major Changes Added more NSD controls and macros (RFE #543) Added !gettlbversion Library TLB and VxD version support on POSIX (patch #284) F.8.2.2 Minor Changes Added System plug-in v2 syntax option Added System plug-in B and H types Added IntPtrCmp, IntPtrCmpU, and IntPtrOp Added Int64Cmp, Int64CmpU and Int64Fmt (64-bit only) Added IntOp and System::Int64Op >>> operator Added more !define /math operators Added WinVer.nsh IsDomainController (patch #286) Plug-ins now set the ASLR, DEP, LAA, NOSEH and TS PE flags (bug #1188) MakeNSIS exits with code 0 for various information commands (bug #1193) Added error and warning states to !pragma warning Removed unused NSD_LB_Clear macro parameter F.8.2.3 Translations Added Tatar (patch #281) Fixed and updated Scottish Gaelic (patch #285, bug #1197) Updated Italian (bug #1194) F.8.2.4 Build System Added support for Python 3 Dropped support for Python 2.6 and older F.9 3.02.1 Released on July 31st, 2017

F.9.1 Changelog F.9.1.1 Translations Fixed Chinese (Traditional) and Romanian translation bugs (bug #1189 and bug #1191) Fixed Scots Gaelic MUI finish page translation F.10 3.02 Released on July 23rd, 2017

F.10.1 Changelog F.10.1.1 Major Changes Fixed NSIS3 RegTool Win9x bug Added the HKCR32, HKCR64, HKCU32, HKCU64, HKLM32 and HKLM64 root keys Unsupported SetRegView mode now fails all registry operations Added ExecShellWait Added WriteRegMultiStr (RFE #382, patch #219) and WriteRegNone Added !pragma warning (patch #267) $LocalAppData now resolves to the ProgramData folder in the SetShellVarContext all context F.10.1.2 Minor Changes Variables used in Caption can now be set in .onGUIInit (RFE #539) MultiUser now supports $ProgramFiles64 (bug #843) Added support for MUI_UNCONFIRMPAGE_VARIABLE (RFE #511) and MUI_PAGE_CUSTOMFUNCTION_DESTROYED Unicode nsExec now supports the /OEM switch (bug #1171) F.10.1.3 Translations Chinese (Traditional) updates by Walter Cheuk Minor French improvements (patch #221) F.11 3.01 Released on December 11th, 2016

F.11.1 Changelog F.11.1.1 Major Changes Error messages are now written to stderr by default New icons by Jan T. Sott F.11.1.2 Minor Changes SetCtlColors now supports Windows color constant values StrCpy "" maxlen handling (bug #1122) Fixed buffer size bug in winchar.cpp (patch #271) F.11.1.3 Translations Added Corsican (patch #268) PortugueseBR fixes (patch #276) Updated Danish translation (bug #1164) Arabic, Norwegian, Portuguese, Ukrainian and Swedish MultiUser fixes (patch #278, patch #279, patch #274, patch #275 & patch #277) F.12 3.0 Released on July 24th, 2016

F.12.1 Release Notes Long-awaited version 3 of NSIS is finally ready. It comes with optional Unicode support, still works on all the same versions of Windows, supports Windows 10, and adds a lot of other small features and fixes. Huge thanks goes out to Anders and Wizou for making this happen and Jim Park for the original patch.

F.12.2 Changelog F.12.2.1 Minor Changes !finalize command now supports the same compare operators as !system (bug #1148) F.12.2.2 Translations PortugueseBR fixes (bug #1149) F.13 3.0 Release Candidate 2 Released on July 8th, 2016

F.13.1 Changelog F.13.1.1 Major Changes Fixed LogicLib nested ${Select} bug !makensis command must force Unicode output to be UTF-8 (bug #1147) F.13.1.2 Minor Changes Zip2Exe aborts if the zip file is encrypted (bug #1141) Added LogicLib & operator NSIS Menu POSIX fixes (bug #1144) F.13.1.3 Translations PortugueseBR fixes (deguix) Minor tweaks to Danish.nlf (scootergrisen) (bug #1140) F.14 3.0 Release Candidate 1 Released on April 3rd, 2016

F.14.1 Changelog F.14.1.1 Major Changes Fixed !appendfile on POSIX and LogicLib ${Switch} More security hardening to prevent dll hijacking F.14.1.2 Minor Changes Documentation improvements The name of the uninstaller created in %TEMP%\~nsu.tmp has changed from %UNIQUE%u.exe to Un%UNIQUE%.exe Various warning and error improvements F.14.1.3 Translations Added missing MULTIUSER_* entries to Japanese.nsh (patch #266) F.15 3.0 Beta 3 Released on December 26th, 2015

F.15.1 Changelog F.15.1.1 Major Changes RequestExecutionLevel now defaults to admin LoadLibrary security hardening to prevent dll hijacking (bug #1125) FileReadUTF16LE now skips the optional BOM at the start of a file F.15.1.2 Minor Changes Fixed System plugin GUID type output bug on Win98 FileWriteUTF16LE can add a BOM with the /BOM switch CreateShortcut icon index can now be larger than 255 (bug #1123) !system and !execute now provide an empty StdIn pipe to work around bugs in some Windows utilities Added support for 0o octal radix prefix on number literals in the preprocessor The single parameter version of !if now also supports floats Preprocessor now warns when invalid floating point numbers are used in math operations MakeNSISW now uses WinInet when checking for updates F.15.1.3 Translations Brazilian Portuguese updated (Felipe) (patch #263) Polish updated (Paweł Porwisz) F.16 3.0 Beta 2 Released on August 4th, 2015

F.16.1 Changelog F.16.1.1 Major Changes Preliminary Windows 10 support F.16.1.2 Minor Changes Added !appendfile /RawNL switch Added PESubsysVer attribute Exec[Wait] sets the CREATE_DEFAULT_ERROR_MODE flag when creating a process Fixed 4+ TiB freespace calculation bug (bug #1115) Fixed CreateShortcut /NoWorkingDir parsing bug (bug #1110) Fixed minor issues in the Pascal NSIS plug-in SDK and removed the extrap global variable nsDialogs and InstallOptions now use the system link color F.16.1.3 Build System Linux stdcall warning fix (patch #261) Linux test-scripts fix (patch #260) Win64 fixes (including patch #258, bug #1105) Visual C 2012 fixes F.17 3.0 Beta 1 Released on October 6th, 2014

F.17.1 Release Notes This release addresses a lot of build issues, reintroduces the nightly builds and adds automatic nightly test execution F.17.2 Changelog F.17.2.1 Major Changes !insertmacro allows macro recursion (RFE #497) Added !makensis command Added new MUI2 bitmap stretch modes, *_NOSTRETCH is now deprecated (RFE #521) InitiateShutdown() is used to reboot the machine if available (patch #247) Added PPO and SafePPO preprocess-only compiler switches MakeNSIS WM_COPYDATA messages now use the QH_OUTPUTCHARSET encoding with CP_ACP as the default for compatibility with old IDEs. F.17.2.2 Minor Changes Added IsWow64 to x64.nsh Added PEDllCharacteristics attribute Added System::Call direct register memory access type. (patch #249) Added WX compiler switch Allow skipping ExDLL build with SKIPPLUGINS ((patch #254)) Changed default DllCharacteristics to TS_AWARE+NO_SEH+NX_COMPAT+DYNAMIC_BASE Fixed Mac OS X builds (patch #253 and bug #1085) Fixed POSIX !searchparse bug (patch #251) Fixed !macroundef Fixed test-code build target on POSIX and enabled it in nightly builds (bug #1098) Fixed Visual Studio 2012 builds F.17.2.3 Translations Added Armenian (Hrant Ohanyan) F.18 3.0 Beta 0 Released on May 11th, 2014

F.18.1 Release Notes POSIX builds work again! Please let us know if your favorite platform is still having build issues. We mainly test on Linux. F.18.2 Changelog F.18.2.1 Major Changes Basic AMD64 System::Call support Fixed POSIX builds F.18.2.2 Minor Changes Added CreateShortcut /NoWorkingDir parameter Added Int<32|64|Ptr><Op|Cmp[U]> helper macros to Util.nsh Added P<, P<=, P=, P<>, P>= and P> LogicLib ptrdiff_t tests Try harder to find duplicate strings in string block (bug #1088) !system will decode child output as OEMCP if GetConsoleOutputCP() == GetOEMCP() !system and !execute can store the exit code in a define !execute supports comparing the exit code with the same syntax as !system Preprocessor supports 0n and 0b radix prefix on number literals F.19 3.0 Alpha 2 Released on December 24th, 2013

F.19.1 Release Notes It's the holiday gift you've been waiting for!

F.19.1.1 Known Issues The POSIX build is getting much closer, but still currently broken LangDLL doesn't display localized language name with Unicode false F.19.2 Changelog F.19.2.1 Major Changes !include defaults to UTF-8 after Unicode True Preprocessor does not parse all branches and will not validate code that is never executed (bug #1086) F.19.2.2 Minor Changes FileRead in Unicode installers can handle DBCS, conversion output is limited to UCS-2. FileRead in Unicode installers now uses the Unicode replacement character (U+FFFD) for invalid characters and not '?'. FileReadByte no longer performs a Unicode conversion on non-ASCII characters Windows 8.1 & 2012R2 support in WinVer.nsh Fixed !define Unicode null terminator bug (bug #1079) Unicode stubs create WCHAR richedit controls (bug #1080) Fixed MakeNSISW default pushbutton and tab order Fixed incorrect page count in compiler statistics F.20 3.0 Alpha 1 Released on July 14th, 2013

F.20.1 Release Notes F.20.1.1 Known Issues The POSIX build is currently broken LangDLL doesn't display localized language name with Unicode false FileRead may return '?' for MBCS letters with Unicode true F.20.2 Changelog F.20.2.1 Major Changes Default verbosity is /V3 without logo, MakeNSISW still uses /V4. ManifestSupportedOS added support for the Windows 8.1 GUID and it is set by default to avoid GetVersionEx compatibility behavior. F.20.2.2 Minor Changes Fixed !finalize %1 Fixed !searchparse (bug #1073) Made installers always respect /S on command line, even when installer file can't be read (bug #1076) Minor MakeNSISW fixes and tweaks Added Zip2Exe Unicode checkbox F.21 3.0 Alpha 0 Released on May 19th, 2013

F.21.1 Release Notes MakeNSIS can now generate ANSI and Unicode installers. Source files can be UTF8SIG, UTF16BOM or traditional MBCS text files (which are converted to Unicode with ACP unless you specify a different codepage). The default plugins are now stored in sub-folders based on their CPU target and character set encoding. F.21.1.1 Known Issues The POSIX build is currently broken LangDLL doesn't display localized language name with Unicode false FileRead may return '?' for MBCS letters with Unicode true F.21.2 Changelog F.21.2.1 Major Changes Added the Unicode attribute (RFE #1238132, patch #1795257) Added support for Windows 8 and Windows Server 2012 MakeNSIS can read UTF8SIG and UTF16BOM script files (RFE #2026892) All NLF and NSH language files are stored as UTF-16LE (RFE #1879642) Scripts can control the SupportedOS list in the application manifest using ManifestSupportedOS (bug #2725883, RFE #3020103) Installers can claim DPI-awareness with ManifestDPIAware (bug #2897169) The index of the changed section is stored in $0 during .onSelChange callbacks (RFE #1634936) ${U+1}...${U+10FFFF} are treated as a Unicode character unless there is already a define with that name (RFE #2084797) F.21.2.2 Minor Changes Added !getdllversion (bug #2809308) Added !appendfile /CHARSET parameter Added !if support for /fileexists, case sensitive comparisons, hex and float Added more definitions to WinMessages.nsh %temp%\Low will be used if the installer cannot write to %temp% nor %windir%\Temp (bug #2909242, patch #2912824) Added ${NSIS_PACKEDVERSION}, the NSIS version packed as a hex number (patch #2680832) Added ${MACRO} and ${COUNTER} predefines Added UnsafeStrCpy instruction, it can write to special variables like $PLUGINSDIR Added VIFileVersion Added !finalize for post-build commands (like signing the installer) Plugins in ${NSISDIR}\Plugins have to be reserved with ReserveFile /plugin MakeNSIS /NOTIFYHWND uses a (optional) new event name to abort compilation, see build.cpp/h for details. Reduced !include/!insertmacro recursion stack usage (bug #3067954) Fixed minor MakeNSIS leaks (bug #3474662) Fixed MUI_FINISHPAGE_TITLE_3LINES padding when reboot is required (bug #3400067, bug #3408407) Fixed removal of read only attribute even if Delete or RMDir fails (bug #3072159) Fixed ${SECTION} in hidden sections (RFE #1787648) Various documentation fixes (bug #3063566, bug #3567313, patch #3307144) Lots of other small fixes... F.21.2.3 Translations Changed LANGFILE macro in LangFile.nsh Warnings are now displayed for missing strings (LANGFILE_INCLUDEWITHDEFAULT) Added Georgian (David Huriev) Added Pashto (Pakhtosoft) Added Scottish Gaelic (GunChleoc) Fixed Korean MUI[UN]TEXT_FINISHINFO* (bug #3541515) F.22 2.51 Released on April 1st, 2016

F.22.1 Changelog F.22.1.1 Minor Changes More security hardening to prevent dll hijacking Backported support for system 'p' type and logiclib P and Z tests F.22.1.2 Translations Added missing MULTIUSER_* entries to Japanese.nsh (patch #266) F.23 2.50 Released on December 26th, 2015

F.23.1 Changelog F.23.1.1 Major Changes RequestExecutionLevel now defaults to admin F.23.1.2 Minor Changes Preload certain system libraries to prevent dll hijacking (bug #1125) F.24 2.49 Released on December 16th, 2015

F.24.1 Changelog Fixed CreateShortcut failure on Vista caused by security changes in 2.47 F.25 2.48 Released on December 10th, 2015

F.25.1 Changelog Fixed CHM (bug #1129) F.26 2.47 Released on December 8th, 2015

F.26.1 Release Notes This is a maintenance and security release F.26.2 Changelog F.26.2.1 Major Changes LoadLibrary security hardening to prevent dll hijacking (bug #1125) InitiateShutdown() is used to reboot the machine if available (patch #247) F.26.2.2 Minor Changes Fixed 4+ TiB freespace calculation bug (bug #1115) Windows 8 & 2012 support in WinVer.nsh