React-native: spec.prepare_command error in third-party-podspecs for GLog and DoubleConversion

Created on 19 Oct 2017  Â·  9Comments  Â·  Source: facebook/react-native

Is this a bug report?

Yes

when i Adding React Native to an Existing Application According to the document execution "pod install ".
I get the error :
``` Installing DoubleConversion (1.1.5)
[!] /bin/bash -c
set -e
mv src double-conversion

mv: rename src to double-conversion: No such file or directory

At last I found the pod specs of GLog and DoubleConversion have a prepare_command lead to the error.

### Have you read the [Contributing Guidelines](https://facebook.github.io/react-native/docs/contributing.html)?

Yes

### Environment

  Environment:
    OS:  macOS High Sierra 10.13
    Node:  8.7.0
    Yarn:  0.27.5
    npm:  5.4.2
    Xcode:  9.0 (9A235)

  Packages: (wanted => installed)
    react-native: 0.49.0 
    react: 16.0.0

  Target Platform: iOS (10.3)

### Steps to Reproduce

(Write your steps here:)

1. In accordance with the Adding React Native to an Existing Application Document for iOS Swift
2. add the pod file
3. pod install

poffile 

Reactive Native

pod 'React', :path => './ReactComponent/node_modules/react-native', :subspecs => [
    'Core',
    'CxxBridge', # Include this for RN >= 0.47
    'DevSupport', # Include this to enable In-App Devmenu if RN >= 0.43
    'RCTText',
    'RCTNetwork',
    'RCTWebSocket', # needed for debugging

Add any other subspecs you want to use in your project

]

Explicitly include Yoga if you are using RN >= 0.42.0

pod 'yoga', :path => '../node_modules/react-native/ReactCommon/yoga'
pod 'Folly', :path => '../node_modules/react-native/third-party-podspecs'
pod 'DoubleConversion', :path => '../node_modules/react-native/third-party-podspecs'
pod 'GLog', :path => '../node_modules/react-native/third-party-podspecs'

```

Locked

Most helpful comment

@FlyingNoob Did you means change pod 'DoubleConversion', :path => './React/node_modules/react-native/third-party-podspecs' to pod 'DoubleConversion', :path => './React/node_modules/react-native/third-party-podspecs/DoubleConversion.podspec' . But it don't work for me

All 9 comments

So am I,and there are solutions?

@xiaozi4624 Yes , I found the podspecs path is wrong. We should use the absolute path. For example '../node_modules/react-native/third-party-podspecs/GLog.podspecs'. Not like the document for 'yoga'.

@FlyingNoob Did you means change pod 'DoubleConversion', :path => './React/node_modules/react-native/third-party-podspecs' to pod 'DoubleConversion', :path => './React/node_modules/react-native/third-party-podspecs/DoubleConversion.podspec' . But it don't work for me

@skhan02 thanks, it works for me

@xiaozi4624 All the third pod path must be absolute path. Not only DoubleConversion

Hi
I am facing the same issue. I have tried everything and wasted last 3 days
Please help me!!!!

Also getting this bug as I try to make React Native work. :/ any solutions

I was having this issue, but changed my Podfile to look exactly like this and it worked:

(You'll need to tweak what nm_path is based on your project)

nm_path = './rn/Teacher/node_modules/'
rn_path = nm_path + 'react-native/'
pod 'Folly', :podspec => rn_path + '/third-party-podspecs/Folly.podspec'
pod 'DoubleConversion', :podspec => rn_path + '/third-party-podspecs/DoubleConversion.podspec'
pod 'glog', :podspec => rn_path + '/third-party-podspecs/glog.podspec'
Was this page helpful?
0 / 5 - 0 ratings

Related issues

jlongster picture jlongster  Â·  3Comments

grabbou picture grabbou  Â·  3Comments

aniss picture aniss  Â·  3Comments

upbit picture upbit  Â·  3Comments

despairblue picture despairblue  Â·  3Comments