-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
Difficulty compiling 15.1.0 from objective-c code #2140
Comments
I am experiencing the same issue when trying to make this SDK work with UE, did you find any solutions to this problem? |
No, I did not find a workaround, I'm stuck at 15.0.0. No response yet from maintainer(s) - though I see a commit from @samodom on Nov 8 and this was logged on Nov 2. Sam, I am not implying any expectation of response time with that comment, just saying as a general statement "the repository seems alive, Sam was here after the issue, perhaps it will get attention eventually" :-). Cheers |
I have actually found the solution, you should add respective imports to the files that yield errors.
…On 16 Dec 2022, 19:39 +0200, Mike Hardy ***@***.***>, wrote:
No, I did not find a workaround, I'm stuck at 15.0.0. No response yet from maintainer(s) - though I see a commit from @samodom on Nov 8 and this was logged on Nov 2. Sam, I am not implying any expectation of response time with that comment, just saying as a general statement "the repository seems alive, Sam was here after the issue, perhaps it will get attention eventually" :-). Cheers
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you commented.Message ID: ***@***.***>
|
@TarasOsiris can you be more specific, perhaps with an example or a diff or similar? I feel like I tried most things, but I must be unaware of the exact technique you mention as it did not occur to me and I'm not sure exactly what you mean. Thanks in advance if you can |
Hello, I've had this issue and spent couple hours debugging as well... Just figured out that AppDelegate extension ended in https://stackoverflow.com/questions/29142045/module-not-recognized-in-xcode-project |
You should consider adding the appropriate XCode frameworks to your build: SafariServices and AuthenticationServices. |
Just remember to put the import statements (shared by @muhachev) before the Big thanks to this comment. |
Checklist before submitting a bug report
Xcode version
14.0
Facebook iOS SDK version
15.1.0
Dependency Manager
CocoaPods
SDK Framework
Core
Goals
I am the maintainer of react-native-fbsdk-next (the current FBSDK wrapper, we drive a lot of SDK usage 😄 - 64,000+ package downloads a week it appears https://www.npmjs.com/package/react-native-fbsdk-next )
I am trying to update our wrapper to use facebook-ios-sdk 15.1.0, it worked with 15.0.0
We are still written in Objective-C, and need swift/objc interop to work well
Currently we advise people that do deep-linking to import the module in AppDelegate.mm like so:
I understand from other issues that
@import FBSDKCoreKit;
is the recommended objc interop way of doing it but:(same as noted in following comments on that issue linked just above: #2043 (comment))
So the goal is just to get the react-native-fbsdk-next obj-c code compiling correctly vs v15.1.0 here in a react-native-compatible way
Expected results
A successful compile
Actual results
Steps to reproduce
I think the best way to reproduce might be to try the PR I have open in our example app, I am not 100% of the best way to do it, but I think this might work:
That should reproduce the errors above.
RNFBSDKExample/ios/AppDelegate.mm
has the integration with import. If you change it to swift@import
style you get the c++ modules issue.Perhaps there is a way to add an
@obj protocol
interop specifier or similar in FBSDKCoreKit? Perhaps there is something I/we could put in our podspec that would help?It is possible to play with possibilities by reaching directly in to
RNFBSDKExample/node_modules/react-native-fbsdk-next
and altering things (like perhaps the podspec to add compiler flags)I wish I had more Obj-C/Swift interop experience but hopefully, since we (me, really at this point) are now maintaining the facebook module for react-native after it was pulled out of the main facebook/meta repos you will take pity on my and help keep it going, I would certainly appreciate it
Code samples & details
The text was updated successfully, but these errors were encountered: