如何修复不为 iOS 构建的 React Native App [英] How to fix React Native App not building for iOS

查看:26
本文介绍了如何修复不为 iOS 构建的 React Native App的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在为 iOS 构建 React Native 应用程序时遇到问题.对于 android,它构建得非常好.对于 iOS,项目将构建但不存档.这是尝试存档我的项目时的错误代码:

I'm having trouble building my react native app for iOS. For android it builds perfectly fine. For iOS, the project will build but not archive. Here is the error code when attempting to archive my project:

1) Target 'React-Core.common-AccessibilityResources' has create directory command with output '/Users/jacobcarpenter/Library/Developer/Xcode/DerivedData/LFGOPocker-gaqwcsmtamkdjtbdiwhnzcvmexjk/Build/Intermediates.noindex/ArchiveIntermediates/LFGOPocker/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/AccessibilityResources.bundle'
2) Target 'React-Core.common-CoreModulesHeaders-AccessibilityResources' has create directory command with output '/Users/jacobcarpenter/Library/Developer/Xcode/DerivedData/LFGOPocker-gaqwcsmtamkdjtbdiwhnzcvmexjk/Build/Intermediates.noindex/ArchiveIntermediates/LFGOPocker/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/AccessibilityResources.bundle'

要说明的几点:运行 React-native 0.63,Podfile 和部署目标都在 11 上

Few things to state: Running React-native 0.63, Podfile and deployment targets are all on 11

从命令行运行时我收到此错误

when running from the command line I receive this error

      '/Users/jacobcarpenter/Library/Developer/Xcode/DerivedData/LFGOPocker-bzowsupbiktzuzaaadvokqxbgvzq/Build/Intermediates.noindex/ArchiveIntermediates/LFGOPocker/BuildProductsPath/Release-iphoneos/YogaKit/YogaKit.modulemap'
      not found```

推荐答案

我通过从我的 pod 目标中删除 'React-Core.common-AccessibilityResources' 修复了这个错误.尝试存档时,请确保您没有使用 .xcodeproj 并使用您的工作区.即使您认为您正在使用工作区三重检查.此外,如果您尝试通过命令行归档,则必须特别说明工作区.

I fixed this error by deleting 'React-Core.common-AccessibilityResources' from my pod targets. When attempting to archive, make sure you are not using .xcodeproj and using your workspace. Even if you think you are using workspace triple check. Also if you try archiving through the command line you must specifically state workspace.

这篇关于如何修复不为 iOS 构建的 React Native App的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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