To fix this, the code in Shared.nsh will have to be modified. Start here: https://searchfox.org/mozilla-central/source/browser/installer/windows/nsis/shared.nsh#1285 NSIS is basically assembly language. You'll have to use the IntCmp in that method: https://nsis.sourceforge.io/Reference/IntCmp
Bug 1879963 Comment 4 Edit History
Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.
To fix this, remove pinning as an option from the installer (setup.exe) on older versions of Windows. To do that, the code in Shared.nsh will have to be modified. Start here: https://searchfox.org/mozilla-central/source/browser/installer/windows/nsis/shared.nsh#1285 NSIS is basically assembly language. You'll have to use the IntCmp in that method: https://nsis.sourceforge.io/Reference/IntCmp You'll have to add a new label ${pin_lbl}_win10 or something, jump to that when the version is the right number. Basically, go here: https://searchfox.org/mozilla-central/source/browser/installer/windows/nsis/shared.nsh#1327 and modify the code to: ``` ; If the build number is less than 19045, jump to pinning; if greater, keep testing IntCmp $2 19045 "" ${pin_lbl}_good "" ; if the major number is less than 22000, then test against windows 10 IntCmp $2 22000 "" ${pin_lbl}_test_win10 "" ${pin_lbl}_test_win11: ; If the build number is less than 22621, jump to pinning; if greater than, no pinning IntCmp $2 22621 "" ${pin_lbl}_good ${pin_lbl}_bad ; Only if the version is 10.0.22621 do we fall through to here ; If the UBR is greater than or equal to 2361, jump to no pinning ; Otherwise jump to pinning IntCmp $3 2361 ${pin_lbl}_bad ${pin_lbl}_good ${pin_lbl}_bad ${pin_lbl}_test_win10: ; Only if the version is 10.0.19045 do we fall through to here ; If the UBR is greater than or equal to 3996, jump to no pinning IntCmp $3 3996 ${pin_lbl}_bad ${pin_lbl}_good ${pin_lbl}_bad ${pin_lbl}_good: ``` To test that this all works, you'll need to be running on Windows 10. You can do this using a VM. You'll need to test with an older version of Windows 10, to confirm that pinning appears as an option in the advanced options of the installer and leaving pinning on results in the installer pinning to the taskbar. You'll also have to test on the newest version of Windows 10 (to be released tomorrow, newest as of today, Jan 12, 2024). On the newer version of Windows 10, confirm that pinning is not one of the options in the advanced options in the installer. Also test on an older version of Windows 11, to confirm that you didn't break that from working as well. (Michael Hughes can help test this once a diff is up).