Library not found for -lCommLibiOS Error.

Hi,
I am trying to implement iOS SDK into the Swift project and I am getting an error library not found for -lCommLibiOS
I am using Pods and I tried both implementing SDK manually (which gives me the same error as pointed out here , when I utilize the provided solution I get: library not found for -lCommLibiOS ) and through Pods(gives me library not found for -lCommLibiOS straight away ).
What I tried so far :
*After experimenting for couple of hours, I found out that if I remove -ObjC and $(inherited) from Other Linker Flags in Build Settings and add CommLibiOS.a and backendless.a manually. Everything starts to work - (I suspect it might be caused by the Bridging header inside Backendless SDK Backendless-Bridging-Header.h, cause I already use one for my other files.) Unfortunately this also kills all my Pods like FacebookSDK etc… , so this is not a solution.
*Created a “test” Objective C project, same exact thing happening, the workaround above works too.
*Tried using both a normal and light SDK, when using normal I also get errors described here. (I am not going to use any streaming services, so light works fine for me)

  • Tried adding Library Search Path to CommLibiOS.a folder, same error.
    *Tried building for both a simulator and a real device, same error.
    Thanks a lot for reading through my problem and I do really want to get it resolved, as I am trying to move away from greedy Parse.

Hi Nick,

To fix this problem for swift project:

  1. If you use the Backendless-Bridging-Header.h - you have to change the
    “Objective-C Bridging Header” build setting to “${PODS_ROOT}/Headers/Public/Backendless-ios-SDK/Backendless-Bridging-Header.h”
  2. If you use your own bridging header file you can simply add the line
    #import “Backendless.h”
    If you need MediaService you also should add the line

#import “MediaService.h”

It didn’t work, gives me the same error. However, I found the solution for this one:

  1. Added SDK manually
  2. Linked Frameworks and Libraries manually
  3. Added 3 flags to Other Linker Flags: “-lsqlite3, -framework, SystemConfiguration”

Not sure what’s the reason, but it did work. Also saving and retrieving data works fine, which means that SDK is functional. Thanks for the reply!

Its such a big mess this SDK, I think is really time to properly rewrite it, and not use these bad practice

Tomas, the SDK is open source. Why don’t you fork it, rewrite and show how it should be done? I’ll be glad to put alternative implementations right next to ours on the website.

Cheers,
Mark

Thanks, thats very good idea…just time what i spent by including it and fixing facebook sdk and still its useless.

Let me know when you have something to show… I’ll be happy to try it out.

Is there a fix for this issue not using Swift?

Simon,

If you use the latest pod, you should not have any issues.

Regards,
Mark

I am currently using:

s.dependency ‘Backendless-ios-SDK’, ‘~>3.0.21’

I have also tried just adding

s.dependency ‘Backendless-ios-SDK’

to get the most up to date version but the problems are still occurring.

Use the pod called ‘Backendless’. We published it last Friday. It does not include media API and thus simplifies a lot of things.

Mark

That did the trick, thanks for your help.