1
votes

None of my 'Firebase' pods are found.

I updated to Xcode 9. Ran 'pod update'

deitegrated my pods, and re-installed

Deleted 'Derived Data' folder contents

Build from 'Generic Devices'

Added the paths in the Header Search Path in the Build Settings $(inherited) and "$(SRCROOT)/Pods" and "${PODS_ROOT}/Firebase/Core/Sources"

Cleaned, build, closed the app, re-installed Xcode, restarted the system, and did it all again.

2 Swift Compiler Errors are always there.

'FirebaseAnalytics/FirebaseAnalytics.h' file not found and Could not build Objective-C module 'Firebase'

I'm on Sierra 10.12.6

None of these has worked so far to get rid of them. Does anyone know of any other possible solutions?

Here is the pod file info.

Uncomment the next line to define a global platform for your project

platform :ios, '10.0'

target 'MP' do # Comment the next line if you're not using Swift and don't want to use dynamic frameworks

use_frameworks!

# Pods for MP

pod 'Firebase'
pod 'Firebase/Analytics'
pod 'Firebase/Core'
pod 'Firebase/Database'
pod 'Firebase/Auth'
pod 'Firebase/Storage'

end

------ UPDATE ------

as Hexfire suggested below. I removed pods and manually added the frameworks.

After some fiddling with the pathing for my MP.h file, that first error is gone, however now I am getting these compiler errors now...

:0: error: PCH file '/Users/.../Library/Developer/Xcode/DerivedData/MP-gwnwsbrisiyspxepcxkbrojwtfrs/Build/Intermediates.noindex/PrecompiledHeaders/MP-swift_ZJX6RAPYV1IT-clang_2SW1CJQDTFSBO.pch' not found: module file not found

clang importer creation failed

I built a .pch file 'MP.pch' and I pointed to it in the Build Settings Prefix Header with $(SRCROOT) with no luck. Do I have to put all of my Framework paths in there as well?

All of this seems related to the search paths. Does anyone have any other thoughts here? Perhaps an example of the build settings syntax? For example $(SRCROOT) with quotes or without? $(SRCROOT)/MP.pch or just $(SRCROOT)?

2
Can I see your pod file ?iOS Geek
I put the pod file info into the original question text block.dqmoto
i think add `firebase' as custom and use objective c bridgingMidhun K Mohan
You shouldn't need to change the search paths at all for Firebase. Are you able to build the Firebase quickstarts? github.com/firebase/quickstart-iosPaul Beusterien
Sorry, to clarify. "I shouldn't need to change the search paths"...does that mean that there should be nothing in the Framework search paths? Or should there have been something there initially? I have been all over this thing, and I honestly have no idea what if anything should be in there as I see conflicting info out there. And, the same question is for the Header Search Paths. Cheers. I'll give the quick start a go shortly. Thanks again.dqmoto

2 Answers

0
votes

One of the good ways to make this work is by not using CocoaPods. You can grab all necessary Firebase libraries from here and use within your app (if link doesn't work, go here, and scroll down to "Integrate without CocoaPods").

After downloading:

  1. Unzip and see the README file for which Frameworks to include in to your project.
  2. Add the ObjC linker flag in your Other Linker Settings in your target's build settings.

This is a valid option and 100% workable.

P.S. If Firebase is the only pod you are using, you can quickly and safely clean your project from any CocoaPods trails by using pod deintegrate command.

Good luck!

0
votes

If All Of this do not work Try this for once

run sudo gem install cocoapods

You can check your version by typing pod --version anywhere on your terminal.

Make sure you are using latest Version of it