error Failed to build iOS project. We ran “xcodebuild” command but it exited with error code 65

前端 未结 13 1303
礼貌的吻别
礼貌的吻别 2020-11-29 23:58

I\'ve build a react-native application and suddenly I get this error message on my terminal during run of the command react-native run-ios. The same code work fine 10 minute

相关标签:
13条回答
  • 2020-11-30 00:10

    After upgrading react-native, you may have stale dependencies. The steps below should fix it.

    1. cd ios
    2. delete Podfile.lock
    3. pod deintegrate && pod install
    4. Navigate back to package.json directory
    5. run react-native run-ios
    6. In Xcode you can build your project again too

    Hope this helps, I did this after upgrading to react-native 0.61

    0 讨论(0)
  • 2020-11-30 00:12
    1. delete the build/ folder in ios/ and rerun if that doesn't do any change then
    2. File -> Project Settings (or WorkSpace Settings) -> Build System -> Legacy Build System
    3. Rerun and voilà!

    In case this doesn't work, don't be sad, there is another solution to deeply clean project

    1. Delete ios/ and android/ folders.

    2. Run react-native eject

    3. Run react-native link

    4. react-native run-ios

    This will bring a whole new resurrection for your project

    0 讨论(0)
  • 2020-11-30 00:12

    run pod install inside ios folder then go back to root folder and run npx react-native run-ios

    0 讨论(0)
  • 2020-11-30 00:13

    If you don't have cocoa pods installed you need to sudo gem install cocoapods

    1. run cd ios
    2. run pod install
    3. cd ..
    4. delete build folder
    5. run react-native run-ios

    if error persists, 1. delete build folder again 2. open the /ios folder in x-code 3. navigate File -> Project Settings -> Build System -> change (Shared workspace settings and Per-User workspace settings): Build System -> Legacy Build System

    0 讨论(0)
  • 2020-11-30 00:17

    Should always start with the simplest first, after wasting hours and days on this error.

    And after an extensive amount of research,

    Simply

    RESTART YOUR MACHINE
    

    This resolved this error.

    I'm on

    react-native-cli: 2.0.1
    react-native: 0.63.3
    
    0 讨论(0)
  • 2020-11-30 00:19

    SOLVED: Always be sure to update your Xcode folks!

    Protip: And don't do it from the apple store (but always do it from an official apple website of course)

    tip from: http://ericasadun.com/2016/03/22/xcode-upgrades-lessons-learned/

    official apple download page: https://developer.apple.com/download/more/

    For those who are unable to resolve with above method

    1. Go to project settings in Xcode. Menu File->Project Settings

    2. Go to per-User Project Settings section.

    3. Click on advanced.

    4. Select Xcode Default option. previously this used to be Legacy for my project.

    I have analysed on similar lines and concluded that clean is causing the archive to fail. So, the new build system is not clearing the custom/legacy build directory.

    delete the build/ folder in ios/ and rerun if that doesn't do any change then
    File -> Project Settings (or WorkSpace Settings) -> Build System -> Legacy Build System
    Rerun and voilà!
    

    If it still Fails you need to clean full project

    Do the following:

    • Delete ios dir manually
    • Clean cache Run npm cache clean --force
    • Run react-native eject
    • Re-install all packages npm install
    • Run the link command react-native link
    • Finally run react-native run-ios
    0 讨论(0)
提交回复
热议问题