Skip to content
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

Not able to compile the iOS Build #921

Open
disolaterX opened this issue Mar 17, 2024 · 7 comments
Open

Not able to compile the iOS Build #921

disolaterX opened this issue Mar 17, 2024 · 7 comments

Comments

@disolaterX
Copy link

Podfile:

source "https://gitlab.linphone.org/BC/public/podspec.git"
pod 'linphone-sdk' , '~>5.3.4'

But I am getting

❌ (ios/Pods/RCT-Folly/folly/portability/Time.h:22:10)

20 | #include <time.h>
21 |

22 | #include <folly/portability/Config.h>
| ^ 'folly/portability/Config.h' file not found
23 |
24 | // OSX is a pain. The XCode 8 SDK always declares clock_gettime
25 | // even if the target OS version doesn't support it, so you get

❌ (ios/Pods/linphone-sdk/linphone-sdk/apple-darwin/share/linphonesw/LinphoneWrapper.swift:21:8)

19 | */
20 | import Foundation

21 | import linphone
| ^ could not build Objective-C module 'linphone'
22 | #if canImport(SwiftUI)
23 | import SwiftUI
24 | #endif

@mingeee
Copy link

mingeee commented Mar 28, 2024

@disolaterX I am getting the same issue. Did you end up finding a solution? 😭
Do you mind sharing the solution if you have one?

@disolaterX
Copy link
Author

@disolaterX I am getting the same issue. Did you end up finding a solution? 😭

Do you mind sharing the solution if you have one?

no luck till now

@lchenfox
Copy link

The same issue.

@lchenfox
Copy link

lchenfox commented Apr 7, 2024

As a workaround:

    1. ios/Pods/RCT-Folly/folly/portability/Time.h

Change

#include <folly/portability/Config.h>

into

#import "Config.h"
    1. Pods/RCT-Folly/folly/portability/Config.h

Comment out or remove the following line

#ifndef FOLLY_NO_CONFIG
//#include <folly/folly-config.h> // **Comment out** or **remove** this line.
#endif

Then clean Xcode and build again. It should work well.

@disolaterX
Copy link
Author

image

What you did for this ?

@lchenfox
Copy link

lchenfox commented Apr 7, 2024

image

What you did for this ?

Firstly, make sure that you have already added PushKit framework to Link Binary with Libraries in Build Phases. Then, you have to import CallKit framework before importing linphone and import your project swift bridging header file. It looks like in AppDelegate.m

#import <CallKit/CallKit.h>
#import "YOUR-PROJECT-NAME-Swift.h"
#import <PushKit/PushKit.h> 
#import <linphone/linphonecore.h>

@mingeee
Copy link

mingeee commented Apr 15, 2024

As a workaround:

    1. ios/Pods/RCT-Folly/folly/portability/Time.h

Change

#include <folly/portability/Config.h>

into

#import "Config.h"
    1. Pods/RCT-Folly/folly/portability/Config.h

Comment out or remove the following line

#ifndef FOLLY_NO_CONFIG
//#include <folly/folly-config.h> // **Comment out** or **remove** this line.
#endif

Then clean Xcode and build again. It should work well.

You are the man! Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants