Blank app fails debug build - /Info.plist file not found

与世无争的帅哥 提交于 2019-11-28 21:37:34

This problem is caused because Xcode 10 contains a new build system which is currently not compatible with cordova-ios@4 - see here.

The solution for now is to run Cordova with the --buildFlag='-UseModernBuildSystem=0' option to instruct Xcode to use the old build system, e.g.:

 cordova run ios --debug --target "iPhone-8" --buildFlag='-UseModernBuildSystem=0'

Update: For my own convenience, I've wrapped this in a shell script:

#!/bin/bash
# Adds build flag to make cordova-ios@4 work with Xcode 10
cordova "$@" --buildFlag='-UseModernBuildSystem=0'

I saved this in a file called cordova-xcode10, made sure it's in the path and made it executable (chmod a+x cordova-xcode10), then I can just do:

cordova-xcode10 run ios --target "iPhone-8"

and it will work with Xcode 10

Manish

This problem is caused because of Xcode 10. I resolved this issue by two ways.

  1. ionic cordova build ios -- --buildFlag="-UseModernBuildSystem=0"

  2. Create a build.json file on root of project.

In build.json write below code.

{
    "ios": {
        "debug": {
            "buildFlag": ["-UseModernBuildSystem=0"]
        },
        "release": {
            "buildFlag": ["-UseModernBuildSystem=0"]
        }
    }
}

After that you can run these commands without any error.

  • ionic cordova build ios
  • ionic cordova run ios
  • ionic cordova run ios --target="iPhone-6s" -l

This worked for me

Open your workspace file, then File --> WorkSpace Settings

In shared Workspace settings, choose Build System: Legacy Build System.

Then run ionic cordova run -l

Source(last comment): https://forum.ionicframework.com/t/fresh-ionic-fails-to-emulate-ios-12-info-plist-file-not-found/142291

Update

I just found out that Cordova IOS 5.0.0 was released. https://cordova.apache.org/announcements/2019/02/09/cordova-ios-release-5.0.0.html

This worked for me:

cd platforms/ios/cordova && npm install ios-sim@latest
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!