“:CFBundleIdentifier",不存在:Mac/iOS 上的 ReactNative 0.58 [英] ":CFBundleIdentifier", Does Not Exist: ReactNative 0.58 on Mac / iOS

查看:201
本文介绍了“:CFBundleIdentifier",不存在:Mac/iOS 上的 ReactNative 0.58的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在关注 0.58 的 ReactNative 教程.我做了它所说的一切,但在运行 react-native run-ios 后我崩溃了.我在 2016 年看到过这个非常相似的

解决方案

我尝试修改构建系统,它对我有用.

详情:

在 Xcode 中打开您的项目工作区文件,然后

文件 ->工作区设置 ->构建系统 ->旧版构建系统

I am following the ReactNative tutorial for 0.58. I do everything it says to do and I am crashing after running react-native run-ios. I have seen this extremely similar SO question from 2016.

  • I attempted react-native upgrade and it recommended doing react-native-git-upgrade.This did nothing. Same problem.
  • The bit on running ./configure in the question above after cd-ing into glog did nothing. There was no configure script there. In the path NewStupidProject/node_modules/react-native/scripts there is a script called ios-configure-glog.sh. I run bash ios-configure-glog.sh and it says ios-configure-glog.sh: line 31: ./configure: No such file or directory.
  • I have also attempted setting Xcode to use the legacy build system. This did not fix the issue. I am restarting my laptop now to see if that makes any of these changes take effect. No luck. At the top it says:

Found Xcode project NewStupidProject.xcodeproj Building using "xcodebuild -project NewStupidProject.xcodeproj -configuration Debug -scheme NewStupidProject -destination id=854019D1-8EE7-4D13-87E1-385E6CAC21BE -derivedDataPath build" User defaults from command line:

IDEDerivedDataPathOverride = /Users/me/NewStupidProject/ios/build

Prepare build

note: Using legacy build system === BUILD TARGET double-conversion OF PROJECT React WITH CONFIGURATION Debug ===

When I go into the home directory and run react-native --version the output is:

[NewStupidProject](master)$ react-native --version
react-native-cli: 2.0.1 
react-native: 0.58.4 
[NewStupidProject](master)$

My output after crashing is:

** BUILD FAILED **

The following build commands failed: PhaseScriptExecution Install\ Third\ Party /Users/me/native_react_apps/NewStupidProject/ios/build/Build/Intermediates.noindex/React.build/Debug-iphonesimulator/double-conversion.build/Script-190EE32F1E6A43DE00A8543A.sh (1 failure)

Installing build/Build/Products/Debug-iphonesimulator/NewStupidProject.app An error was encountered processing the command (domain=NSPOSIXErrorDomain, code=22): Failed to install the requested application The bundle identifier of the application could not be determined. Ensure that the application's Info.plist contains a value for CFBundleIdentifier. Print: Entry, ":CFBundleIdentifier", Does Not Exist

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

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

at checkExecSyncError (child_process.js:637:11)
at Object.execFileSync (child_process.js:655:13)
at Promise.then (/Users/me/native_react_apps/NewStupidProject/node_modules/react-native/local-cli/runIOS/runIOS.js:208:5)

How is it possible for the setup process to be this fraught with errors and this difficult?

WHY is this error message not in the Troubleshooting ReactNative setup?

HOW do I fix this? Is it possible to avoid this altogether in the future?

Other versioning info:

  • XCode: 10.1
  • Command Line Tools: 10.1
  • yarn: 0.27.5
  • watchman: 4.9.0
  • homebrew: 2.0.1
  • npm: 6.8.0
  • node: v11.9.0
  • macOS: 10.13.6

UPDATE: I am trying to implement the solution in this issue in GitHub and I'm getting:

dyld: Library not loaded: /usr/local/opt/readline/lib/libreadline.7.dylib Referenced from: /usr/local/bin/awk Reason: image not found ./ios-install-third-party.sh: line 20: 24497 Broken pipe: 13
shasum -p "$cachedir/$file" 24498 Abort trap: 6 | awk -v hash="$hash" '{exit $1 != hash}' Incorrect hash: 61067502c5f9769d111ea1ee3f74e6ddf0a5f9cc ?/Users/me/.rncache/glog-0.3.5.tar.gz

UPDATE No. 2 I am trying to run the watchman watch-del-all command as recommended here to clear the cache for RN > 0.50 and the whole thing is hanging.

解决方案

I tried modify the build system and it worked for me.

Detail:

Open your project workspace file in Xcode, and

File -> Workspace Settings -> Build system -> Legacy Build system

这篇关于“:CFBundleIdentifier",不存在:Mac/iOS 上的 ReactNative 0.58的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆