Platform.wxi 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <!--
  3. *
  4. * Copyright (C) by Michael Schuster <michael@schuster.ms>
  5. *
  6. * This program is free software; you can redistribute it and/or modify
  7. * it under the terms of the GNU General Public License as published by
  8. * the Free Software Foundation; either version 2 of the License, or
  9. * (at your option) any later version.
  10. *
  11. * This program is distributed in the hope that it will be useful, but
  12. * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
  13. * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
  14. * for more details.
  15. *
  16. -->
  17. <Include>
  18. <!--
  19. MSI packages are built either for x86 or x64, we use defines to maintain a single WiX script.
  20. Some hints:
  21. https://www.joyofsetup.com/2010/05/14/working-hard-or-hardly-working/
  22. https://stackoverflow.com/questions/18628790/build-wix-3-6-project-targeting-x64
  23. https://www.howtobuildsoftware.com/index.php/how-do/1oQ/wix-detect-if-32-or-64-bit-windows-and-define-var
  24. -->
  25. <?if $(var.Platform) = x64 ?>
  26. <?define PlatformBitness = "(64-bit)" ?>
  27. <?define PlatformWin64 = "yes" ?>
  28. <?define PlatformProgramFilesFolder = "ProgramFiles64Folder" ?>
  29. <?else ?>
  30. <?define PlatformBitness = "(32-bit)" ?>
  31. <?define PlatformWin64 = "no" ?>
  32. <?define PlatformProgramFilesFolder = "ProgramFilesFolder" ?>
  33. <?endif ?>
  34. </Include>