-
Notifications
You must be signed in to change notification settings - Fork 122
Refine Apple Silicon / CocoaPods workaround #549
Conversation
This PR is a draft because I’m still verifying that the workaround has the expected behavior when integrated into a project and built in various configurations. |
|
@1ec5 could you provide an update when you have a chance? I can't take the suspense. Thanks! |
c88e314
to
7f6d075
Compare
(Sorry for the radio silence; didn’t see the update until I force-reloaded the page. 🤐) All the scenarios in #549 (comment) now pass with the test pod in both our internal dogfooding application and a real-world project that a customer provided. We were close, but the affected projects had a blank After we incorporate the changes in this PR in a new release of the map SDK, if any developer continues to see the linker error in mapbox/mapbox-navigation-ios#2739 (comment), they’ll need to manually clear that |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I also tested pod lib lint
on my Apple Silicon DTK, it's ok.
I dislike using s.user_target_xcconfig
. It changes the user's target build setting without the user's knowledge. Is there a better solution way to do it?
Not that I know of; this is pretty much a last resort to work around CocoaPods/CocoaPods#10065 CocoaPods/CocoaPods#10104 until we fix #171. In fairness, the CocoaPods developers prefer that we avoid setting |
I hotfixed v6.2.2 using the following commands: git checkout ios-v6.2.2
patch -p1 -i excludearchs.patch
pod repo update
pod trunk delete Mapbox-iOS-SDK 6.2.2
make idocument OUTPUT=6.2.2 JAZZY_CUSTOM_HEAD="<script src='https://docs.mapbox.com/analytics.js'></script>"
git stash
git checkout publisher-production
git add 6.2.2
git commit -m '6.2.2 [ci skip]'
git push
git checkout -
git stash pop
pod trunk push platform/ios/Mapbox-iOS-SDK.podspec These commands resulted in CocoaPods/Specs@bce50de deleting v6.2.2 and CocoaPods/Specs@ec2ac3f restoring v6.2.2 with the hotfix:
|
I similarly hotfixed v6.3.0, deleting it in CocoaPods/Specs@721f34a and restoring a patched podspec in CocoaPods/Specs@64d7704:
|
🔥 🔥 thank you @1ec5 for running with those manual hotfixes! 🔥 🔥 |
If anyone is getting errors or warnings installing either v6.2.2 or v6.3.0 using CocoaPods, try the following commands: rm -rf ~/Library/Caches/CocoaPods/Pods/
rm -rf ~/.cocoapods/repos/trunk/Specs/a/5/9/Mapbox-iOS-SDK/
pod repo update
pod update |
The CocoaPods podspec now excludes 64-bit ARM architectures less aggressively with build settings that match the iOS navigation SDK. The new build setting takes into account the native architecture of the build machine, the Xcode major version, and the target environment.
I pushed a clone of this podspec to a throwaway pod to CocoaPods trunk in CocoaPods/Specs@a1b0a72. I also pushed a clone of the navigation SDK podspec that depends on this throwaway pod in CocoaPods/Specs@c641e30.
Fixes mapbox/mapbox-navigation-ios#2739.
/cc @mapbox/navigation-ios @julianrex @ZiZasaurus @frederoni