Unverified Commit 7c24ebc7 authored by Jenn Magder's avatar Jenn Magder Committed by GitHub

Map arm64e devices to arm64 devices (#50612)

parent 781cd4d8
......@@ -142,7 +142,7 @@ class AOTSnapshotter {
genSnapshotArgs.add('--no-use-integer-division');
}
// The name of the debug file must contain additonal information about
// The name of the debug file must contain additional information about
// the architecture, since a single build command may produce
// multiple debug files.
final String archName = getNameForTargetPlatform(platform, darwinArch: darwinArch);
......
......@@ -390,6 +390,7 @@ DarwinArch getIOSArchForName(String arch) {
case 'armv7':
return DarwinArch.armv7;
case 'arm64':
case 'arm64e': // iPhone XS/XS Max/XR and higher. arm64 runs on arm64e devices.
return DarwinArch.arm64;
case 'x86_64':
return DarwinArch.x86_64;
......
......@@ -85,4 +85,12 @@ void main() {
expect(getNameForTargetPlatform(TargetPlatform.ios, darwinArch: DarwinArch.x86_64), 'ios-x86_64');
expect(getNameForTargetPlatform(TargetPlatform.android), isNot(contains('ios')));
});
test('getIOSArchForName on Darwin arches', () {
expect(getIOSArchForName('armv7'), DarwinArch.armv7);
expect(getIOSArchForName('arm64'), DarwinArch.arm64);
expect(getIOSArchForName('arm64e'), DarwinArch.arm64);
expect(getIOSArchForName('x86_64'), DarwinArch.x86_64);
expect(() => getIOSArchForName('bogus'), throwsAssertionError);
});
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment