Unverified Commit ab6f2fc8 authored by Jenn Magder's avatar Jenn Magder Committed by GitHub

Set BUILD_DIR when determining if plugins support arm64 simulators (#90088)

parent bf66cc2e
......@@ -499,6 +499,13 @@ void _validateIosPodfile(String appPath) {
'test_plugin_swift',
'ios',
));
// Make sure no Xcode build settings are leaking derived data/build directory into the ios directory.
checkDirectoryNotExists(path.join(
appPath,
'ios',
'build',
));
}
void _validateMacOSPodfile(String appPath) {
......
......@@ -228,6 +228,7 @@ class XcodeProjectInterpreter {
return null;
}
final Status status = _logger.startSpinner();
final String buildDirectory = _fileSystem.path.absolute(getIosBuildDirectory());
final List<String> showBuildSettingsCommand = <String>[
...xcrunCommand(),
'xcodebuild',
......@@ -237,6 +238,8 @@ class XcodeProjectInterpreter {
'-project',
podXcodeProject.path,
'-showBuildSettings',
'BUILD_DIR=$buildDirectory',
'OBJROOT=$buildDirectory',
];
try {
// showBuildSettings is reported to occasionally timeout. Here, we give it
......
......@@ -3,4 +3,5 @@
**/Pods/
# Xcode-related
**/dgph
**/xcuserdata/
......@@ -695,6 +695,7 @@ Information about project "Runner":
final Directory podXcodeProject = project.ios.hostAppRoot.childDirectory('Pods').childDirectory('Pods.xcodeproj')
..createSync(recursive: true);
final String buildDirectory = fileSystem.path.absolute('build', 'ios');
fakeProcessManager.addCommands(<FakeCommand>[
kWhichSysctlCommand,
kARMCheckCommand,
......@@ -710,6 +711,8 @@ Information about project "Runner":
'-project',
podXcodeProject.path,
'-showBuildSettings',
'BUILD_DIR=$buildDirectory',
'OBJROOT=$buildDirectory',
],
stdout: '''
Build settings for action build and target plugin1:
......@@ -748,6 +751,7 @@ Build settings for action build and target plugin2:
final Directory podXcodeProject = project.ios.hostAppRoot.childDirectory('Pods').childDirectory('Pods.xcodeproj')
..createSync(recursive: true);
final String buildDirectory = fileSystem.path.absolute('build', 'ios');
fakeProcessManager.addCommands(<FakeCommand>[
kWhichSysctlCommand,
kARMCheckCommand,
......@@ -763,6 +767,8 @@ Build settings for action build and target plugin2:
'-project',
podXcodeProject.path,
'-showBuildSettings',
'BUILD_DIR=$buildDirectory',
'OBJROOT=$buildDirectory',
],
exitCode: 1,
),
......@@ -789,6 +795,7 @@ Build settings for action build and target plugin2:
final Directory podXcodeProject = project.ios.hostAppRoot.childDirectory('Pods').childDirectory('Pods.xcodeproj')
..createSync(recursive: true);
final String buildDirectory = fileSystem.path.absolute('build', 'ios');
fakeProcessManager.addCommands(<FakeCommand>[
kWhichSysctlCommand,
kARMCheckCommand,
......@@ -804,6 +811,8 @@ Build settings for action build and target plugin2:
'-project',
podXcodeProject.path,
'-showBuildSettings',
'BUILD_DIR=$buildDirectory',
'OBJROOT=$buildDirectory',
],
stdout: '''
Build settings for action build and target plugin1:
......
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