2

Referring this issue, I've the same problem. I've MacOs El Captain on VMware.

  • Node v. 7.8.0
  • npm v.4.6.1
  • react-native-cli 2.0.1
  • react-native 0.46.4
  • Xcode v. 8.2.1

I've two issues: - when trying to init a new react-native project, the packages fetching hangs on getting react-native 0.46.4 package from repo. Other packages were downloaded successfully. So I've execute npm install from Windows and then copied the node_modules folder on Mac. - when trying to run the project on iOS simulator I recieve the following error:

** BUILD FAILED **

...
In file included from /Users/michelebombardi/Desktop/ReactNativeProjects/caliup/node_modules/react-native/React/../third-party/folly-2016.09.26.00/folly/Bits.h:70:
/Users/michelebombardi/Desktop/ReactNativeProjects/caliup/node_modules/react-native/React/../third-party/folly-2016.09.26.00/folly/detail/BitIteratorDetail.h:21:10: fatal error: 'boost/iterator/iterator_adaptor.hpp' file not found
#include <boost/iterator/iterator_adaptor.hpp>

The following build commands failed:

CompileC /Users/michelebombardi/Desktop/ReactNativeProjects/caliup/ios/build/Build/Intermediates/React.build/Debug-iphonesimulator/third-party.build/Objects-normal/x86_64/Conv.o /Users/michelebombardi/Desktop/ReactNativeProjects/caliup/node_modules/react-native/third-party/folly-2016.09.26.00/folly/Conv.cpp normal x86_64 c++ com.apple.compilers.llvm.clang.1_0.compiler
(1 failure)

Installing build/Build/Products/Debug-iphonesimulator/CaliUp.app
An error was encountered processing the command (domain=NSPOSIXErrorDomain, code=2):
Failed to install the requested application
An application bundle was not found at the provided path.
Provide a valid path to the desired application bundle.
Print: Entry, ":CFBundleIdentifier", Does Not Exist

Command failed: /usr/libexec/PlistBuddy -c Print:CFBundleIdentifier build/Build/Products/Debug-iphonesimulator/CaliUp.app/Info.plist
Print: Entry, ":CFBundleIdentifier", Does Not Exist`

I really need to publish my app on the app store before the end of the week. I've already try all suggested solutions but nothin works.

Could anyone help me?

3 Answers 3

2

First try this: watchman watch-del-all && rm -rf node_modules

If you install node using Homebrew uninstall it and install node from here.(https://nodejs.org/en/)

Now if you used yarn to install node modules: Try npm install

Sign up to request clarification or add additional context in comments.

Comments

1

This error is caused by a failed third party library download in the build step. In your home folder there should be a ~/.rncache directory with a number of compressed C++ libraries. The error occurs when one or more of these files fails to download completely from the github amazon s3 servers. (likely in China)

The problem sticks around because the script in the react-native xcode build doesn't know how to resume the broken download. So you can fix this by deleting your ~/.rncache folder and because these folders are extracted into your modules you should also rm -rf node_modules and reinstall.

More info can be found here and here

Comments

0

May be this will work. Try these steps:

  1. Backup your icons, images etc from ios folder.

  2. Check that app name is set for key "name" in {project-root}\app.json file.

  3. Delete ios/ and android/ directories

  4. Run react-native eject

  5. Replace the icons,images etc you copied earlier

  6. Run react-native link

  7. Launch you app from Xcode using short cut key command+r

2 Comments

Regenerating ios and android folders with react-native eject on my Mac solves the issue. Thank you very much!
@Androidian Yes, regeneration of ios and android folders is helps because every few releases of react-native has some internal project settings related changes. That's why the command watch-del-all is not useful in such cases.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.