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
Unable to import OS X frameworks using private headers and header_mappings_dir #5313
Comments
If I understand, this is only an issue for OS X? |
Yes, because it fails just because of the missing symlink, which is only present in the framework structure used by OS X. |
Joy 😭 |
I see two ways how we could solve that:
Adding a dummy header like in 1. outside of the But it is possible to partially work around that from the podspec as seen below, but this doesn't follow the exact structure and could theoretically break AppStore-compatibility if not already now then possibly in the future. s.osx.pod_target_xcconfig = {
'PUBLIC_HEADERS_FOLDER_PATH' => '$(WRAPPER_NAME)/Headers',
'PRIVATE_HEADERS_FOLDER_PATH' => '$(WRAPPER_NAME)/PrivateHeaders'
} Note that the |
I guess let's look into a build phase to make the symlinks? |
What did you do?
Integrated Realm in an OS X target.
What did you expected to happen?
The integrating target would build.
What happened instead?
The generated pod target for Realm itself builds, but it can't be imported. Clang complains about missing headers from the module map:
Inspecting the build products and comparing them with the binaries we build ourselves from our Xcode project, it turns out, that the
PrivateHeaders
symlink in the root directory of the framework bundle is missing. While the actualPrivateHeaders
dir exists withinVersions/A
. My suspicion is that the custom copy files build phase, which ensures to retain the header layout of theheader_mappings_dir
creates thePrivateHeaders
directory in a way Xcode doesn't expect, preventing the automatic creation of the symlink.So this seems to be an instance of a more general error, which is only relevant for podspecs using
header_mappings_dir
, a custom module map and private headers, which are explicitly declared in the module map.CocoaPods Environment
Project that demonstrates the issue
https://github.com/realm/realm-cocoa-converter/tree/to-0.102.0-update
The text was updated successfully, but these errors were encountered: