11

Apple has tricked me and even though I disabled autoupdates it now pulled the most recent XCode version (Version 10.0 (10A255)) and dependencies. The effect is that I can not build my app anymore, even after removing (ionic cordova platform remove ios) and re-adding the platform.

It now fails with the error below.

onic cordova run ios --debug --target="iPhone-8"  --consolelogs

...

<path>/platforms/ios/build/emulator/MyApp.app/Info.plist file not found.

[ERROR] An error occurred while running cordova run ios --debug --target iPhone-8 (exit code 1).

ionic --version
3.20.0

---- EDIT

ran with verbose and received :No scripts found for hook "before_deploy". as additional info for the failure.

----- EDIT ------

Please look here for more detail. I was able to reproduce it from scratch / a blank app template Blank app fails debug build - /Info.plist file not found

El Dude
  • 5,328
  • 11
  • 54
  • 101
  • Info.plist is a file which is a must for an ios app to build, please check manually by going to your project location ../iOS and look for .plist file. – Ashwani Sep 24 '18 at 05:13
  • The `ios/build` folder is missing. I found a `MyApp-Info.plist` in the `ios/MyApp` folder. Created a symbolic link `Info.plist` to that file, no avail. Not sure why the whole build folder is not being generated? – El Dude Sep 25 '18 at 04:46
  • Is there a way to run the `*.plist` generating script again? It seems to be missing... – El Dude Sep 26 '18 at 01:19
  • you have to open code using xcode. there you can create a plist file with all the permissions and version detail of the app – Ashwani Sep 27 '18 at 05:31
  • The plist file is in `/MyApp/platforms/ios/MyApp/MyApp-Info.plist`. However, it is not being copied nowhere... @Ashwani - any idea how to get it copied automatically during build? – El Dude Sep 27 '18 at 05:40
  • 2
    This link may solve you're problem. https://github.com/apache/cordova-ios/issues/407. Xcode10 isn't supported by Cordova as of right now. – Stephen Romero Oct 09 '18 at 13:25

2 Answers2

16

ionic cordova emulate ios -- --buildFlag="-UseModernBuildSystem=0"

Try this command it should work,this is issue with cordova.

Devi Kiran
  • 598
  • 1
  • 5
  • 17
  • This command worked for me. cordova run ios doesn't work for me and it does not launch the emulator. This is cordova cli v 8 and Mac OS Catalina. – user1261710 Aug 21 '20 at 10:11
14

If you're building on the command-line, try this

ionic cordova emulate ios -- --buildFlag="-UseModernBuildSystem=0"

or

Xcode 10

If you are opening the project in the Xcode IDE, you need to change the build system in Workspace Settings to "Legacy Build System"

Xcode example

enter image description here

enter image description here

Now, You can also run this on command-line $ionic cordova build ios

Best of luck

Abdul Hameed
  • 1,025
  • 13
  • 17