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

Plugins should not require removing use_frameworks! from Podfile #9694

Closed
collinjackson opened this Issue May 1, 2017 · 9 comments

Comments

Projects
None yet
6 participants
@collinjackson
Contributor

collinjackson commented May 1, 2017

Right now the Google Sign In example app has removed use_frameworks! from its Podfile.

If this line is added back, the pod install step fails with the following error.

[!] The 'Pods-Runner' target has transitive dependencies that include static binaries: (/Users/jackson/git/gsi42/example/ios/Pods/Google/Frameworks/GGLCore.framework and /Users/jackson/git/gsi42/example/ios/Pods/Google/Frameworks/GGLSignIn.framework)

See firebase/FirebaseUI-iOS#34 for an example of other devs struggling with this issue.

A related issue is that the FlutterFire plugins are also written assuming use_frameworks! is not in the Podfile. For example, the Firebase Analytics example app fails when use_frameworks! is added back to its Podfile.

    <module-includes>:1:1: warning: umbrella header for module 'Flutter' does not include header 'FlutterAsyncMessageListener.h' [-Wincomplete-umbrella]
    #import "Headers/Flutter.h"
    ^
    <module-includes>:1:1: warning: umbrella header for module 'Flutter' does not include header 'FlutterJSONMessageListener.h' [-Wincomplete-umbrella]
    <module-includes>:1:1: warning: umbrella header for module 'Flutter' does not include header 'FlutterMessageListener.h' [-Wincomplete-umbrella]
    3 warnings generated.
    In file included from /Users/jackson/git/firebase_analytics/ios/Classes/FirebaseAnalyticsPlugin.m:7:
    /Users/jackson/git/firebase_analytics/example/ios/Pods/Headers/Private/Firebase/Firebase.h:1:9: fatal error: 'FirebaseAnalytics/FirebaseAnalytics.h' file not found
    #import <FirebaseAnalytics/FirebaseAnalytics.h>
            ^
    3 warnings and 1 error generated.

We should try to make our plugin system compatible with use_frameworks!, or if that's not possible for Google Sign In, at least make the Firebase plugins able to build with use_frameworks!.

/cc @mravn-google @jakobr-google @szakarias @mit-mit

@collinjackson collinjackson added the plugin label May 1, 2017

@mit-mit mit-mit added the p: tooling label May 2, 2017

@eseidelGoogle eseidelGoogle added this to the 3: Make conferences happy milestone May 3, 2017

@collinjackson

This comment has been minimized.

Contributor

collinjackson commented May 8, 2017

We have a workaround (commenting out use_frameworks!), though it's not pretty, so I’m probably going to focus on other more pressing issues for the next few weeks. This issue is available if anyone else wants to investigate; it's possible that the answer is "just move to Carthage" in which case we can punt it.

@eseidelGoogle

This comment has been minimized.

Contributor

eseidelGoogle commented May 12, 2017

If we're going to move to Carthage we'll want to do that sooner rather than later. :)

@collinjackson

This comment has been minimized.

Contributor

collinjackson commented May 12, 2017

Carthage isn't officially supported by Firebase or Google Sign-In SDKs yet, so I think we might be stuck with Cocoapods until that changes. It is supported by Facebook, though.

@jakobr-google

This comment has been minimized.

Contributor

jakobr-google commented May 15, 2017

Plus, Carthage doesn't automatically add(/remove) the dependent frameworks to your app project, which is basically the only thing we're using CocoaPods for (well, that, and letting plugins transitively depend on other frameworks).

Switching to Carthage means having to develop our own code for managing the Xcode projects, so it's not happening right now.

@collinjackson

This comment has been minimized.

Contributor

collinjackson commented May 15, 2017

We talked about this in our meeting this morning and it sounds like we want use_frameworks! to be commented out by default in the new project template. This is more work for Swift developers but makes life easier for everyone else.

@mit-mit

This comment has been minimized.

Member

mit-mit commented May 23, 2017

@collinjackson @LarkAscending can we go ahead and remove this from the Firebase codelab then?

@LarkAscending

This comment has been minimized.

LarkAscending commented May 23, 2017

YES we can do that! Excellent news....and it's a low-impact change to the codelab.
Removing and republishing now.

@LarkAscending

This comment has been minimized.

LarkAscending commented May 23, 2017

Removed from step 6, Configure Google Sign-In on iOS section:
https://codelabs.developers.google.com/codelabs/flutter-firebase/#5

@ch-muhammad-adil

This comment has been minimized.

ch-muhammad-adil commented Apr 12, 2018

In your podfile where You see

target 'Runner' do
  use_frameworks!  

comment user_frameworks!

target 'Runner' do
  # use_frameworks!  

and go to path /ios of the project

run

pod install

and cheers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment