Submit Unity games to the Mac App Store!

First you must register with Apple to be an official Mac developer (costs $99).
http://developer.apple.com/devcenter/mac
Then you must download OS X 10.6.6, Xcode 3.2.5 and Application Tools 1.1
And, of course, you have to create your own App ID, Mac App and Installer Certificates. http://developer.apple.com/certificates/

After you are all setup as an Apple developer (see above) and have your Unity game developed, follow these steps to package your game for the Mac App Store…

  1. Build in Unity for Mac Intel Only

  2. Show Package Contents of the .app

2.a. Edit Info.plist
CFBundleShortVersionString
1.0.0
LSApplicationCategoryType
public.app-category.puzzle-games
NSHumanReadableCopyright
(c) 2010 Iterations Software LLC. All rights reserved.
CFBundleIdentifier
com.oneiteration.zenofclover
CFBundleVersion
1.0.0

2.b. Replace Resources/UnityPlayer.icns with one that is 512x512

2.c. Change permissions on /Data for “everyone” from “no access” to be “Read only”

  1. In Terminal…

3.a. codesign -f -s “3rd Party Mac Developer Application: randy edmonds” ZenOfClover.app

3.b. productbuild --component ZenOfClover.app /Applications --sign “3rd Party Mac Developer Installer: randy edmonds” zenofclover.pkg

3.c. Delete the .app file after productbuild has created the .pkg (or the installer test will not work).

3.d. sudo installer -store -pkg ZenOfClover.pkg -target /

  1. Verify that your app is installed in Applications

  2. Ready to submit the .pkg to iTunes Connect!

I have an app submitted and “waiting for review”. Hope it is accepted!

I have used the same process when I submitted the Fairy Cubes to the Mac Store. Waiting for review…

You, my good sir, are awesome.

I tried following the instructions presented here and it seems like my isntaller isn’t working properly. My app isn’t showing up under /Applications, and I’m getting a couple of weird errors in the installer test.

installer: Installation Check: Passed
installer: Volume Check: Passed
installer: Starting install
installer: Install 0.0% complete
2010-12-20 19:03:45.248 installer[5772:2403] PackageKit: *** Missing bundle identifier: /Library/Receipts/fbx20100_2_fbxextensionssdk_macos.pkg
2010-12-20 19:03:45.250 installer[5772:2403] PackageKit: *** Missing bundle identifier: /Library/Receipts/fbx20100_2_fbxsdk_macos.pkg
2010-12-20 19:03:45.252 installer[5772:2403] PackageKit: *** Missing bundle identifier: /Library/Receipts/Flip4Mac QuickTime Components.pkg
2010-12-20 19:03:45.253 installer[5772:2403] PackageKit: *** Missing bundle identifier: /Library/Receipts/Flip4Mac Web Plugins.pkg
installer: Install 5.3% complete
installer: Install 23.0% complete
installer: Install 28.5% complete
installer: Install 100.0% complete
installer: Finished install

Any help?

Are you sure you setup the bundle identifier under your Mac Developer Account correctly (and that your payment for your yearly subscriptiong went through) and that you don’t have typos in the plist?

i got the same errors when i follow the guide. I read some where that the mac installer may be broken on snow leopard but have no proove for that and no fix. Just trying to get the package done on an other mac.

But a solution for this bug would be very nice

Nice!! I was wondering about this… shame Unity Tech has not add this into the build options yet. Some of us are lazy. :slight_smile:

an Update to the problem Tetrad and I had:

I Updated Mac OS to the beta 10.6.6 build available in the Dev Center and now all works perfect.

I can call codesign with the certificates but productbuild is not available in the terminal. I’m not a MAC pro…but I have XCode 3.2.5.

Is there something basic I’m missing (like adding certificates in XCode and so on) ?

So I think the errors I was getting when testing the installer are pretty meaningless. I managed to fix them but on my iMac the installer still failed (as in, the app didn’t show up in /Applications). I tried doing the same thing on my Macbook Pro and it worked fine. But the pkg I made on the other computer (which worked there) still didn’t work on the iMac. So I’m leaning towards there’s some kind of bug.

Also Artial, you have to log into the mac dev center and download the “Application Tools”. They just updated to 1.1 yesterday so maybe that’ll fix some issues people were having…

Many thanks, the App Tools 1.1 gives me the productbuild command!

The missing bundle identifier messages can be ignored… however if you are not seeing your app in /Applications, it is probably because you didn’t do step “3.c”.

For whatever reason, if you .app is located anywhere else on your Mac, the installer does not write the app to /Applications… instead the installer will overwrite the .app in the location it already exists. From my experience, YOU HAVE TO DELETE every copy of the app from your machine or the installer will not write to /Applications. I suggest you use Spotlight to search for copies of your app and remove them all.

Just got a rejection letter in regards to using a private API (thread_stack_pcs) and playerprefs being saved to the wrong place.

Is this after you built with the latest 3.2.02b Unity beta build?

That was with the latest released version. I’m not aware of any beta version.

Go here and PM mantasp for the latest version:
http://forum.unity3d.com/threads/64453-Mac-App-Store?p=461654&viewfull=1#post461654

Hopefully that addresses your problem and you should have tomorrow to submit your app before the deadline.

Our game is on Mac App Store: :slight_smile:

http://itunes.apple.com/us/app/mr-hair-afro-estate-tycoon/id432893561?mt=12&ls=1

I use his method:

http://technology.blurst.com/unity-games-and-mac-app-store/

I do NOT use variables such as “$version” or “$game” but instead of “1.0” or “Mr. Hair”.

Hi, all. I’m putting together my first Mac App Store submission and I’m following the instructions Randy and every have put together here and everything goes fine until I get to the step where I create the signed installer:

i.e. 3.b. productbuild --component ZenOfClover.app /Applications --sign “3rd Party Mac Developer Installer: randy edmonds” zenofclover.pkg

When I enter this command int the terminal, it throws an error indicating that it doesn’t recognize the --sign option, starting like this:

e.g. productbuild: unrecognized option `–sign 3rd Party Mac Developer Installer: (etc.) …

I know that I have the strings right because they (or similar ones) worked when I used them in executing the codesign command in the terminal. And I do indeed have both my App and Installer certificates installed in the keychain.

So, anyone have any idea what might be going on here? Oh, please? :wink:

I think the problem may be that I don’t have Application Tools 1.1 installed.

Unfortunately, Apple pulled that download apparently when they released XCode 3.2.6 and SDK 4.3 - which doesn’t like Unity so I can’t upgrade to it.

Does anyone have a copy of the Application Tools 1.1 installer lying around that they could share with me? :slight_smile:

I’m having what appears to be the same problem.

When I enter the “productbuild --component … -sign …” line in the terminal to sign and build the package, I get an error stating that “–sign” is an unrecognized command.

I’m using the last drop of XCode 3.x and SDK 4.3 but haven’t installed Application Tools 1.1 since those files are no longer available. I assume that the stuff they added was incorporated into the final XCode 3.x build - is that wrong?

Any help would be greatly appreciated!