Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

"No such module 'Firebase'" when add Firebase into a library

I just created new Framework and added Firebase via CocoaPods, when combine the library it success.

But when I add that library to other project via CocoaPods as well, then combine that project, and it raise an error: No such module 'Firebase'

Anyone faced a problem like this?

like image 910
Tai Le Avatar asked Jun 16 '16 05:06

Tai Le


4 Answers

tried all these.. I was stuck in this situation for more than 2weeks.

finally resolved by adding "excluded architectures = arm64"

enter image description here

like image 186
Energy Avatar answered Nov 11 '22 02:11

Energy


You need to add the follwing to your POD file:

pod 'Firebase'

After that, you need to type in your terminal

pod install (to refresh the pod file)

like image 16
Christian Mora Avatar answered Nov 11 '22 00:11

Christian Mora


I solve my problem using just the specific import that I'm using, for example. In my SDK I'm using FirebaseCore and FirebaseAnalytics. Into my class I just import:

import FirebaseCore
import FirebaseAnalytics

And in my .podspec I needed to set static_framework property to true, so my .podspec it's seems like code below:

s.static_framework = true

s.dependency 'Firebase'
s.dependency 'Firebase/Core'

It works for me!

like image 8
Bruno Ramos Avatar answered Nov 11 '22 00:11

Bruno Ramos


Do you open the workspace file after installed with cocoa pods ?

Check if the library is added in "Linked Frameworks" or "Embedded Binaries"

enter image description here

If it didn't work, add this pod file

platform :ios, '8.0' use_frameworks! target ‘Your Project’ do


pod 'Firebase', '>= 2.5.1'
pod ‘Firebase/Auth’
pod ‘Google/SignIn’
pod ‘Firebase/Database’
pod 'Firebase/Storage' end

and then type pod deintegrate and after that run pod install.

like image 7
Bram'in Avatar answered Nov 11 '22 02:11

Bram'in