Archive: 64-bit Windows


64-bit Windows
Hi,
I'm glad that NSIS now provides a better support for installations under 64-bit Windows. Unfortunately not completely as I expected. It is still necessary to implement different scripts for 32- and 64-bit Windows! E.g., on 32-bit Windows I have to use $PROGRAMFILES to write to the program files directory, on 64-bit Windows I have to use $PROGRAMFILES64. It would be easier to use the same script for both systems (i.e. $PROGRAMFILES) but compiling different installer just by using a compiler option. Running a 32-bit installer on a 64-bit system is a workaround that involves some problems: file system redirection, registry redirection, calling 64-bit DLLs et cetera. It's a lot effort to write the same installer for both systems, even with the new NSIS features like SetRegView, $PROGRAMFILES64... And it requires that the developer has to know the differences of both systems in detail.
This effort could be avoided just by compiling a real 64-bit installer!


you can work around the program files problem yourself;

!ifdef SomeSpecialFlag
!define MyPF "$PROGRAMFILES64"
!else
!define MyPF "$PROGRAMFILES"
!endif

and then just use ${MyPF}, then do makensis.exe /DSomeSpecialFlag for the special build

The preprocessor can help you out with most of this stuff so you can have just one script for both versions


Yes, that's right. I implemented such things. But it's just one of many problems. Think about 64-bit DLLs that cannot called by 32-bit applications but are sometimes required (e.g. for driver installation), et cetera ... Sure there is a workaround for each issue. But why should it be required to have such an effort for every developer. It's easy to create a new configuration in a C++ IDE to create a 64-bit application from the files of a 32-bit application. Usually there are only a few things to change. So maybe it's less effort to implement an NSIS compiler that is able to create 64-bit installer than implementing a lot of tricks that try to get a 32-bit installer working under 64-bit Windows. And there is still the other problem I mentioned: Every NSIS user has to know the differences between 32-bit and 64-bit Windows to apply the tricks at the right time. Most of this knowledge would be dispensable if NSIS would compile real 64-bit installer.


It's easy to create a new configuration in a C++ IDE to create a 64-bit application from the files of a 32-bit application.
No, it's not that easy. If it was, you'd already have 64-bit NSIS.

It sounds to me that you already investigated that topic. Is it planned to provide 64-bit NSIS? And if so, when?


There is no set roadmap for this feature.