Google-signin: 'RNGoogleSignin/RNGoogleSignin.h' file not found and Argument list too long

Created on 19 Jun 2018  Â·  8Comments  Â·  Source: react-native-google-signin/google-signin

Hello
I just created a new project from scratch with firebase.
I followed steps to install react-native-google-sigin (v12) for Android and it worked fine.
Then I have tried for iOS and I have spent days doing installations steps, both manual , automated with Pod,.. and I always get same 2 issues we can find on other Issues
1rst:/
Argument list too long: recursive header expansion failed at /Users/.../node_modules/react-native-google-signin/ios/../../../ios/build/Index/DataStore/v5/records/0E.
2nd/
'RNGoogleSignin/RNGoogleSignin.h' file not found

I have tried all fixes suggested in other Issues without luck (copied GoogleSDK from node_modules into ios folder, rebuild from scratch, reinstall,...)
Any help would be greatly appreciated.

Environment

  • react-native 0.55.4
  • react-native-google-signin 0.12.0
  • react 16.3.1

Steps to Reproduce

Create newt project with firebase, follow iOS installation steps

Expected Behavior

Be able to log in using Google

Actual Behavior

See previous error messages

🔦 Help Wanted 💥 Build Issue  iOS

Most helpful comment

I was also having an issue with RNGoogleSignin.h not being found. Had to do the manual linking of libraries and call the import as such <GoogleSignIn/GoogleSignIn.h>

All 8 comments

Try installing the version we have on master.

Install from master

yarn add https://github.com/react-native-community/react-native-google-signin.git

react-native link react-native-google-signin

Go into ios folder and run pod install.

cd ios && pod install

if you don't have a Podfile check this out

then
react-native run-ios

This worked for me on a fresh react-native init project.

If you run into trouble comment here but first check out our example app and try to compare the configuration and see what is different.

Thank you for your quick feedback.
I followed all your steps one by one, I have such repo in my package.json now, done the pod install and run react-native run-ios.
Unfortunately , I am still having:

/Users/....../node_modules/react-native-google-signin/ios/RNGoogleSignin/RNGoogleSignInButton.h:1:9: fatal error: 'GoogleSignIn/GoogleSignIn.h' file not found #import

I was thinking it looks for GoogleSignIn.h which does not exist indeed as it is RNGoogleSignIn.h instead within such node-modules folder.
so I start renaming it with RN (updating to #import )and this solved it but I got some other errors happening from these same files too so not sure if this is really the issue here..

Thank you
Fabrice

The steps I took
1) yarn add react-native-google-signin
2) react-native link react-native-google-signin
3) cd ios
4) pod init
5) add GoogleSignIn pod
6) pod install
7) Add GoogleService-info.plist to project folder in xcode.
8) Add url types in Info in xcode. (bundle id and reverse client id).
Attention skip the project set up here, this unnecessary

I just tested IOS on the latest version in npm v0.12.0
here is the repo https://github.com/AndreiCalazans/googleAuthTest

E: Corrected the library name

Since I tested I will close this issue since it's not an issue with the lib but with the steps you are taking to install it.

I will fix this guide
https://github.com/react-native-community/react-native-google-signin/blob/master/ios-guide.md

@AndreiCalazans why you use react-native-google-auth , the module called react-native-google-signin

The steps I took
yarn add react-native-google-auth
react-native link react-native-google-auth

I was also having an issue with RNGoogleSignin.h not being found. Had to do the manual linking of libraries and call the import as such <GoogleSignIn/GoogleSignIn.h>

Using '#import ' solved my problem.

Also, conversely to the installation guide, you may need to add libraries manually even if you used 'react-native link'. Check if those are added to the project.

Please check if you are using Xcode 10. In case of Xcode 10 please enable

File -> Workspace/project Settings -> Build System

as legacy system for per-user workspace settings. This should possibly go into documentation. I spent an entire day repeating the steps over and over again.

Was this page helpful?
0 / 5 - 0 ratings