SoundCloud iOS SDK fails to find all header files. libSoundCloudUI/CocoaSoundCloudUI - ios

I have spent hours over the past week trying to figure out why SoundCloud suddenly stopped working in an app I'm working on. Figuring it might have been file-location related, I completely removed it and re-added the submodules. Then re-added after that didn't work. Then re-added. Then searched. Then nothing.
I've tried re-adding the SoundCloud submodules, and have followed the directions on the SoundCloud site to the T, and still, I get compiler error after error, warning after warning. I add the linker flags as stated, and include the needed frameworks and dependencies. I have absolutely no idea why I'm getting missing file errors.
Changing the Header Search Path (in either MY project file or libSoundCloudUI) just shifts what file can't be found, and when I somehow manage to get SoundCloud to compile with my program, anytime I commit my changes to my Git repository, the submodules are lost and the next person to open the project doesn't have the code, thus making me start over. Pointing the header search path directly to the source code doesn't work, even when it's recursive.
What could be happening? No matter what I do, specifically CocoaSoundCloudUI
Some of the errors I've been getting:
Use of undeclared identifier: 'kTermsofService' (This has a few other keys that aren't being found)
Header file not found: <insert random file include in headers and in source folder>
If my app didn't need SoundCloud support I would have dropped it already. This has been such a nightmare - any help would make my life a lot easier.

Hi Sean Michael Dorian,
indeed, we have updated CocoaSoundCloudAPI and CocoaSoundCloudUI lately and according to your error message you have not updated both repos, i.e. you need to run
git submodule update --init --recursive.
If you have issues w/ submodules in general I recommend you switching to CocoaPods it turns the management of your library dependencies into a no-brainer.
We also provide a Demo Xcode project to check out such a setup.
This should help you resolving the issues let me know if you are missing anything there.

Related

Transferring Xcode Project from one computer to another brings random errors?

I have a Xcode project I got from another developer. Initially when I opened it it has a bunch of errors (most of which were un-updated frameworks). I got it to work after a while and I fixed it. I want pass it back to the manager since I'm leaving uni in a few months. I copied it over to my friends Mac to see what would happen if I just took the project and all it's folders and made it a zipfile. It didn't work for some reason. It gave me an error:
error: using bridging headers with framework targets is unsupported
But why did that come up? I mean it's the same code on the slightly different versions of Xcode (13.1 versos 14.1) but I doubt there was a massive change between the two that would cause this. I want to be able to pass these app later in the future without having to care about this stuff. I made a GitHub (link below) would cloning that work? Also the laptop I chose was just a fresh reset. Would it be due to not having coco-pods installed?
I feel like I could go through and fix it all on that laptop and document that but then I'm afraid that every time I put it on a new one it would come up with random errors every single time making my documentation moot.
https://github.com/AbdullahMSaid/SonicExperiment-Works
With big help this was Fixed.
Things that fixed it.
Having the correct version of Xcode
Turning everything from absolute path to relative
Lots of other code fixes. But those are my project specific.
You don't need bridging headers in framework. Use should have something like "YourFramework.h" where you can import your .h files.

FBSDKCore can't find RCTBridgeModule.h

In my project I am having a problem with the fbsdk. Upon linking the fbsdkcore to my project in xcode using the rnpm as shown here: https://facebook.github.io/react-native/docs/linking-libraries-ios.html
My build now fails due to my RCTFBSDKCore cannot find the RCTBridgeModule.h, even though I think I have gone through all the neccessary steps to include this, even in the Header Search in build settings as shown below:
Linking Binary w/ Lib:
And the Header Search:
After this I am quite lost. I have also tried to update all of my packages without success. And as one can see in the picture below, I have two fbsdkcore, is this one too many, because it is only when I try to build the RCTFBSDKCore that it fails, it is successfull in the other case.
Ok, so to my question. Could it be that the library should not be included like that in the first place? If not, what have I done wrong/missed?
rnpm does not support linking multiple libraries at the moment. Check this article for setting up RN & fbsdk.

More FacebookSDK/Facebook.h issues - file not found

Alright, guys. I'm going freakin' crazy with this one. It is utterly ridiculous that the FacebookSDK causes so many issues. I know there are a couple questions on here regarding this issue, but they all seem to be outdated.
I pulled my Xcode project onto a new computer, and can't build it because I get the "FacebookSDK/FacebookSDK.h" file not found error. There are answers such as This one, but I've followed the steps in every single answer and haven't found one that works. I've just made a fresh pull from my working project from the original machine to the new one. I'll take some screenshots showing my current settings for various fields mentioned in other answers, and maybe I Just have something wonky that is interfering.
Here are the contents of the SDK that I just downloaded
Here are the contents of my Xcode project folder. There isn't anything else Facebook in here.
Here are the frameworks inside my Frameworks group and inside the Link Binary with Libraries section of Build Phases
There are a couple frameworks that are red, and that's OK for now. They were not in the repo, and are instead referenced from Documents or Downloads, and they played nice when I moved the files over and linked them. I just reset my repo to when I pulled it to make sure I didn't have anything from weird stuff I tried that prevents a proper solution from working.
Framework search paths. You can also see that my library search paths is empty. I labeled the stuff I wanted to hide, as it was identifying information
For some reason, my Documents for the new machine is already under the framework search paths. I did not add this myself.
Any ideas on what I can try? This is endlessly frustrating. I've wasted an entire day of development on trying to get Facebooks SDK re-integrated on a new machine.
I was also face the same problem every time I got the checkout for new version from svn.What I did was just removed the Facebook SDK and add again from the backup.It taken me out that time.Please try this might be it works for you.

Xcode Pinterest.h file not found

So I have looked high and low for a fix for this and nothing seems to work. I have a a project that works 100%, but when I transfer it over to another mac I get the following error. Pinterest.h file not found. However this file is in fact present and makes no sense why I am getting this error. I have tried cleaning build, cleaning build folder, restarting xcode, checking build paths and I simply cannot figure out this issue. Here is an image of the error
and here is an image of the class that is causing the error
Literally any help on this would be amazing, I am using sharekit if that helps at all.
Are you sure you have Pinterest.h included in the actual project? It could be that, on your second device, you forgot to include the Pinterest.h as a file inside the project itself. It might be within the directory structure, but that doesn't mean that it's included in the Xcode project.
With the limited images you provided, it's really hard to tell one way or the other. Can you provide more information/images?

YouTube integration issue in iOS SDK

I am integrating YouTube in my app in which I have to login the user for authentication.I got a sample code that is working fine.When I started integrating that code in my app then I am getting some issues.
First:-
When I run the same code in a sample app I made then its telling GTLYouTube.h file missing.I am unable to know how that sample is working even though it does not have that file.
Second:-
Subsequently I added the downloaded file from svn checkout svn checkout http://google-api-objectivec-client.googlecode.com/svn/trunk/ google-api-objectivec-client-read-only and added the files in my app.
Then although the GTLYouTubeConstants.m is present as I can see in Services->Youtube->Generated I am getting error that GTLYouTubeConstants.m file not found.
I am unable to find while compiler is unable to find the file.Is there anything wrong in my implementation?
Finally I came up with the solution.I need to make a lot of changes in the code which I will write in steps so that it can be helpful for others.
The main problem I got in GTLYouTube_Sources.m,GTLCommon_Sources.m and GTLNetworking_Sources.m.When I used these files from the Sample App the files were missing and I was getting message like GTLYouTubeConstants.m file not found in GTLYouTube_Sources.m file.From the comments of developer in the GTLYouTube_Sources.m I came to know that I can't directly use these files.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
So I downloaded the files from svn checkout http://google-api-objectivec-client.googlecode.com/svn/trunk/google-api-objectivec-client-read-only and added the files in my app.Then again I got that error but when I removed the GTLYouTube_Sources.m,GTLCommon_Sources.m and GTLNetworking_Sources.m files form the project then the error gone(since I have already added the needed files).
Then again I got the duplicate symbol _OBJC_METACLASS_$ (linker error).Then I had to remove the GTLYouTube_Sources.m from Services->YouTube->Generated folder and the error gone.
I had made some other changes along with this:
I changed my header search path to same that used in Sample App.Also I changed my framework search path to $(SDKROOT)/Developer/Library/Frameworks $(inherited) $(DEVELOPER_FRAMEWORKS_DIR) and I removed all the test files and didn't use any test framework as we can see in the downloaded files.
May be my solution is not proper but it let the code running so please suggest me any improvement needed.

Resources