Search Unity

XCode codesign error for MacStore using Unity 2019.3.0a7

Discussion in 'macOS' started by richardzzzarnold, Jul 14, 2019.

?

Is it impossible to publish to the Mac AppStore with Unity in 2019?

  1. Yes

    12 vote(s)
    85.7%
  2. No

    2 vote(s)
    14.3%
  1. richardzzzarnold

    richardzzzarnold

    Joined:
    Aug 2, 2012
    Posts:
    140
    I was happy to find that Unity 2019.3 was able to generate codesigned XCode projects ready for upload to the Mac App Store, which I thought would have fixed the nightmarish and actually now impossible process of uploading correctly packaged apps to the Mac AppStore.

    Unfortunately, it still doesn't seem to work properly.

    When I make a build with the Scripting Backend IL2CPP I get the following error:
    ......
    .app/Contents/Frameworks/GameAssembly.map: No such file or directory

    and when I build with the Scripting Backend Mono I get the following error:

    .app/Contents/Frameworks/MonoBleedingEdge: bundle format unrecognized, invalid, or unsuitable


    Either way, it seems impossible, yet again, to clear this hurdle.

    I have tried innumerable permutations in order to get it codesigned correctly but it always stops at one of these two points.

    Is there any likelihood of Unity actually making it possible to achieve?
    They claim that they can publish to the Mac App Store, and while that used to be true, I am not sure that it is still.

    Is there anyone out there that could provide a useful suggestion on how to achieve the seemingly impossible?

    Much thanks
     
  2. vanmani

    vanmani

    Joined:
    Jul 11, 2012
    Posts:
    6
    Just here to say I am also finding it's impossible to codesign the MonoBleedingEdge framework that is included in Unity 2019.2 builds, as above. Which in turn means you cannot notarize the app, and which in turn means nobody on newer versions of MacOS can run your app regardless of how you distribute it. Pretty critical problem.

    It was also impossible to notarize on Unity 2019.1 builds, which is why I started trying 2019.2 builds in the first place.
     
  3. adam_unity574

    adam_unity574

    Joined:
    Apr 3, 2018
    Posts:
    1
    I'm also having this problem after updating to 2019.2.
    Builds from 2018.1 had the MonoBleedingEdge/etc folder under the Contents directory (eg. Contents/MonoBleedingEdge/etc), but this has been moved into the Frameworks directory. ( Contents/Frameworks/MonoBleedingEdge/etc)

    It seems as though the numbered directories ( 2.0, 4.0, 4.5 ) are to blame. Renaming them seems to satisfy the codesign tool, but of course the application won't run.

    There's a note here about periods in directory names that might explain something:

    Note that a location where code is expected to reside cannot generally contain directories full of nested code, because those directories tend to be interpreted as bundles. So this occasional practice is not recommended and not officially supported. If you do do this, do not use periods in the directory names. The code signing machinery interprets directories with periods in their names as code bundles and will reject them if they don't conform to the expected code bundle layout.​
     
  4. wagenheimer

    wagenheimer

    Joined:
    Jun 1, 2018
    Posts:
    323
  5. richardzzzarnold

    richardzzzarnold

    Joined:
    Aug 2, 2012
    Posts:
    140
    Yes, but you have to upgrade to Unity 2020
     
  6. DevPz

    DevPz

    Joined:
    Sep 26, 2013
    Posts:
    6
    Unity 2020.1.0.a11 still repros :/
     
  7. DevPz

    DevPz

    Joined:
    Sep 26, 2013
    Posts:
    6
    Worked with switching to mono backend instead of il2cpp
     
  8. richardzzzarnold

    richardzzzarnold

    Joined:
    Aug 2, 2012
    Posts:
    140
    Hi DevPc , I did it it in Mono. I tried it also in il2cpp but it threw up a whole lot of other problems. I can confirm that I was able to upload Mac standalone builds to the store using Unity 2020 ( if not a3, then a7, but I am pretty sure I did it with a3 ). There IS another code signing issue that has to be solved within XCode. Screen Shot 2.jpg
    In CodeSigningEntitlements in XCode, you need to select Mac Developer in "CodeSigningIdentity" and write in your 4-part bundle identifier in "CodeSigningEntitlements". This needs to be in the format "XXXXXXX.com.companyName.gameName".
    And of course sandbox needs to be activated inXcode capabilities like so: Screen Shot 2019-11-06 at 08.28.19.png

    Nothing in Mac store builds is easy any more. But it IS possible.

    After successfully uploading you app to the store, you will most likely be presented with this new issue which is a new Apple 2019 security feature:
    "your app requests admin access from the user during operation of requesting Key Strokes access."
    https://forums.developer.apple.com/thread/125303

    I am not sure yet how to correct this, but will post it here when I have it figured out. Or if you work how to bypass this, please share.
     
    Last edited: Nov 7, 2019
  9. manga-79

    manga-79

    Joined:
    Mar 14, 2014
    Posts:
    3
    Hey Richard
    I am facing the same issue with "your app requests admin access from the user during operation of requesting Key Strokes access." Did you get any clue about this? I just don't have any idea how to solve this?!

    Ranko
     
  10. richardzzzarnold

    richardzzzarnold

    Joined:
    Aug 2, 2012
    Posts:
    140
    Hi Ranko, I believe this problem was so fresh at the time that I thought that I would wait to find out from someone else how to solve it. So no, sorry, I cant help you.
     
  11. manga-79

    manga-79

    Joined:
    Mar 14, 2014
    Posts:
    3
    Hi Richard.

    Thank you for your reply.
    I will let you know if I find solution in meantime.
    It is surprising that no one knows how to fix this even at this time.
    AppStore is rejecting binaries. I hope unity will step up.

    Regards

    Ranko
     
  12. richardzzzarnold

    richardzzzarnold

    Joined:
    Aug 2, 2012
    Posts:
    140
  13. ManeTI

    ManeTI

    Joined:
    May 11, 2017
    Posts:
    1
    Hey guys, I've found a workaround, moving the MonoBleedingEdge folder inside Resources and leaving a symlink that points to the new path in it's place inside Framework fix the issue.