Ad Hoc distribution. Can it be done without XCode?

Discussion in 'iPhone/iPad Programming' started by jerrywickey, Jun 22, 2009.

  1. macrumors member

    I want to test my app on a freind's iPhone. I have his iPhone's ID, a provisioning profile for his phone and could install it from XCode, but he doesn't have XCode and lives a hundred miles away. He has iTunes.

    I already sent him the provisioning profile, but which app file do I send him? found in build\distribuion-iphoneos turns out to be a directory, not a file.

  2. macrumors 6502a

    You need to send him the .app bundle - just zip it up first and send it over.
  3. Moderator


    Staff Member

    You want to follow the instructions in the Program Portal > Distribution > Prepare App, in particular steps 13 and 14. This will create the desired zip file.
  4. macrumors member

    I tried several different things, including sending the zip.

    Remember, he does not have XCode. If he did, it wouldn't be a problem. He is using iTunes to sync his iPhone. iTunes takes the provisioning file. It will not take the zip or any other file.

    Is there somewhere special in iTunes he needs to place the zip file?

  5. Moderator


    Staff Member

    According to the Program Portal:
    Did you build your application with Xcode for distribution?
  6. macrumors 6502a

    It needs unzipping before you drop it in iTunes.
  7. macrumors member

    I did build it for distribution.

    He did unzip it before dropping it in. He dropped every file which came out of the zip into iTunes and synced the iPhone, but the app did not appear.

    It seems to me that their should be a single app binary file somewhere which contains the provisioning data specific to that iPhone, so that only that single file should be needed. But I didn't write the iPhone OS.

    Any other ideas how he might be able to test my app?

    Perhaps go through the steps you would use.

    1) obtain his device 40 hex ID
    2) obtain an ad hoc provisioning profile for the app and his phone
    3) send via email to him the provisioning file names *.??? and the app file named *.??? found in the ???? directory
    4) he drops both into iTunes and syncs his iPhone
    5) he enjoys the app

    By the way here are the portal's instructions for ad hoc distribution in their entirety
    Are there more detailed instructions anywhere? If so, where?

  8. Moderator


    Staff Member

    Yes, there are more details in other parts of the portal. For example, "1) Create and Download an iPhone Distribution Certificate" has more instructions under Distribution > Obtaining your iPhone Distribution Certificate. Similar sections can be found within the portal for the other pieces, except for probably steps 4 and 5.
  9. macrumors member

    Well, there ya' go. Steps 4 and 5 are with what I need help.

    What application file. zip goes to iStore distribution and presumably also to ad hoc distribution, but the iTunes app makes no provisions for it. Unless there is a undocumented directory in which to place the zip.

    Does anyone know which file and in what directory XCode may have placed it?

  10. macrumors 6502a

    #10 *is* the application. It will show up as a folder as in Windows as that's essentially what it is and Windows knows nothing about .app packages - look at all of your Mac apps in Finder > Applications - all .app, all folders. You can right click on any of them and select "Show Package Contents".

    If the recipient is on a mac just right click on the .app bundle and select "Compress" and send them the zip. They unzip and drag the .app bundle to iTunes. If they are on Windows, the "Compress" option might not work, see this article:

    If you look inside the .app bundle you will find an actual compiled binary in there but that alone is not the whole app.
  11. macrumors member

    Thanks for the link. That might be helpful. but it really just says the whole ad hoc process is a bitch.

    So what my friend on whose iPhone this will be installed needs to drop the into iTunes and sync his iPhone?

    He has already tried that. That is the first thing we tried.

    He is using iTunes on a windows machine.

    Just what should he be doing instead?

    He should drop the provisioning profile into iTunes
    Drop the ????? zip or each file ????? into iTunes
    Sync his iPhone

    It must be different than this because this is exactly what didn't work.

  12. macrumors 6502a

    The following steps work for me:

    1. Xcode settings: Device, Release.
    2. Build.
    3. Products > > Reveal in Finder.
    4. Right click, compress.
    5. Send, along with the PP with which you built the app.

    At the other end:

    1. Extract from
    2. Drag & drop into the "Library" section of iTunes.
    3. Likewise the PP.
    4. Attach device, tick in Applications tab.
    5. Hit "sync".
  13. macrumors 6502a

    I don't think I could have been much clearer, but your friend must unzip the package first, and drop onto iTunes.
  14. macrumors 603

    Used to be that if you zipped up the app bundle up inside a Payload directory and renamed the resulting .zip to an .ipa, you could drop this zip file on top of iTunes in Windows (after the matching PP).

    Does this still work?

    And if not, what changed? (Maybe using the compress command from the Finder, or ditto, to create the zip?)
  15. macrumors newbie

    Windows Ad Hoc

    I just figured out the "trick" on iTunes. I had a good and on my beta distribution server (from which I download them to each PC with the browser) and they worked fine on a Mac. On Windows you do indeed seemingly need to EXTRACT the files from the zip. On the MAC you can simply drag and drop them in zipped form. The TRICK on Windows was in where to DROP the EXTRACTED files in iTunes to get them to "take." I kept getting the circle/bar "can't drop here" mouse pointer UNTIL I hovered over the Library section on the left menu section. I didn't have an Applications item in the Library section because on this particular machine there were no Apps. My Ad Hoc app was the first. It's confusing because if you try to drop anywhere else you get the "no drop" icon.

    I think it might be easier to just go to the App Store in iTunes and download a free app just to create this window in the library then open the window and drag and drop to it.

    There are a lot of places in the Windows world where you can swerve into a ditch with this process.

    Hope this little bit extra helps.

    Oh yes. My Macbook is running the latest update of Leopard and my test PC is running Windows XP.

Share This Page