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

The 'Pods-ProjectName' target has transitive dependencies that include static binaries #1923

Closed
rash6795 opened this issue Dec 27, 2017 · 19 comments
Labels
enhancement New feature or request

Comments

@rash6795
Copy link

Problem Description

Pod installation fails when tried to use along with other cocoapods which are already being used by the project . But works fine when no other pods are installed

Is this a bug report?

YES

Have you read the Installation Instructions?

YES

Environment

react-native: 0.50.3
react:  16.0.0-beta.5
react-native-maps: 0.19.0 
Target Platform: iOS - 8 and above 
ios Using GoogleMaps

Steps to Reproduce

  1. Follow the cocoapods installation for "react-native-maps"
  2. install additional pods like Firebase , Alamofire ,etc ... (or Any other pod )

Expected Behavior

All the Pods to be installed successfully !

Actual Behavior

Pod installation Failed with the following reason:

[!] The 'Pods-mapSample' target has transitive dependencies that include static binaries: (/Users/Username/Desktop/mapSample/ios/Pods/GoogleMaps/Base/Frameworks/GoogleMapsBase.framework, /Users/Username/Desktop/mapSample/ios/Pods/GoogleMaps/Maps/Frameworks/GoogleMaps.framework, and /Users/Username/Desktop/mapSample/ios/Pods/GoogleMaps/Maps/Frameworks/GoogleMapsCore.framework)

Screenshots

Terminal Screenshot

group 4

List of Pods in Project Screenshot

screen shot 2017-12-27 at 12 52 52 pm

Reproducible Demo

No

@rborn rborn added enhancement New feature or request Installation labels Dec 29, 2017
@Jono20201
Copy link

Experiencing the same issue.

@aeruhxi
Copy link

aeruhxi commented Jan 4, 2018

Getting the same issue here, too. This should be a bug not an enhancement.

@Josh2941
Copy link

Josh2941 commented Jan 4, 2018

Here also the same problem. But works fine for Android. I too think its must be a bug.

@Yandamuri
Copy link

Here also the same problem.This should be a bug.

@alvelig
Copy link
Contributor

alvelig commented Jan 4, 2018

Guys, anybody who is experiencing that, please make a reproducible demo. Otherwise this does not move anywhere, remember, we are community, are we?

P.S. This is not a bug, because pod dependencies should be resolved by developer.

@rash6795
Copy link
Author

rash6795 commented Jan 5, 2018

The Reproducible demo is available in the following link

https://drive.google.com/open?id=1Rrr-6Muru6TA3J33288pWz0Bk8cdNUWd

Issues Faced

This is the Podfile when modifying according to react-native-maps documentation

pod1

Terminal output after hitting 'pod install' and project works fine

before

The Podfile after adding other Pod files

pod 2

Terminal output after hitting 'pod install' and there comes the error

after

@rborn
Copy link
Collaborator

rborn commented Jan 8, 2018

Everyone, could you please try the workaround found here (the pre_install script):

CocoaPods/CocoaPods#6993 or the updated one linked in the comment?

Let us know. Thanks.

@phhuan
Copy link

phhuan commented Mar 16, 2018

It fixed my problem.
Please try: CocoaPods/CocoaPods#3289 (comment), the pre_install command post-cocapods 1.3.x should be:

pre_install do |installer|
# workaround for CocoaPods/CocoaPods#3289
Pod::Installer::Xcode::TargetValidator.send(:define_method, :verify_no_static_framework_transitive_dependencies) {}
end

@rborn
Copy link
Collaborator

rborn commented Jun 19, 2019

Very old issue, closing. Please re-open if you still have it.

@dunklesToast
Copy link

I am still encountering this problem. The workaround seems to fix it.

@hoonblizz
Copy link

hoonblizz commented Oct 15, 2019

I had the same issue. Adding

pre_install do |installer|
Pod::Installer::Xcode::TargetValidator.send(:define_method, :verify_no_static_framework_transitive_dependencies) {}
end

after target fixes the issue.

@GarliqBread
Copy link

Thanks @hoonblizz works like a charm

@yuoppp
Copy link

yuoppp commented Jan 6, 2020

(Sponge Bob Voice) 2 years later....

Still facing the issue

@RashVenkat6795
Copy link

@yuoppp try hoonblizz way it works

@CyrusZei
Copy link

check so that you don't have the use_frameworks! in your podfile. Removed that and it worked

@dawidvdh
Copy link

dawidvdh commented Jul 22, 2020

Placing the following in my Podfile worked for various libraries that I had this same issue with while still using use_frameworks!:

pre_install do |installer|
  installer.pod_targets.each do |pod|
    if pod.name.eql?('NAME_OF_POD') || pod.name.start_with?('START_OF_NAME_OF_POD')
      def pod.build_type;
        # Uncomment one line depending on your CocoaPods version
        Pod::BuildType.static_library # >= 1.9
        # Pod::Target::BuildType.static_library # < 1.9
      end
    end
  end
end

replacing NAME_OF_POD and START_OF_NAME_OF_POD with what you require of course.

@sirmong
Copy link

sirmong commented Jul 24, 2020

Thanx, @hoonblizz , you helped so much! 👍

@imondal007
Copy link

Still facing same issue

@bobowinca
Copy link

@dawidvdh, your solution worked great! Thanks.

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

No branches or pull requests