Calculate Size of Unpacked 7z Archive
The other day I encountered the #12345 error for exceeding the 2Gb installer file size limit. Searching around the forums I found that the common solution to this problem is to store the data in an archive separate from the installer executable, and unpack it during the install.

I found this works well using the 7zip command line approach (which is detailed in other topics on the forum).

The problem with this solution however is that the "required space" display does not take into account the size of the data in the external archive.

As a solution, I've written a little python script to calculate the size of the archive, and replace a predefined string ("%data_size%") in the nsis script with this value: