构建 iOS 项目失败。我们运行了“xcodebuild”命令,但它退出并显示错误代码 65

2024-06-25

我是反应原生开发的新手。我正在使用配备 M1 芯片的新款 MacBook Air(M1,2020)。我已经安装了以下依赖项:

Node =  v14.15.3
Npm  = 6.14.9
Homebrew  = 2.7.0
react-native-cli: 2.0.1
Xcode Version 12.3

项目创建日志如下:

alimran@Als-MacBook-Air prod % react-native init test
This will walk you through creating a new React Native project in /Users/alimran/workspace/reactnative/prod/test
Installing react-native...
Consider installing yarn to make this faster: https://yarnpkg.com
npm WARN deprecated @hapi/[email protected] /cdn-cgi/l/email-protection: Switch to 'npm install joi'
npm WARN deprecated @hapi/[email protected] /cdn-cgi/l/email-protection: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated @hapi/[email protected] /cdn-cgi/l/email-protection: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated @hapi/[email protected] /cdn-cgi/l/email-protection: Moved to 'npm install @sideway/address'
npm WARN deprecated @hapi/[email protected] /cdn-cgi/l/email-protection: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated [email protected] /cdn-cgi/l/email-protection: core-js@<3 is no longer maintained and not recommended for usage due to the number of issues. Please, upgrade your dependencies to the actual version of core-js@3.
npm WARN deprecated [email protected] /cdn-cgi/l/email-protection: fsevents 1 will break on node v14+ and could be using insecure binaries. Upgrade to fsevents 2.
npm WARN deprecated [email protected] /cdn-cgi/l/email-protection: Please see https://github.com/lydell/urix#deprecated
npm WARN deprecated [email protected] /cdn-cgi/l/email-protection: https://github.com/lydell/resolve-url#deprecated

> [email protected] /cdn-cgi/l/email-protection install /Users/alimran/workspace/reactnative/prod/test/node_modules/fsevents
> node install.js

  SOLINK_MODULE(target) Release/.node
  CXX(target) Release/obj.target/fse/fsevents.o
  SOLINK_MODULE(target) Release/fse.node

> [email protected] /cdn-cgi/l/email-protection postinstall /Users/alimran/workspace/reactnative/prod/test/node_modules/core-js
> node -e "try{require('./postinstall')}catch(e){}"

Thank you for using core-js ( https://github.com/zloirock/core-js ) for polyfilling JavaScript standard library!

The project needs your help! Please consider supporting of core-js on Open Collective or Patreon: 
> https://opencollective.com/core-js 
> https://www.patreon.com/zloirock 

Also, the author of core-js ( https://github.com/zloirock ) is looking for a good job -)

npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN [email protected] /cdn-cgi/l/email-protection requires a peer of [email protected] /cdn-cgi/l/email-protection but none is installed. You must install peer dependencies yourself.
npm WARN [email protected] /cdn-cgi/l/email-protection requires a peer of react@^16.8.0 || ^17.0.0 but none is installed. You must install peer dependencies yourself.

+ [email protected] /cdn-cgi/l/email-protection
added 732 packages from 414 contributors and audited 732 packages in 39.586s

12 packages are looking for funding
  run `npm fund` for details

found 3 low severity vulnerabilities
  run `npm audit fix` to fix them, or `npm audit` for details
info Setting up new React Native app in /Users/alimran/workspace/reactnative/prod/test
(node:14642) Warning: Accessing non-existent property 'padLevels' of module exports inside circular dependency
(Use `node --trace-warnings ...` to show where the warning was created)
info Adding required dependencies
+ [email protected] /cdn-cgi/l/email-protection
added 1 package and audited 735 packages in 3.979s

12 packages are looking for funding
  run `npm fund` for details

found 3 low severity vulnerabilities
  run `npm audit fix` to fix them, or `npm audit` for details
info Adding required dev dependencies
npm WARN deprecated [email protected] /cdn-cgi/l/email-protection: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN deprecated [email protected] /cdn-cgi/l/email-protection: request-promise-native has been deprecated because it extends the now deprecated request package, see https://github.com/request/request/issues/3142
npm WARN deprecated [email protected] /cdn-cgi/l/email-protection: this library is no longer supported

> [email protected] /cdn-cgi/l/email-protection postinstall /Users/alimran/workspace/reactnative/prod/test/node_modules/core-js-pure
> node -e "try{require('./postinstall')}catch(e){}"

npm WARN [email protected] /cdn-cgi/l/email-protection requires a peer of typescript@>=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta but none is installed. You must install peer dependencies yourself.

+ [email protected] /cdn-cgi/l/email-protection
+ @babel/[email protected] /cdn-cgi/l/email-protection
+ [email protected] /cdn-cgi/l/email-protection
+ @babel/[email protected] /cdn-cgi/l/email-protection
+ [email protected] /cdn-cgi/l/email-protection
+ [email protected] /cdn-cgi/l/email-protection
+ [email protected] /cdn-cgi/l/email-protection
+ @react-native-community/[email protected] /cdn-cgi/l/email-protection
added 582 packages from 308 contributors, updated 3 packages and audited 1317 packages in 24.86s

57 packages are looking for funding
  run `npm fund` for details

found 3 low severity vulnerabilities
  run `npm audit fix` to fix them, or `npm audit` for details
info Installing required CocoaPods dependencies
(node:14642) UnhandledPromiseRejectionWarning: Error: Failed to install CocoaPods dependencies for iOS project, which is required by this template.
Please try again manually: "cd ./test/ios && pod install".
CocoaPods documentation: https://cocoapods.org/
    at runPodInstall (/Users/alimran/workspace/reactnative/prod/test/node_modules/react-native/node_modules/@react-native-community/cli/build/tools/installPods.js:99:13)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)
    at async installPods (/Users/alimran/workspace/reactnative/prod/test/node_modules/react-native/node_modules/@react-native-community/cli/build/tools/installPods.js:222:5)
    at async generateProject (/Users/alimran/workspace/reactnative/prod/test/node_modules/react-native/node_modules/@react-native-community/cli/build/commands/init/initCompat.js:136:5)
    at async Object.initCompat (/Users/alimran/workspace/reactnative/prod/test/node_modules/react-native/node_modules/@react-native-community/cli/build/commands/init/initCompat.js:105:3)
(node:14642) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 2)
(node:14642) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
alimran@Als-MacBook-Air prod % 

手动 Pod 安装结果:

alimran@Als-MacBook-Air prod % cd test
alimran@Als-MacBook-Air test % ls
App.js          app.json        ios         package-lock.json
__tests__       babel.config.js     metro.config.js     package.json
android         index.js        node_modules
alimran@Als-MacBook-Air test % cd ios
alimran@Als-MacBook-Air ios % sudo pod install
Password:
Traceback (most recent call last):
    5: from /usr/local/bin/pod:23:in `<main>'
    4: from /usr/local/bin/pod:23:in `load'
    3: from /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.10.0/bin/pod:55:in `<top (required)>'
    2: from /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.10.0/lib/cocoapods/command.rb:48:in `run'
    1: from /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.10.0/lib/cocoapods/command.rb:102:in `ensure_not_root_or_allowed!'
/Library/Ruby/Gems/2.6.0/gems/claide-1.0.3/lib/claide/command.rb:439:in `help!': [!] You cannot run CocoaPods as root. (CLAide::Help)

Usage:

    $ pod COMMAND

      CocoaPods, the Cocoa library package manager.

Commands:

    + cache        Manipulate the CocoaPods cache
    + env          Display pod environment
    + init         Generate a Podfile for the current directory
    + install      Install project dependencies according to versions from a
                   Podfile.lock
    + ipc          Inter-process communication
    + lib          Develop pods
    + list         List pods
    + outdated     Show outdated project dependencies
    + repo         Manage spec-repositories
    + setup        Setup the CocoaPods environment
    + spec         Manage pod specs
    + update       Update outdated project dependencies and create new Podfile.lock

Options:

    --allow-root   Allows CocoaPods to run as root
    --silent       Show nothing
    --version      Show the version of the tool
    --verbose      Show more debugging information
    --no-ansi      Show output without ANSI codes
    --help         Show help banner of specified command
alimran@Als-MacBook-Air ios % 

项目运行报错如下:

alimran@Als-MacBook-Air test % react-native run-ios
error Could not find "Podfile.lock" at /Users/alimran/workspace/reactnative/prod/test/ios/Podfile.lock. Did you run "pod install" in iOS directory?
info Found Xcode project "test.xcodeproj"
info Building (using "xcodebuild -project test.xcodeproj -configuration Debug -scheme test -destination id=06B32499-BA8E-488E-B934-FDC4C7D2A385")
(node:16530) Warning: Accessing non-existent property 'padLevels' of module exports inside circular dependency
(Use `node --trace-warnings ...` to show where the warning was created)
error Failed to build iOS project. We ran "xcodebuild" command but it exited with error code 65. To debug build logs further, consider building your app with Xcode.app, by opening test.xcodeproj. Run CLI with --verbose flag for more details.
Command line invocation:
    /Applications/Xcode.app/Contents/Developer/usr/bin/xcodebuild -project test.xcodeproj -configuration Debug -scheme test -destination id=06B32499-BA8E-488E-B934-FDC4C7D2A385

note: Using new build system
note: Building targets in parallel
note: Planning build
note: Constructing build description
warning: Capabilities for Signing & Capabilities may not function correctly because its entitlements use a placeholder team ID. To resolve this, select a development team in the test editor. (in target 'test' from project 'test')
ProcessProductPackaging "" /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/test.app-Simulated.xcent (in target 'test' from project 'test')
    cd /Users/alimran/workspace/reactnative/prod/test/ios
    

Entitlements:

{
    "application-identifier" = "FAKETEAMID.org.reactjs.native.example.test";
    "keychain-access-groups" =     (
        "FAKETEAMID.org.reactjs.native.example.test"
    );
}


    builtin-productPackagingUtility -entitlements -format xml -o /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/test.app-Simulated.xcent

ProcessProductPackaging "" /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/test.app.xcent (in target 'test' from project 'test')
    cd /Users/alimran/workspace/reactnative/prod/test/ios
    

Entitlements:

{
    "com.apple.security.get-task-allow" = 1;
}


    builtin-productPackagingUtility -entitlements -format xml -o /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/test.app.xcent

PhaseScriptExecution Start\ Packager /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/Script-FD10A7F022414F080027D42C.sh (in target 'test' from project 'test')
    cd /Users/alimran/workspace/reactnative/prod/test/ios
    /bin/sh -c /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/Script-FD10A7F022414F080027D42C.sh

CompileC /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/Objects-normal/x86_64/main.o /Users/alimran/workspace/reactnative/prod/test/ios/test/main.m normal x86_64 objective-c com.apple.compilers.llvm.clang.1_0.compiler (in target 'test' from project 'test')
    cd /Users/alimran/workspace/reactnative/prod/test/ios
    export LANG\=en_US.US-ASCII
    /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -x objective-c -target x86_64-apple-ios10.0-simulator -fmessage-length\=0 -fdiagnostics-show-note-include-stack -fmacro-backtrace-limit\=0 -std\=gnu99 -fobjc-arc -fmodules -gmodules -fmodules-cache-path\=/Users/alimran/Library/Developer/Xcode/DerivedData/ModuleCache.noindex -fmodules-prune-interval\=86400 -fmodules-prune-after\=345600 -fbuild-session-file\=/Users/alimran/Library/Developer/Xcode/DerivedData/ModuleCache.noindex/Session.modulevalidation -fmodules-validate-once-per-build-session -Wnon-modular-include-in-framework-module -Werror\=non-modular-include-in-framework-module -Wno-trigraphs -fpascal-strings -O0 -fno-common -Wno-missing-field-initializers -Wno-missing-prototypes -Werror\=return-type -Wunreachable-code -Wno-implicit-atomic-properties -Werror\=deprecated-objc-isa-usage -Wno-objc-interface-ivars -Werror\=objc-root-class -Wno-arc-repeated-use-of-weak -Wimplicit-retain-self -Wduplicate-method-match -Wno-missing-braces -Wparentheses -Wswitch -Wunused-function -Wno-unused-label -Wno-unused-parameter -Wunused-variable -Wunused-value -Wempty-body -Wuninitialized -Wconditional-uninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-conversion -Wconstant-conversion -Wint-conversion -Wbool-conversion -Wenum-conversion -Wno-float-conversion -Wnon-literal-null-conversion -Wobjc-literal-conversion -Wshorten-64-to-32 -Wpointer-sign -Wno-newline-eof -Wno-selector -Wno-strict-selector-match -Wundeclared-selector -Wdeprecated-implementations -DDEBUG\=1 -DOBJC_OLD_DISPATCH_PROTOTYPES\=0 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.3.sdk -fasm-blocks -fstrict-aliasing -Wprotocol -Wdeprecated-declarations -g -Wno-sign-conversion -Winfinite-recursion -Wcomma -Wblock-capture-autoreleasing -Wstrict-prototypes -Wno-semicolon-before-method-body -fobjc-abi-version\=2 -fobjc-legacy-dispatch -index-store-path /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Index/DataStore -iquote /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/test-generated-files.hmap -I/Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/test-own-target-headers.hmap -I/Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/test-all-target-headers.hmap -iquote /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/test-project-headers.hmap -I/Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Products/Debug-iphonesimulator/include -I/Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/DerivedSources-normal/x86_64 -I/Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/DerivedSources/x86_64 -I/Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/DerivedSources -F/Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Products/Debug-iphonesimulator -MMD -MT dependencies -MF /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/Objects-normal/x86_64/main.d --serialize-diagnostics /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/Objects-normal/x86_64/main.dia -c /Users/alimran/workspace/reactnative/prod/test/ios/test/main.m -o /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/Objects-normal/x86_64/main.o
In file included from /Users/alimran/workspace/reactnative/prod/test/ios/test/main.m:3:
/Users/alimran/workspace/reactnative/prod/test/ios/test/AppDelegate.h:1:9: fatal error: 'React/RCTBridgeDelegate.h' file not found
#import <React/RCTBridgeDelegate.h>
        ^~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.

CompileC /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/Objects-normal/x86_64/AppDelegate.o /Users/alimran/workspace/reactnative/prod/test/ios/test/AppDelegate.m normal x86_64 objective-c com.apple.compilers.llvm.clang.1_0.compiler (in target 'test' from project 'test')
    cd /Users/alimran/workspace/reactnative/prod/test/ios
    export LANG\=en_US.US-ASCII
    /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -x objective-c -target x86_64-apple-ios10.0-simulator -fmessage-length\=0 -fdiagnostics-show-note-include-stack -fmacro-backtrace-limit\=0 -std\=gnu99 -fobjc-arc -fmodules -gmodules -fmodules-cache-path\=/Users/alimran/Library/Developer/Xcode/DerivedData/ModuleCache.noindex -fmodules-prune-interval\=86400 -fmodules-prune-after\=345600 -fbuild-session-file\=/Users/alimran/Library/Developer/Xcode/DerivedData/ModuleCache.noindex/Session.modulevalidation -fmodules-validate-once-per-build-session -Wnon-modular-include-in-framework-module -Werror\=non-modular-include-in-framework-module -Wno-trigraphs -fpascal-strings -O0 -fno-common -Wno-missing-field-initializers -Wno-missing-prototypes -Werror\=return-type -Wunreachable-code -Wno-implicit-atomic-properties -Werror\=deprecated-objc-isa-usage -Wno-objc-interface-ivars -Werror\=objc-root-class -Wno-arc-repeated-use-of-weak -Wimplicit-retain-self -Wduplicate-method-match -Wno-missing-braces -Wparentheses -Wswitch -Wunused-function -Wno-unused-label -Wno-unused-parameter -Wunused-variable -Wunused-value -Wempty-body -Wuninitialized -Wconditional-uninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-conversion -Wconstant-conversion -Wint-conversion -Wbool-conversion -Wenum-conversion -Wno-float-conversion -Wnon-literal-null-conversion -Wobjc-literal-conversion -Wshorten-64-to-32 -Wpointer-sign -Wno-newline-eof -Wno-selector -Wno-strict-selector-match -Wundeclared-selector -Wdeprecated-implementations -DDEBUG\=1 -DOBJC_OLD_DISPATCH_PROTOTYPES\=0 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.3.sdk -fasm-blocks -fstrict-aliasing -Wprotocol -Wdeprecated-declarations -g -Wno-sign-conversion -Winfinite-recursion -Wcomma -Wblock-capture-autoreleasing -Wstrict-prototypes -Wno-semicolon-before-method-body -fobjc-abi-version\=2 -fobjc-legacy-dispatch -index-store-path /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Index/DataStore -iquote /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/test-generated-files.hmap -I/Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/test-own-target-headers.hmap -I/Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/test-all-target-headers.hmap -iquote /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/test-project-headers.hmap -I/Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Products/Debug-iphonesimulator/include -I/Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/DerivedSources-normal/x86_64 -I/Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/DerivedSources/x86_64 -I/Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/DerivedSources -F/Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Products/Debug-iphonesimulator -MMD -MT dependencies -MF /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/Objects-normal/x86_64/AppDelegate.d --serialize-diagnostics /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/Objects-normal/x86_64/AppDelegate.dia -c /Users/alimran/workspace/reactnative/prod/test/ios/test/AppDelegate.m -o /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/Objects-normal/x86_64/AppDelegate.o
In file included from /Users/alimran/workspace/reactnative/prod/test/ios/test/AppDelegate.m:1:
/Users/alimran/workspace/reactnative/prod/test/ios/test/AppDelegate.h:1:9: fatal error: 'React/RCTBridgeDelegate.h' file not found
#import <React/RCTBridgeDelegate.h>
        ^~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.


** BUILD FAILED **


The following build commands failed:
    CompileC /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/Objects-normal/x86_64/main.o /Users/alimran/workspace/reactnative/prod/test/ios/test/main.m normal x86_64 objective-c com.apple.compilers.llvm.clang.1_0.compiler
    CompileC /Users/alimran/Library/Developer/Xcode/DerivedData/test-alolrygzfwbwxdfvdrglncimtovw/Build/Intermediates.noindex/test.build/Debug-iphonesimulator/test.build/Objects-normal/x86_64/AppDelegate.o /Users/alimran/workspace/reactnative/prod/test/ios/test/AppDelegate.m normal x86_64 objective-c com.apple.compilers.llvm.clang.1_0.compiler
(2 failures)

alimran@Als-MacBook-Air test % 

Please see the folder structure below.enter image description here I hope some have the proper solution for this problem. #Thanks


这是一个已知的 Flipper 问题

1条评论Flipper在 PodFile 上

  post_install do |installer|
    flipper_post_install(installer)
  end

2-安装吊舱cd ios/ && pod install

3-现在您应该能够运行模拟器了cd .. && yarn ios

这是以下方面的未决问题:https://github.com/facebook/flipper/issues/1940 https://github.com/facebook/flipper/issues/1940

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

构建 iOS 项目失败。我们运行了“xcodebuild”命令,但它退出并显示错误代码 65 的相关文章

  • ARM NEON 汇编器错误:“指令不能是有条件的”

    根据手臂信息中心 http infocenter arm com help index jsp topic com arm doc dui0489c CIHJCAAG htmlvadd 可以有条件地执行 但是当我尝试时 vaddeq f32
  • 在 React Native ios 应用程序中无法识别 fontFamily

    我正在努力获取我的字体 按开始2P 已加载 它是来自谷歌字体的字体 已多次执行以下步骤 以确保我没有马虎 从所有迹象来看 该字体应该在 React Native 应用程序中可用 在我的项目目录的根目录下创建了资产文件夹 在资产文件夹中创建字
  • 在导出之前将对象分配给变量作为模块默认警告

    import axios from axios const baseUrl http localhost 3001 persons const getAll gt return axios get baseUrl const create
  • Eslint 错误:不要嵌套三元表达式

    我正在使用 React js 开发一个项目 并且使用 eslint 时出现此错误 不要嵌套三元表达式 这是我的代码 const MyApp gt return lt gt var1 var2
  • 我以前从未见过的奇怪的 xCode 链接器错误说“断言失败”

    通过Unity构建了这个游戏 并通过xCode成功编译过一次 然而 如果没有任何明显的变化 就会出现此错误消息 我不明白从哪里开始寻找解决方案 但也许其他人有线索 我通过搜索看到了类似的错误 尽管与我的相比 这些修复似乎是任意的 有人能透露
  • 如何正确处理聊天消息应用程序的“已读”-“未读”状态?

    我目前正在开发一个反应本机应用程序 该应用程序使用 socket io 提供聊天室功能 我目前愿意处理消息的未读 已读状态 但我不知道该逻辑应位于何处 在客户端代码中还是在服务器端 这是我的代码组件的基本实现
  • React Table - useRowSelect 的单选输入

    如何在 React Table 中使用单选输入而不是复选框作为可选表 有一个复选框但没有单选按钮的示例 https github com tannerlinsley react table blob master examples row
  • React router 和 this.props.children - 如何将状态传递给 this.props.children

    我是第一次使用 React router 还不知道如何思考它 这是我在嵌套路由中加载组件的方法 入口点 js ReactDOM render
  • 在 Xcode Beta 中分发构建时“IPA 处理失败”

    在尝试分发 IPA 时 Xcode 抛出错误 IPA 处理失败 Steps 产品 gt 存档 gt 分发 gt 企业 开发 gt IPA 处理失败 Xcode Version 11 0 beta 3 11M362v OS 10 15 Bet
  • 如何在 React 中创建原子进程(async/await)?

    想象一下按下按钮即可点赞的帖子 此按钮会修改远程数据库 因此需要一些时间才能将点赞与特定帖子关联起来 现在 如果用户使用以下代码开始如此快速地按下按钮 state isLiked false handlePress gt this setS
  • '在捆绑 NSBundle 中找不到名为“MainTabController”的故事板

    我收到的似乎无法修复的错误是 由于未捕获的异常而终止应用程序 NSInvalidArgumentException 原因 找不到故事板 NSBundle 包中名为 MainTabController 应用程序将构建并显示登录屏幕 但随后立即
  • 在react js中触发更改或输入事件的最佳方式是什么

    我们使用 Backbone ReactJS 捆绑包来构建客户端应用程序 严重依赖臭名昭著的valueLink我们通过自己的包装器将值直接传播到模型 该包装器支持用于双向绑定的 ReactJS 接口 现在我们面临的问题是 We have jq
  • Swift PerformSegueWithIdentifier 不起作用

    我试图在用户成功登录其帐户后切换视图控制器 但它无法正常工作 我无法直接使用 segue 因为如果单击登录按钮 无论信息是否正确 它都会转到该视图控制器 我已经尝试了我所知道的一切 但没有成功 这是我正在尝试的代码 IBAction fun
  • typescript 如何输入类属性?

    我正在实现我的客户端渲染版本 我想输入我的route object 其结构如下 import Post from Post export const route path post component Post 请注意 Post 是一个未实
  • 如何与其他 ReactDOM.render 进行 ReactDOM.render 通信

    我有一个包含 React 应用程序和其他 HTML 元素的项目 它的意思是 ReactDOM render
  • 当我输入字母时,React 文本输入失去焦点

    我有一个文本输入字段 它是一个受控的 React 组件 当我在字段中输入字母时 输入失去焦点并且光标消失 有问题的文件是 src modules PollName js https codesandbox io embed wkl1kkp0
  • 自定义首次渲染反应本机选项卡导航

    有没有人知道如何设置初始路由 但不知道 tab screen 反应导航的部分 当我打开应用程序而没有从底部选项卡中选择焦点时 我想将主屏幕设置为默认屏幕 and when I press browse tab it s display th
  • 禁用应用程序的启动图像

    我想从我的应用程序禁用启动图像 我已经有一个启动屏幕 因此在应用程序启动时首先显示启动图像 然后显示启动屏幕 我想禁用启动图像并仅在应用程序启动时显示启动屏幕 请帮忙 提前致谢 你不能 因为它会一直保持到你的程序被加载并从applicati
  • Swiper 8 和笑话

    Swiper 8和Jest 支持ESM 必须使用import来加载ES模块在此输入图像描述 https i stack imgur com e3bB4 png 在此输入图像描述 https i stack imgur com nUmhq p
  • React cloneElement 未设置键

    我正在构建一个动态生成键的表控件 我理解这可能不是一个好主意 我想键应该与其代表的数据唯一关联 否则 React 只能为我们生成唯一的 id 但无论哪种方式似乎没有设置按键 我不知道为什么 表中的行是用可以找到的函数生成的here http

随机推荐