I want to dynamically derive the source folder (and destination folder) for 32/64 bit installations. So how can I specify that in the [Files] section of Inno setup.
The following gives a compilation error:->
[Files]
Source: {#MySourcePath}\{code:GetSourceLibFolder}\*.jar; DestDir: {code:GetAppDir}\lib\;
I have the GetSourceLibFolder() and GetAppDir() function defined in the code section.
The functions are very simple and just return a variable:
function GetSourceLibFolder(Param: String): String;
begin
Result:= SourceLibFolder;
end;
function GetSourceBinFolder(Param: String): String;
begin
Result:= SourceBinFolder;
end;
Thanks !
The source path needs to be used at compile time (unless you have the
externalflag) which means you must use ISPP and a#define. The[Code]section is only for run/install time code so will work for the target path.If you provide the code for your
GetSourceLibFolderfunction, someone can convert it to ISPP.