I have a helper DLL and a function that I call at the end of my script installation. I just want to run it depending on the version of the operating system.
I include the following lines in the code section:
function CompleteInstall(szInstallPath: String) : Integer;
external 'CompleteInstall@files:InstallHelper.dll cdecl setuponly';
I wrote a function to prevent the extraction of the DLL by adding in the [Files] instruction for the parameter "Validation: IsXPorHigher" in the "Source") in the [Files] section.
It seems that when I run the installer, it tries to eliminate the external function due to the external operator, causing a runtime error (Can not import ...), because my DLL relies on a function that is not available on older OSs.
Is it possible to conditionally declare a function in a script, or does this require a separate installer for older versions of the OS? I try to support only one script for all scripts.
source
share