64BitThreeArch.iss 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. ; -- 64BitThreeArch.iss --
  2. ; Demonstrates how to install a program built for three different
  3. ; architectures (x86, x64, Itanium) using a single installer.
  4. ; SEE THE DOCUMENTATION FOR DETAILS ON CREATING .ISS SCRIPT FILES!
  5. [Setup]
  6. AppName=My Program
  7. AppVersion=1.5
  8. DefaultDirName={pf}\My Program
  9. DefaultGroupName=My Program
  10. UninstallDisplayIcon={app}\MyProg.exe
  11. Compression=lzma2
  12. SolidCompression=yes
  13. OutputDir=userdocs:Inno Setup Examples Output
  14. ; "ArchitecturesInstallIn64BitMode=x64 ia64" requests that the install
  15. ; be done in "64-bit mode" on x64 & Itanium, meaning it should use the
  16. ; native 64-bit Program Files directory and the 64-bit view of the
  17. ; registry. On all other architectures it will install in "32-bit mode".
  18. ArchitecturesInstallIn64BitMode=x64 ia64
  19. [Files]
  20. ; Install MyProg-x64.exe if running on x64, MyProg-IA64.exe if
  21. ; running on Itanium, MyProg.exe otherwise.
  22. ; Place all x64 files here
  23. Source: "MyProg-x64.exe"; DestDir: "{app}"; DestName: "MyProg.exe"; Check: IsX64
  24. ; Place all IA64 files here, first one should be marked 'solidbreak'
  25. Source: "MyProg-IA64.exe"; DestDir: "{app}"; DestName: "MyProg.exe"; Check: IsIA64; Flags: solidbreak
  26. ; Place all x86 files here, first one should be marked 'solidbreak'
  27. Source: "MyProg.exe"; DestDir: "{app}"; Check: IsOtherArch; Flags: solidbreak
  28. ; Place all common files here, first one should be marked 'solidbreak'
  29. Source: "MyProg.chm"; DestDir: "{app}"; Flags: solidbreak
  30. Source: "Readme.txt"; DestDir: "{app}"; Flags: isreadme
  31. [Icons]
  32. Name: "{group}\My Program"; Filename: "{app}\MyProg.exe"
  33. [Code]
  34. function IsX64: Boolean;
  35. begin
  36. Result := Is64BitInstallMode and (ProcessorArchitecture = paX64);
  37. end;
  38. function IsIA64: Boolean;
  39. begin
  40. Result := Is64BitInstallMode and (ProcessorArchitecture = paIA64);
  41. end;
  42. function IsOtherArch: Boolean;
  43. begin
  44. Result := not IsX64 and not IsIA64;
  45. end;