본문 바로가기

about DEV

Ad-Hoc App Distribution with XCode 4

 Xcode4로 개발프로그램을 바꾼지, 꽤 되었는데 정작 빌드/아카이브 등이 많이 달라져서 잘 사용하지 않고 있다가, 애드훅버젼에서는 기존과 같이 단순 빌드로는 안되는 것을 확인하고 부랴부랴 관련 자료를 찾아봤다.  구글링으로 많이도 나와있지만, 정작 너무 긴 설명과 눈에 잘 보이지도 않는 영어 블라블라로.. 그나마 심플하고 알아보기(?)쉬운 원문을 긁어왔다.

이런 아카이브로 하는게 무척 쉽긴 한데... 근데 아직까지, 아이튠즈에 판매등록하는 방식은 기존의 방식이 더 쉬운거 같긴 하다. 아무래도 익숙해서 그렇겠지만...

원문 URL : http://diaryofacodemonkey.ruprect.com/2011/03/18/ad-hoc-app-distribution-with-xcode-4/

So amongst the many nice features in XCode 4 comes the modified process for building your app for distribution. And with “The Google” not being entirely helpful about the process as well as the docs on the Apple developer site still containing the XCode 3 instructions I thought it would help at least somebody out there for me to document the process. Please note that since I haven’t built one yet for distribution to the app store this just covers ad-hoc distribution. Maybe I’ll update this when we release to the app store.

Interacting with the provisioning portal hasn’t changed. You still need to create your distribution profile and download it to your development machine. Once you’ve done that is where the process has changed.

Like in XCode 3 you still need to create a new configuration for your distribution build. Click on your project in the project navigator and click on the your project in the project editor. You should see something like this:

 

As before you’ll want to create a copy of your release configuration and name it something like “Ad-Hoc”. Once you’ve done that click on the “Build Settings” tab in the project editor. You should see something like this:

 

Change your Code Signing Identity to match your Ad-Hoc distribution provisioning profile. Now in the upper left hand corner of XCode next to the Run and Stop buttons click the Scheme dropdown and click Edit Scheme. In the scheme editor select Archive from the left side and change the Build Configuration to the configuration you created previously (Ad-Hoc for me):

 

Click OK to close it. Verify that you have a iOS device selected in the scheme dropdown in XCode and then select the Archive option from the Product menu:

 

This will build your project and create the archive. If the Organizer doesn’t pop up after it is done building  just open it by clicking the Organizer button:

 

Select your new archive and click the Share button (I imagine the Submit button here has to do with submitting to the app store):

 

Leave it on “iOS App Store Package (.ipa)” and select your distribution profile in the identity (you may be able to say “Don’t Re-sign” but I haven’t tried that yet) and click Next:

 

Save it to whatever location and now you have an IPA file to drag into iTunes.