-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Revert creation of module maps for static libraries #3898
Conversation
@@ -71,40 +71,18 @@ def implode! | |||
# @return [Array<Pathname>] | |||
# | |||
def add_files(namespace, relative_header_paths, platform) | |||
relative_header_paths.map do |relative_header_path| |
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 think these changes were fine, though?
create_umbrella_header do |generator| | ||
generator.imports += target.file_accessors.flat_map(&:public_headers).map(&:basename) | ||
end | ||
link_module_map |
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.
What about Pods that provide custom module maps? If the pod provides the module map, then CocoaPods should still be able to link it safely in the sandbox. It's the generated ones that are the problem.
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.
Realm has a custom module map, and we got reports of issues as well
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.
The ENABLE_CLANG_MODULES
issue is just the ultimate reason why this cannot work at all for generated module maps, there were apparently other practical issues with this change in some situations.
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.
Got it. Yep, I can see at least one reason why the Realm pod broke: it finds both the original modulemap and the module map in Headers/Public. :(
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.
Looked into trying to get this to work tonight, and no dice.
I'm good with this 👍 |
Also, rescue unknown extensive analysis exceptions and nicely error on them
Originally from 5121dff
b2d1e78
to
73c779d
Compare
@@ -12,6 +12,17 @@ To install release candidates run `[sudo] gem install cocoapods --pre` | |||
headers. | |||
[Russ Bishop](https://github.com/russbishop) | |||
[#3893](https://github.com/CocoaPods/CocoaPods/issues/3893) | |||
##### Fixed |
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.
belongs in the bug fixes section?
👍 |
…tic-libraries Revert creation of module maps for static libraries
Changes Unknown when pulling c17f843 on revert-module-support-for-static-libraries into ** on master**. |
Reverts #3878
Fixes #3879, #3888, #3884, #3886, #3889
Most importantly, we actually cannot support this feature in CocoaPods, because of how
ENABLE_CLANG_MODULES
works. This option is enabled by default, but acts a little bit different from its documentation in that it will automatically convert all imports of headers outside of the given target to module imports if a module exists. So the generated modules wouldn't be opt-in, but automatically used. Since not all Pods are working as modules, this makes this change unsuitable.Integration spec PR: CocoaPods/cocoapods-integration-specs#42