无法打开文件(在项目"Pods"中的目标"React"中)(在目标"React"中) [英] unable to open file (in target "React" in project "Pods") (in target 'React')

查看:173
本文介绍了无法打开文件(在项目"Pods"中的目标"React"中)(在目标"React"中)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个reactNative项目,我试图在最新的xcode 10.1中运行,但是在我构建时它抛出了两个错误.

I have one reactNative project and i am trying to run in latest xcode 10.1.But its throwing two error while i building.

错误:

Users/ios/Pods/Target Support Files/React/React.xcconfig: unable to open file (in target "React" in project "Pods") (in target 'React')

Users/ios/Pods/Target Support Files/React/React.xcconfig: unable to open file (in target "React" in project "Pods") (in target 'React')

我的pod文件如下:

 source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '9.0'

EXPO_CPP_HEADER_DIR = 'ExpoKit'

target 'commonalityre' do
  pod 'ExpoKit',
    :git => "http://github.com/expo/expo.git",
    :tag => "ios/2.6.8",
    :subspecs => [
      "Core",
      "CPP",
      "GL"
    ],
    :inhibit_warnings => true

  pod 'React',
    :path => "../node_modules/react-native",
    :inhibit_warnings => true,
    :subspecs => [
      "Core",
      "ART",
      "RCTActionSheet",
      "RCTAnimation",
      "RCTCameraRoll",
      "RCTGeolocation",
      "RCTImage",
      "RCTNetwork",
      "RCTPushNotification",
      "RCTText",
      "RCTVibration",
      "RCTWebSocket",
      "DevSupport",
      "CxxBridge"
    ]
  pod 'yoga',
    :path => "../node_modules/react-native/ReactCommon/yoga",
    :inhibit_warnings => true

不确定如何解决此问题.我试着删除派生数据,并且干净无济于事.仍然我收到此错误.

Not sure how can i solve this. I tried deleting derived data, and clean, nothing help. Still i am getting this error.

谢谢

推荐答案

下面的方法应该起作用:

Following should work:

1.

rm -rf ~/Library/Developer/Xcode/DerivedData

2.

rm -rf node_modules && rm -rf ios/build/* && rm -rf android/build/* && rm -rf $TMPDIR/react-* && yarn cache clean && rm -rf /tmp/haste-map-react-native-packager-* && yarn

这篇关于无法打开文件(在项目"Pods"中的目标"React"中)(在目标"React"中)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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