Skip to content

Commit

Permalink
Fix: Duplicated Signature issue with Xcode 15 #12022
Browse files Browse the repository at this point in the history
  • Loading branch information
tyrauber committed Jan 31, 2024
1 parent 62f118f commit 20b87b5
Showing 1 changed file with 20 additions and 1 deletion.
21 changes: 20 additions & 1 deletion plugin/src/withMapLibre.ts
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,28 @@ export function setExcludedArchitectures(project: XcodeProject): XcodeProject {
// Using `project.addToBuildSettings` modifies too many targets.
if (typeof buildSettings?.PRODUCT_NAME !== 'undefined') {
buildSettings['"EXCLUDED_ARCHS[sdk=iphonesimulator*]"'] = '"arm64"';

/**
* Delete Duplicate Signature File
* https://github.com/CocoaPods/CocoaPods/issues/12022
*/
const shellScript = `if [ "$XCODE_VERSION_MAJOR" = "1500" ]; then
echo "Remove signature files (Xcode 15 workaround)";
rm -rf "$BUILD_DIR/Release-iphoneos/Mapbox.xcframework-ios.signature";
fi`;

project.addBuildPhase(
[],
'PBXShellScriptBuildPhase',
'Remove signature files (Xcode 15 workaround)',
null,
{
shellPath: '/bin/sh',
shellScript,
},
);
}
}

return project;
}

Expand Down

0 comments on commit 20b87b5

Please sign in to comment.