Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

unity 4.2.1 ios7 build crahes in start-up ( with xcode 5 )

Discussion in 'iOS and tvOS' started by booleangame, Sep 14, 2013.

  1. booleangame

    booleangame

    Joined:
    Sep 14, 2013
    Posts:
    1
    hi everyone~ I`m upgrading my ios app to obtain ios7 compatibility

    but it keeps crashing in start-up with error message “Failed to load AOT module mscorlib in aot-only mode.”

    I`ve already read the solution in unity wiki

    "Problem: Program crashes and debugger reports: “Failed to load AOT module ... in aot-only mode.”

    Possible Causes: Unknown cause. Possibly another bug in the Unity iPhone build pipeline.
    Possible Solution: Delete the app in the device (using Xcode Organizer) then install it again. "

    I tried it but it`s not worked.

    any solutions???
     
  2. _Max_

    _Max_

    Joined:
    Feb 21, 2013
    Posts:
    160
    I got 4.2.1 and iOS7, Xcode loads up and nothing happens, similar issues..
     
  3. iossif

    iossif

    Joined:
    Mar 4, 2011
    Posts:
    332
    does not surprise me. i guess one of the next unity updates will support ios7.
     
  4. Mantas-Puida

    Mantas-Puida

    Unity Technologies

    Joined:
    Nov 13, 2008
    Posts:
    1,864
    Sounds like you Xcode project is broken. When building from Unity try to choose replace instead of appending existing Xcode project.
     
  5. _Max_

    _Max_

    Joined:
    Feb 21, 2013
    Posts:
    160
    So you telling me, u have the latest Unity3d and Xcode 5 and you tested, and works for you??
    Confirm this please.
     
  6. Mantas-Puida

    Mantas-Puida

    Unity Technologies

    Joined:
    Nov 13, 2008
    Posts:
    1,864
    Yes, Unity 4.2.1 is tested to work with Xcode 5 GM fine (except build&run and some bugus warnings).
     
  7. _Max_

    _Max_

    Joined:
    Feb 21, 2013
    Posts:
    160
    sounds like you have not tested on own machine to confirm..anyway thank you..
     
  8. Graham-Dunnett

    Graham-Dunnett

    Unity Technologies

    Joined:
    Jun 2, 2009
    Posts:
    4,287
    Mantas is our lead iOS dev. I'd fully expect he's tested on his own machine if he says it works.
     
  9. _Max_

    _Max_

    Joined:
    Feb 21, 2013
    Posts:
    160
    Actually I'm very suspicious about your claims, considering the Xcode 5 GM build was only released the other day.
    So personally I do not believe this has gone through proper testing, this is my opinion.

    $Error.png

    So lets look at example screenshot.
    Firstly un-ticking the external Xcode 4 does nothing.

    So with it ticked it produces a error as seen on screen visible in Unity3d editor.
    So is Unity trying to launch Xcode 4 or looking for it?

    - Two things happened here, either you have not tested latest Xcode Build to confirm to community.
    - Second its my machine setup when installing Xcode 5 overiding Xcode 4 - which could be the case also I admit.
    - Under external tools no mention of Xcode 5- so you saying also by default Xcode 5 acts as Xcode 4
     
    Last edited: Sep 16, 2013
  10. Mantas-Puida

    Mantas-Puida

    Unity Technologies

    Joined:
    Nov 13, 2008
    Posts:
    1,864
    This error (and the tick in Editor) is related to Build&Run function, which is not working with Xcode 5 GM as I mentioned above. Though this error isn't fatal, it just means you need to open project in Xcode and hit Build manually. Yes, I tested it on my machine with various Unity 4.x flavours and it works.

    Typically top 2 reasons why people get error like the one you posted above are:
    a) Broken Xcode project. (Solution is just to rebuild from Unity and replace project from scratch instead of appending)
    b) Broken Unity installation. Solution is reinstalling it by using these precaution steps:
    - unmount all Unity install images in Finder
    - re-mount the latest Unity dmg
    - run the installer
    - open your project with freshly installed Unity and replace your Xcode project when building with it.
     
  11. Skyrise

    Skyrise

    Joined:
    Nov 3, 2005
    Posts:
    158
    All our projects compile and run just fine with Unity 4.2.1 and Xcode 5 GM.
    As Mantas said, only build and run is not working and there are some warnings.
     
  12. OceanBlue

    OceanBlue

    Joined:
    May 2, 2013
    Posts:
    251
    I'm curious - can you have both xcode 4 and xcode 5 on your machine and build to the xcode of your choosing?
     
  13. Mantas-Puida

    Mantas-Puida

    Unity Technologies

    Joined:
    Nov 13, 2008
    Posts:
    1,864
    Yes, that's is possible. Though Unity will prefer Xcode 5 for opening project and Build&Run won't work for it, but you still can manually open project in any Xcode you want and click build there.
     
  14. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,555
    Yesterday I bought Mountain Lion, installed it, then got Xcode 5. Not only can I not build run, I can't even open XCode 5. It never starts up. Not sure if that's because it can't start up with a Unity 4.2 project from last session or what. Anything I should try? I ALWAYS use Replace, not Append.
     
  15. Casio

    Casio

    Joined:
    Jul 16, 2012
    Posts:
    28
    BUMP!

    When will Unity be updated to fix what apple changed in the scripting interface of XCODE 5 so we can get back to automatic build and run?

    For those of you who have this problem you can simply remove XCODE 5 and go get the last build of XCODE 4 from the apple developer site and install it and get back to mostly normal.