Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice
  3. Dismiss Notice

App rejected, Unsupported Architecture

Discussion in 'macOS' started by User340, Jul 22, 2018.

  1. User340

    User340

    Joined:
    Feb 28, 2007
    Posts:
    3,001
    My Mac app recently got rejected by iTunes Connect. See below for error. Any idea as to what's going on? I have submitted this app many times in the past and didn't get this error.

    Unsupported Architecture - Application executables may support either or both of the Intel architectures:

    • i386 (32-bit)
    • x86_64 (64-bit)
    Other architectures may not be included in submitted binaries. Confirm that your Xcode project's build settings include those architectures and no others.
    Specifically, we found the following unsupported architectures in your binary:
    • i386 (in com.mycompanyname.myappname.pkg/Payload/myapp.app/Contents/Plugins/FileBrowserBundle.bundle/Contents/MacOS/FileBrowserBundle)
     
  2. giorgos_gs

    giorgos_gs

    Joined:
    Apr 23, 2014
    Posts:
    623
    same here
     
  3. giorgos_gs

    giorgos_gs

    Joined:
    Apr 23, 2014
    Posts:
    623
    .NET 4.x with both MONO and IL2CPP fails because the include some lib only support i386, and do not have x64. Only .NET 3.5 MONO works.
     
  4. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,938
    We're shipping changes in the next 2018.2 release of Unity which remove the i386 slice from the Mono binary, so this should not be a problem any more.
     
  5. giorgos_gs

    giorgos_gs

    Joined:
    Apr 23, 2014
    Posts:
    623
    This is a good opportunity to fix another bug that rejects our Mac builds.
    Apple request to unlink the GameKit framework
    Please put a choice in the Mac player settings to link/unlink the Gamekit framework.
    This would be a very useful feature. Now we cannot submit, only with a dirty hack.
     
  6. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,938
    I'm not too familiar with this issue, but could you submit a bug report for this?
     
  7. giorgos_gs

    giorgos_gs

    Joined:
    Apr 23, 2014
    Posts:
    623
  8. giorgos_gs

    giorgos_gs

    Joined:
    Apr 23, 2014
    Posts:
    623
    I read old forums that had the same error, now it reappeared.
     
  9. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,938
    I think this is definitely worth a bug report. Can you submit one?
     
  10. giorgos_gs

    giorgos_gs

    Joined:
    Apr 23, 2014
    Posts:
    623
  11. giorgos_gs

    giorgos_gs

    Joined:
    Apr 23, 2014
    Posts:
    623
    I can submit a new one.
     
  12. User340

    User340

    Joined:
    Feb 28, 2007
    Posts:
    3,001
    My rejection did not mention Mono, but it mentioned my plugin FileBrowserBundle. Does macOS standalone support 32 bit or is it exclusively 64 bit (2017.4)? I'm not sure with how to proceed in regards to fixing this problem. I have submitted my app with this plugin many times in the past without issue.
     
  13. User340

    User340

    Joined:
    Feb 28, 2007
    Posts:
    3,001
    See attachment, the inspector for my plugin does not even have an x86 option, only x64. Yet Apple still claims that it has x86.

    Another thing that doesn't make sense to me. Apple says that binaries must be i386 or x86_64, and that any other type will be rejected. By my binary IS x86, so I am totally complying to their request yet still getting rejected.

    Screen Shot 2018-07-27 at 3.46.22 PM.png
     
  14. greg-harding

    greg-harding

    Joined:
    Apr 11, 2013
    Posts:
    525
    We've hit problems like this too.

    You can check what slices your binaries have with 'lipo'. For example, check your plugin in a built app using;
    > lipo -info Your.app/Contents/Plugins/x86_64/YourPluginName


    You can remove unwanted slices like;
    > lipo Your.app/Contents/Plugins/x86_64/YourPluginName -thin x86_64 -output Your.app/Contents/Plugins/x86_64/YourPluginName
     
    Gametyme and User340 like this.
  15. User340

    User340

    Joined:
    Feb 28, 2007
    Posts:
    3,001
    @greg-harding Thanks a bunch! You're a life saver, my app has passed processing!
     
  16. greg-harding

    greg-harding

    Joined:
    Apr 11, 2013
    Posts:
    525
    No problem - nice work!
     
  17. manelroure

    manelroure

    Joined:
    May 2, 2014
    Posts:
    1
    This is because since January 2018 Apple no longer accepts architectures other than 64 bits. Recently I found the same problem, I finally solved it by eliminating the i386 architecture of each one of the plugins that contained it.

    In the same way I also use "lipo" to solve it.

    From terminal:

    $ lipo [FolderWhereYourAppFileIs / Your.app / Contents / Plugins / PluginName.bundle / Contents / MacOS / PluginName] -output [FolderWhereYourAppFileIs / Your.app / Contents / Plugins / PluginName.bundle / Contents / MacOS / PluginName] -remove i386

    I also notice that you may find other errors, such as the collision of the plugin if there is already a version of the app in the IOS Apple Store, for this you must modify the Info.plist of each plugin in the .app. You can change for example the <CFBundleIdentifier>, with that would be enough.

    Another error that can result in the validation of the Mac Apple Store is this:
    "unsealed contents present in the bundle root"

    To fix it, it is convenient to delete all .meta files from all your plugins in the .app.

    Although I must say that I'm still trying to solve another problem, due to the bad behavior of the fullscreen option in macOS, Apple keeps rejecting my app. ¬¬

    Any help on the problem of fullscreen in macOS?

    Thank you and good luck to those who develop an app for the Apple Store Mac!
     
    MidnightGameDeveloper likes this.
  18. Oscar-Tsang

    Oscar-Tsang

    Joined:
    Nov 7, 2012
    Posts:
    85
    I have sent Bug report to Unity, but no one following my case. I suggest everyone send your bug report to Unity. Let them know we need publish to macStore. Not simply can build a mac app is enough.

    Meet macStore requirement is the most important!
    All other improvements are nothing, if you cannot publish to macStore.
     
    User340 likes this.
  19. dmko

    dmko

    Joined:
    Jun 15, 2014
    Posts:
    65
    Using the latest 2018 beta, these files cause the error - with settings IL2CPP and .NET 3.5:

    Contents/Frameworks/MonoBleedingEdge/MonoEmbedRuntime/osx/libMonoPosixHelper.dylib, Contents/Frameworks/MonoBleedingEdge/MonoEmbedRuntime/osx/libmonobdwgc-2.0.dylib

    What's the fix (I guess I'll try setting .NET 4.0..)
     
  20. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,938
    Regarding these two files, the next 2018.2 patch release and the first 2018.3 beta (both yet to ship) should have the 32-bit slice removed from both files.
     
  21. dmko

    dmko

    Joined:
    Jun 15, 2014
    Posts:
    65
    switching to .NET 4.0 did not fix it - but the lipo approach did :)
     
  22. Oscar-Tsang

    Oscar-Tsang

    Joined:
    Nov 7, 2012
    Posts:
    85
    How about the GameKit framework? How to unlink it?
     
  23. AMA_MR

    AMA_MR

    Joined:
    Mar 23, 2018
    Posts:
    17
    I've had to use lipo to strip unsupported architectures from various 3rd-party libraries as well.

    I'll second (third, fourth?) that request for a GameKit-unlink option as well.
     
  24. freak77

    freak77

    Joined:
    Nov 19, 2016
    Posts:
    5
    Still no solution for Gamekit-unlink?

    I got a reject for my new Mac App game. I'm using latest version of Unity.
     
  25. User340

    User340

    Joined:
    Feb 28, 2007
    Posts:
    3,001
    Are any of your scripts referencing Game Center? I have submitted my app many times without any mention from Apple in regards to Gamekit.
     
  26. richardzzzarnold

    richardzzzarnold

    Joined:
    Aug 2, 2012
    Posts:
    145
    Still no solution for Gamekit-unlink?

    I got a reject for my new Mac App game.and I'm using Unity 2018.3.0b3
     
  27. Xander-Davis

    Xander-Davis

    Joined:
    Apr 23, 2011
    Posts:
    441
  28. MidnightGameDeveloper

    MidnightGameDeveloper

    Joined:
    Apr 26, 2014
    Posts:
    123
    Thank you SOOOO much for your post, it helped me a lot! I was getting all the errors you mentioned in your post...

    I have noticed the same problem with the fullscren option on macOS. For now i have set the Screenmode and Resolution in script, with this i could get rid of the "black bars" at the top and bottom of the screen. But i dont know if thats enough...

    Code (CSharp):
    1. Screen.SetResolution(Screen.resolutions[Screen.resolutions.Length-1].width, Screen.resolutions[Screen.resolutions.Length-1].height, true);