Open mlfairy opened 4 years ago
Ok, seems this happens when i include Promises with any MacOS app. I have a link to a project which shows the problem.
I simply created a new macos app, added a Podfile, and added Promises as a dependency.
I forked the repo, and submitted a PR for what I believe fixes this issue.
My understanding is that the custom modulemap file that's defined in the FBLPromises target is not used by Cocoapods (which instead is generating its own umbrella header, duplicating the includes).
In the same sample app i provided in the previous comment, I instead changed my podfile to point to my fork. This seemed to clean up the problem.
# Uncomment the next line to define a global platform for your project
# platform :ios, '9.0'
target 'TestPromises' do
# Comment the next line if you don't want to use dynamic frameworks
use_frameworks!
pod 'PromisesObjC', :git => "https://github.com/mlfairy/promises.git"
pod 'PromisesSwift', :git => "https://github.com/mlfairy/promises.git"
# Pods for TestPromises
end
Friendly ping here - @mlfairy are you still using your custom fork? @tristane0 what do you think of merging this PR?
Apologize for the extremely long delay in following up on this. Before merging, can we test with the latest versions of cocoapods and Xcode for both iOS and macOS? May also want to test without the change too just to make sure it’s still required.
Thank you!
hi @eytanbiala I was up until a few weeks ago. Then i moved over to using combine. thanks for checking in!
I was able to reproduce mlfairy's issue with Cocoapods version 1.7.5, but the issue appears to have been fixed in more recent Cocoapods version, and pod spec lint
passes with Cocoapods version 1.9.2. I was unable to track down the specific Cocoapods fix that addressed this, but also did not spent much time searching.
Repro steps:
pod lib create Foo
to create a framework targeting OSX,s.osx.dependency "PromisesSwift", "~> 1.2.8"
pod spec lint --no-clean --fail-fast --verbose --allow-warnings --platforms=macos
Even though this issue was addressed by some Cocoapods update, it may be preferable to specify s.module_map since Promises provides a custom module map. But I haven't had a chance yet to verify this across the various platforms.
@eytanbiala it sounds like your issue was not identical (it doesn't sound like you're maintaining a framework distributed through Cocoapods)... are you still having issues with this?
Hi, I'm sorry to cross post this with stackoverflow, but there was no tag related to google-promises.
I'm working on a framework that uses promises internally, and I'd like the framework to work cross platform for iOS, macos and tvOS.
When building my framework for distribution with cocoapods, the lint check is failing specifically for macos, but not the other platforms.
I've described the error in this ticket: https://stackoverflow.com/questions/58171317/umbrella-header-for-module-fblpromises-does-not-include-header-headers-promi
If I can get some help, i'd very much appreciate it.