On Wed, 2015-11-11 at 09:07 +0100, IOhannes m zmoelnig wrote:
On 2015-11-10 21:54, Roman Haefeli wrote:
The not so nice part about NSIS is that you have to list every single file of your source packet explicitly and tell it where to install. Since it is inconvenient to touch that script whenever a new version is released, I added a bash script that creates the file list automatically for a given Pd-for-Windows folder.
looking at my NSIS installer for Gem [1], it seems that you can use wildcards for adding files.
Yes, but when using wildcards the nsi-script still relies on the directory layout not to change. Since we want to actually _move_ the Pd directory as is to its destination (without changing its layout), it seemed more reasonable to me to build the file list on the fly without assuming a directory layout.
iirc, the main problem with this is, that for the *uninstaller* you need to enumerate the files as well (again you can use wildcards, but then you risk deleting unrelated files)
Yes, one more reason to build the list of files dynamically.
Once you have Wine and NSIS installed, it's really only a matter of running the included bash script to create an updated Pd installer. I only tried it on Linux, but if you have bash on Windows, it should work there as well.
wine? shouldn't that only be needed to *test* the installer?
You're right. I could have built makensis (the compiler) on Linux. It seemed easier to me to download their pre-compiled Windows package. If you're going to cross-compile Pd for Windows the Miller way, it's likely you have installed Wine anyway. That is the setup I had in mind.
anyhow, just a quick warning: i do remember having problems with the linux builds of NSIS: the resulting installers worked great but had the side-effect of "somehow" wrecking the target system in subtle ways. (IIRC after running the installer, people stopped being able to use M$ outlook and weird things like that; while i never found out the actual cause of the problem, i was able to confirm that problems started when using the installer built on my Debian system and that they did not start when using the installer built on a W32 system (using the same input)).
Thanks for sharing those experiences! I haven't tried myself to create an installer with a Linux build of makensis and your experiences do not exactly sound encouraging. I tested the resulting installer under Wine, Windows XP (VirtualBox) and Windows 7 (VirtualBox). I didn't run into the problems you described, but of course I wasn't testing much other software after installing. This kind of issues is really hard to test for preemptively.
I tested the following after installing : * Pd runs correctly * Pd files have to correct icon * Pd files are opened with Pd when double-clicked
I tested the following after uninstalling: * The uninstaller can be executed * The uninstaller completely removes Pd from %ProgramFiles% * The uninstaller completely removes the start menu entries * Any entries to the registry added by the installer are removed
If there are more things to be tested on a Windows machine I did not think about, please let me know. To my knowledge, the installer only touches %ProgramFiles%, the start menu, and the registry.
Roman