diff options
| author | Bob Arnson <bob@firegiant.com> | 2020-05-17 17:30:46 -0400 |
|---|---|---|
| committer | Bob Arnson <bob@firegiant.com> | 2020-05-17 17:38:40 -0400 |
| commit | df8cf532fb8f77947664b95901122b8b47fe562b (patch) | |
| tree | e88c8e836c8f215fa2bd67760a2c0ab91e12aff8 /src | |
| parent | ad9cdd7dc6faee762e06a8d3446fa68c74dd802d (diff) | |
| download | wix-df8cf532fb8f77947664b95901122b8b47fe562b.tar.gz wix-df8cf532fb8f77947664b95901122b8b47fe562b.tar.bz2 wix-df8cf532fb8f77947664b95901122b8b47fe562b.zip | |
Add missing ARM64 cases & random fixes.
Diffstat (limited to 'src')
| -rw-r--r-- | src/WixToolset.Core.WindowsInstaller/Unbind/ExtractCabinetsCommand.cs | 2 | ||||
| -rw-r--r-- | src/WixToolset.Core/Compiler.cs | 18 | ||||
| -rw-r--r-- | src/WixToolset.Core/Compiler_2.cs | 45 | ||||
| -rw-r--r-- | src/WixToolset.Core/ExtensibilityServices/PreprocessHelper.cs | 3 |
4 files changed, 45 insertions, 23 deletions
diff --git a/src/WixToolset.Core.WindowsInstaller/Unbind/ExtractCabinetsCommand.cs b/src/WixToolset.Core.WindowsInstaller/Unbind/ExtractCabinetsCommand.cs index 6840b2d4..f63835b8 100644 --- a/src/WixToolset.Core.WindowsInstaller/Unbind/ExtractCabinetsCommand.cs +++ b/src/WixToolset.Core.WindowsInstaller/Unbind/ExtractCabinetsCommand.cs | |||
| @@ -90,7 +90,7 @@ namespace WixToolset.Core.WindowsInstaller.Unbind | |||
| 90 | { | 90 | { |
| 91 | if (null != record) | 91 | if (null != record) |
| 92 | { | 92 | { |
| 93 | // since the cabinets are stored in case-sensitive streams inside the msi, but the file system is not case-sensitive, | 93 | // since the cabinets are stored in case-sensitive streams inside the msi, but the file system is not (typically) case-sensitive, |
| 94 | // embedded cabinets must be extracted to a canonical file name (like their diskid) to ensure extraction will always work | 94 | // embedded cabinets must be extracted to a canonical file name (like their diskid) to ensure extraction will always work |
| 95 | var cabinetFile = Path.Combine(this.IntermediateFolder, String.Concat("Media", Path.DirectorySeparatorChar, diskId.ToString(CultureInfo.InvariantCulture), ".cab")); | 95 | var cabinetFile = Path.Combine(this.IntermediateFolder, String.Concat("Media", Path.DirectorySeparatorChar, diskId.ToString(CultureInfo.InvariantCulture), ".cab")); |
| 96 | 96 | ||
diff --git a/src/WixToolset.Core/Compiler.cs b/src/WixToolset.Core/Compiler.cs index d4ad3279..32e9b9d6 100644 --- a/src/WixToolset.Core/Compiler.cs +++ b/src/WixToolset.Core/Compiler.cs | |||
| @@ -79,6 +79,12 @@ namespace WixToolset.Core | |||
| 79 | public Platform CurrentPlatform => this.Context.Platform; | 79 | public Platform CurrentPlatform => this.Context.Platform; |
| 80 | 80 | ||
| 81 | /// <summary> | 81 | /// <summary> |
| 82 | /// Gets or sets the platform which the compiler will use when defaulting 64-bit attributes and elements. | ||
| 83 | /// </summary> | ||
| 84 | /// <value>The platform which the compiler will use when defaulting 64-bit attributes and elements.</value> | ||
| 85 | public bool IsCurrentPlatform64Bit => this.Context.Platform == Platform.ARM64 || this.Context.Platform == Platform.IA64 || this.Context.Platform == Platform.X64; | ||
| 86 | |||
| 87 | /// <summary> | ||
| 82 | /// Gets or sets the option to show pedantic messages. | 88 | /// Gets or sets the option to show pedantic messages. |
| 83 | /// </summary> | 89 | /// </summary> |
| 84 | /// <value>The option to show pedantic messages.</value> | 90 | /// <value>The option to show pedantic messages.</value> |
| @@ -1777,7 +1783,7 @@ namespace WixToolset.Core | |||
| 1777 | } | 1783 | } |
| 1778 | } | 1784 | } |
| 1779 | 1785 | ||
| 1780 | if (!explicitWin64 && (Platform.IA64 == this.CurrentPlatform || Platform.X64 == this.CurrentPlatform)) | 1786 | if (!explicitWin64 && this.IsCurrentPlatform64Bit) |
| 1781 | { | 1787 | { |
| 1782 | search64bit = true; | 1788 | search64bit = true; |
| 1783 | } | 1789 | } |
| @@ -2250,7 +2256,7 @@ namespace WixToolset.Core | |||
| 2250 | } | 2256 | } |
| 2251 | } | 2257 | } |
| 2252 | 2258 | ||
| 2253 | if (!explicitWin64 && (Platform.IA64 == this.CurrentPlatform || Platform.X64 == this.CurrentPlatform)) | 2259 | if (!explicitWin64 && this.IsCurrentPlatform64Bit) |
| 2254 | { | 2260 | { |
| 2255 | //bits |= MsiInterop.MsidbComponentAttributes64bit; | 2261 | //bits |= MsiInterop.MsidbComponentAttributes64bit; |
| 2256 | win64 = true; | 2262 | win64 = true; |
| @@ -3405,7 +3411,7 @@ namespace WixToolset.Core | |||
| 3405 | id = Identifier.Invalid; | 3411 | id = Identifier.Invalid; |
| 3406 | } | 3412 | } |
| 3407 | 3413 | ||
| 3408 | if (!explicitWin64 && (CustomActionTargetType.VBScript == targetType || CustomActionTargetType.JScript == targetType) && (Platform.IA64 == this.CurrentPlatform || Platform.X64 == this.CurrentPlatform)) | 3414 | if (!explicitWin64 && this.IsCurrentPlatform64Bit && (CustomActionTargetType.VBScript == targetType || CustomActionTargetType.JScript == targetType)) |
| 3409 | { | 3415 | { |
| 3410 | win64 = true; | 3416 | win64 = true; |
| 3411 | } | 3417 | } |
| @@ -5510,6 +5516,12 @@ namespace WixToolset.Core | |||
| 5510 | case "ia64": | 5516 | case "ia64": |
| 5511 | procArch = "ia64"; | 5517 | procArch = "ia64"; |
| 5512 | break; | 5518 | break; |
| 5519 | case "arm": | ||
| 5520 | procArch = "arm"; | ||
| 5521 | break; | ||
| 5522 | case "arm64": | ||
| 5523 | procArch = "arm64"; | ||
| 5524 | break; | ||
| 5513 | case "": | 5525 | case "": |
| 5514 | break; | 5526 | break; |
| 5515 | default: | 5527 | default: |
diff --git a/src/WixToolset.Core/Compiler_2.cs b/src/WixToolset.Core/Compiler_2.cs index 85fb9e4c..c5f3fb6f 100644 --- a/src/WixToolset.Core/Compiler_2.cs +++ b/src/WixToolset.Core/Compiler_2.cs | |||
| @@ -632,23 +632,27 @@ namespace WixToolset.Core | |||
| 632 | 632 | ||
| 633 | switch (this.CurrentPlatform) | 633 | switch (this.CurrentPlatform) |
| 634 | { | 634 | { |
| 635 | case Platform.X86: | 635 | case Platform.X86: |
| 636 | platform = "Intel"; | 636 | platform = "Intel"; |
| 637 | break; | 637 | break; |
| 638 | case Platform.X64: | 638 | case Platform.X64: |
| 639 | platform = "x64"; | 639 | platform = "x64"; |
| 640 | msiVersion = 200; | 640 | msiVersion = 200; |
| 641 | break; | 641 | break; |
| 642 | case Platform.IA64: | 642 | case Platform.IA64: |
| 643 | platform = "Intel64"; | 643 | platform = "Intel64"; |
| 644 | msiVersion = 200; | 644 | msiVersion = 200; |
| 645 | break; | 645 | break; |
| 646 | case Platform.ARM: | 646 | case Platform.ARM: |
| 647 | platform = "Arm"; | 647 | platform = "Arm"; |
| 648 | msiVersion = 500; | 648 | msiVersion = 500; |
| 649 | break; | 649 | break; |
| 650 | default: | 650 | case Platform.ARM64: |
| 651 | throw new ArgumentException("Unknown platform enumeration '{0}' encountered.", this.CurrentPlatform.ToString()); | 651 | platform = "Arm64"; |
| 652 | msiVersion = 500; | ||
| 653 | break; | ||
| 654 | default: | ||
| 655 | throw new ArgumentException("Unknown platform enumeration '{0}' encountered.", this.CurrentPlatform.ToString()); | ||
| 652 | } | 656 | } |
| 653 | 657 | ||
| 654 | foreach (var attrib in node.Attributes()) | 658 | foreach (var attrib in node.Attributes()) |
| @@ -768,6 +772,9 @@ namespace WixToolset.Core | |||
| 768 | case "arm": | 772 | case "arm": |
| 769 | platform = "Arm"; | 773 | platform = "Arm"; |
| 770 | break; | 774 | break; |
| 775 | case "arm64": | ||
| 776 | platform = "Arm64"; | ||
| 777 | break; | ||
| 771 | case "": | 778 | case "": |
| 772 | break; | 779 | break; |
| 773 | default: | 780 | default: |
| @@ -813,13 +820,13 @@ namespace WixToolset.Core | |||
| 813 | this.Core.Write(ErrorMessages.IllegalAttributeWithOtherAttribute(sourceLineNumbers, node.Name.LocalName, "InstallPrivileges", "InstallScope")); | 820 | this.Core.Write(ErrorMessages.IllegalAttributeWithOtherAttribute(sourceLineNumbers, node.Name.LocalName, "InstallPrivileges", "InstallScope")); |
| 814 | } | 821 | } |
| 815 | 822 | ||
| 816 | if ((0 != String.Compare(platform, "Intel", StringComparison.OrdinalIgnoreCase)) && 200 > msiVersion) | 823 | if ((String.Equals(platform, "X64", StringComparison.OrdinalIgnoreCase) || String.Equals(platform, "Intel64", StringComparison.OrdinalIgnoreCase)) && 200 > msiVersion) |
| 817 | { | 824 | { |
| 818 | msiVersion = 200; | 825 | msiVersion = 200; |
| 819 | this.Core.Write(WarningMessages.RequiresMsi200for64bitPackage(sourceLineNumbers)); | 826 | this.Core.Write(WarningMessages.RequiresMsi200for64bitPackage(sourceLineNumbers)); |
| 820 | } | 827 | } |
| 821 | 828 | ||
| 822 | if ((0 == String.Compare(platform, "Arm", StringComparison.OrdinalIgnoreCase)) && 500 > msiVersion) | 829 | if ((String.Equals(platform, "Arm", StringComparison.OrdinalIgnoreCase) || String.Equals(platform, "Arm64", StringComparison.OrdinalIgnoreCase)) && 500 > msiVersion) |
| 823 | { | 830 | { |
| 824 | msiVersion = 500; | 831 | msiVersion = 500; |
| 825 | this.Core.Write(WarningMessages.RequiresMsi500forArmPackage(sourceLineNumbers)); | 832 | this.Core.Write(WarningMessages.RequiresMsi500forArmPackage(sourceLineNumbers)); |
diff --git a/src/WixToolset.Core/ExtensibilityServices/PreprocessHelper.cs b/src/WixToolset.Core/ExtensibilityServices/PreprocessHelper.cs index bdf11879..e84bb001 100644 --- a/src/WixToolset.Core/ExtensibilityServices/PreprocessHelper.cs +++ b/src/WixToolset.Core/ExtensibilityServices/PreprocessHelper.cs | |||
| @@ -244,6 +244,9 @@ namespace WixToolset.Core.ExtensibilityServices | |||
| 244 | case Platform.ARM: | 244 | case Platform.ARM: |
| 245 | return "arm"; | 245 | return "arm"; |
| 246 | 246 | ||
| 247 | case Platform.ARM64: | ||
| 248 | return "arm64"; | ||
| 249 | |||
| 247 | default: | 250 | default: |
| 248 | throw new ArgumentException("Unknown platform enumeration '{0}' encountered.", context.Platform.ToString()); | 251 | throw new ArgumentException("Unknown platform enumeration '{0}' encountered.", context.Platform.ToString()); |
| 249 | } | 252 | } |
