vimeo advanced api for iOS - ios

I have used OA consumer class in my app and while trying to run it i got this error and i dint understand the problem. i have added -ObjC to other linker flags also. i have searched google but dint find any related to this. I have disabled the arc and do i need to add any linker flags or is there any other problem.
can you please tell me whether there is an error in code or do i have to change the linker settings

These are linker errors -- it's finding the headers just fine, but the library is missing at link time. Make sure the OA library is in the Linked Frameworks and Libraries list for your target.

I removed this error after lots of trails, the problem in my case is the corefoundation framework is corrupted, it has shown a small question mark on it, after i carefully read the exception, it says that some files are missing from the corefoundation framework, then i removed the framework and copied a new one from another project then the errors gone.
Note: while you are removing any file, don't just remove references , move it to trash, other wise the Xcode may give you a error file already exist and cannot be copied.

Related

XCODE Swift 5.0 Frameworks Problems -ObjC and FacebookSDK

I'm developing an iOS (>=13.0) app, it's already on the App Store etc...
The problem is that today I've tried to implement the Facebook SDK to permit me to create ad on Facebook and Instagram, I've added the FacebookCore CocosPod and then, as the guide said, I've added on "Other Linker Flags" the flag "-ObjC", since I've added this flag nothing worked, nothing.
I've got several time this error:
ld: 665 duplicate symbols for architecture x86_64 clang: error: linker command failed with exit code 1 (use -v to see invocation)
and all my frameworks files became red.
I've tried to clean up my code, the project, the pod file, I've also removed some pods and the I've put them back because I read some treads where they said it could be a duplicate problem.
After returning to my original podfile I don't have this issue of "duplicate symbols..." but some components of the library (MDCSnackbarManager) don't work and all frameworks files still reds.
I honestly really need your help because I don't know what to do...
Thanks you, please help me.
UPDATE
I didn't solve the problem, since all the project seems to be corrupted and nothing works as should...
As I mentioned before I've tried to reload the project from a previous backup on GitHub.
Now I'm doing well, the project works and so I tried to check the differences between this project and the corrupted one, but nothing, they are identical in all shades, even the flags are all the same, I've checked all of them in both project.
I'm now pretty confused about the cause of all these problems, I'll figure out what happened and if I'll find something I will tell you.
If you have any idea I'll read it and try to figure out if it will work.
At the moment what I can tell you is to NOT set the flag "-ObjC" and install the FacebookCore pod, don't do that.

Why am I receiving Apple Mach-O linker (ld) error when I use ffmpeg in iOS Xcode project?

I am getting all these errors I have no idea why I hope you can help me guys.
I have included "avformat.h" in bridging header
I have included all frameworks/libraries needed too
Make sure you have all required includes and they are included inside extern, you may be seeing name mangling going on. Read this https://trac.ffmpeg.org/wiki/Including%20FFmpeg%20headers%20in%20a%20C%2B%2B%20application
This is one possibility if you have already made sure that libraries are in path and included.

Duplicate symbol(s) for architecture(s) [arm7, arm64]

I have imported a new version of a framework in my SDK. Anyway, I am not able to build on iPhone 6 running iOS 9.0.1 because of the following error that's driving me crazy:
duplicate symbol _IPDJobStatus in:
/Users/akiki/Desktop/iOS 9 Test/MPSDK/iPD.framework/iPD(IPDDevice.o)
/Users/akiki/Desktop/iOS 9 Test/MPSDK/iPD.framework/iPD(IPDAdministration.o)
ld: 5 duplicate symbols for architecture arm7
clang: error: linker command failed with exit code 1 (use -v to see invocation)
This is happening for the same symbol _IPDJobStatus being found twice in 5 files. The same is happening on iPhone 4S running iOS 9.1 with arm64 architecture. To import the framework, I deleted the old one from the project, imported the new one and check into the Link Binary with Library section wether the framework reference links to the correct updated file. Before asking I have tried to perform the following actions:
I searched for the duplicate symbol inside the project scope with no result.
I'm not importing a .m file by accident.
The Compile Sources of the Build Phases project settings doesn't include any duplicate file.
The framework headers references in Headers of the Build Phases project settings link to the proper files.
I tried to clean the project, empty the Derived Data folder, quit and relaunch Xcode.
I added the -ObjC linker flag (in this case the duplicate symbols goes from five to only one).
I switched the No Common Blocks compiler setting to NO, though it has the same error with or without it.
I created a new empty project and imported the framework there. In this case I was able to build, so the problem must resides in my SDK.
Could someone please give me some help?
You can check your project directory may be there available framework. If available then delete it.
I was able to solve the same problem with the following code.
Add this to the Library Search Paths in Build Settings and make sure you select recursive, delete other library paths which might be absolute paths.
$(PROJECT_DIR)
May be it will help you.
You can not make constant type variables of same name & type in two or more classes.
_IPDJobStatus is this constant type variable?
change it to some other name for different classes.
Here you can see the same issue
It means in you project multiple copy of same View Controller instance (i,e means duplicate).
Possible observation:
This IPDJobStatus variable contains in the class IPDDevice or IPDAdministration of the framework is duplicate. Please check this.
Note: You should not have/create a class which already have in any other framework either Xcode's default or 3rd party framework.
For example: UIkit framework have class name "UIApplication" (i.e UIApplication.h, and UIApplication.m). So, if you create you class name "UIApplication". this error will occur. Same case for also 3rd party framework.

Undefined symbol "_OBJC_CLASS_$_CkoFtp2" link error with chilikat

When I'm writing simple code in ViewController, I wanted to run it and boom. Apple Mach-O linker error as shown. I don't know what is the problem. Then, I've made a quick research, according to research; I deleted Derived Data folder, I deleted Derived Data folder contents, I deleted test hosts in build settings(it is already empty), I cleaned the build folder and I applied clean action. But nothing changed same errors. Is there any specific solution of this error depends on app and what is that solution?
EDIT:
I moved the codes to a new xode project and I noticed that when I add the line let ftp = CkoFtp2(), the error occurs otherwise it compiles. But it is coloring the CkoFtp() part of line and I'm not getting any specific errors there. Just Match-O and linker command.You can see the CkoFtp2 code here.
I had the same issue. Please make sure to follow the directions on chilkat's site, particularly the following:
Add libChilkatCocoa.a to your list of libs for linking. In your project build settings, find Build Phases, Link Binary with Libraries, select Add Other, navigate to the libChilkatCocoa.a, and add it.
The Chilkat library internals are written in C++. Therefore, your Swift application will need to link against the C++ runtime libraries. In your Build Settings, go to the Linking section and add -lstdc++ to the Other Linker Flags.
https://www.chilkatsoft.com/chilkatSwiftCocoa.asp
I also ran into trouble because the libChilkatCocoa.a library resided in a folder that had a space in its name. Avoid that, or make sure it is correctly escaped under Build Settings.
Looks like you've got a reference to a framework located in your Downloads folder. Chances are you moved that somewhere else, yes? Remove the SimpleUnzipper framework from the project and re-add it from wherever you moved it to.
After the edits, this is clearly not the problem...
It's hard to tell from just the error message, but it appears that you're using a library that you downloaded from another developer. Are you sure you followed their instructions for setting things up? The linker error means that you're not linking your program with the library, though it looks like you've managed to set up a bridging header so that you can call the function without getting a compiler error.

Significance of -ObjC value in Other Linker Flags: GMaps SDK

I was trying out google maps sdk integration with iOS 6.1. I am successfully able to populate gmap on iOS simulator by using instructions given on
GMaps for iOS starting guide
Then what the issue with it:
It works great when I use it as a separate project. But when I club the above project code with my existing application, then it behaves weird, and all the errors generates due to inclusion of -ObjC value in Other Linker Flags in Build Settings.
Error
duplicate symbols for architecture i386
When I skip step 7 (GMaps iOS), it doesn't give errors. Due to exclusion of -ObjC value, it doesn't able to identify a specific GMaps library class and its method:
[GMSCameraPosition cameraWithLatitude:longitude:zoom:]: unrecognized selector sent
My iOS application background:
Using a third party library SUP (Sybase Unwired Platform). Connecting SAP to iOS application. I guess there is something ambiguous with SUP environment enablement (Build settings) when I am trying to add GMaps library.
Seeking for your advices.
Thanks!
There many posts on SO about the duplicate symbols for architecture i386 error. Usually it means that you defined the same symbol twice in the one namespace. The last time I got this error was because I accidentally included a .m file instead of .h header file.
Have you checked the Build Architecture?
Try setting Build Active Architecture Only to Yes.
I was facing the same issue Today! -ObjC linker flag - When trying to add it to "Other Linker Flags" I get an error
I solved my problem, Here is what I'd suggest. Take your original project (without Gmaps and with SUP) and add the -ObjC flag to it. Are you still getting an error? If so, take Gmaps out of the equation. If you are still getting an error check in the warnings about which files it is warning you about. My problem was that I had two files libGoogleAnalytics.a and libGoogleAnalytics_debug.a and for some reason they could not coexist with the -ObjC.
Long story short, you need to find what libraries Gmaps is using that you already have in your project and remove one of them.
Please try this…
step 1: Add '-ObjC' to other linker flags in 'Build Settings' of your 'target' only not to the 'project'

Resources