使用 Xcode 4 进行 iPhone 特别构建

发布于 2024-10-22 02:22:36 字数 140 浏览 4 评论 0原文

我刚刚切换到 Xcode 4,需要进行临时构建,以便我的客户可以测试我的应用程序。然而,我找到的每个教程都是基于 Xcode 3 的,而我似乎无法在 Xcode 4 上找到我需要执行的类似设置和操作的方法。有教程或任何东西可以帮助我吗?我用谷歌搜索了它,但结果很差。

I just switched to Xcode 4 and need to make an ad hoc build so my customer can test my app. Yet every tutorial I find is based on Xcode 3 and I can't seem to find my way with Xcode 4 on similar settings and actions I need to do. Is there a tutorial or anything out there that can help me on this? I googled it but with very poor results.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

情话墙 2024-10-29 02:22:36

确保您从下拉菜单中选择了设备而不是模拟器。

然后在 XCode 4 中转到 product ->存档

构建完成后,打开管理器并选择Archives

在这里您将找到您的构建,然后您可以从这里选择共享,接下来 XCode 将询问使用哪个配置文件来签署应用程序。

现在您已经创建了一个 IPA,您可以将其发送给测试人员。

Make sure you have selected a device from the drop down menu and not the simulator.

Then in XCode 4 go to product -> archive.

After the build is complete open the organizer and selected Archives.

Here you will find your build, from here you can then select share, next XCode will ask with which profile to sign the app.

Now you have created an IPA which you can send to your testers.

樱娆 2024-10-29 02:22:36

我也找不到这方面的最新(2013 年 8 月)信息,特别是将该应用程序分发给使用 PC(而不是 Mac)的 iPhone 用户的信息。通过对 Google 结果进行排序,我发现了很多关于 iTunes Connect 和 Validation 的冗余且令人困惑的信息。

以下是对我有用的方法:

  1. 您无需在 iTunes Connect 中创建应用程序记录 - 这仅适用于您想要将其放入商店的情况。如果这就是您想要的,请查看以下内容: https://developer.apple.com/library/ios/documentation/ToolsLanguages/Conceptual/YourFirstAppStoreSubmission/CreateYourAppRecordiniTunesConnect/CreateYourAppRecordiniTunesConnect.html

  2. 您无需验证您的应用。这仅适用于您想将其放入商店时。如果这就是您想要的,请查看以下内容:https: //developer.apple.com/library/ios/recipes/xcode_help-archives_organizer/articles/validating_apps.html

  3. 您确实需要一个临时配置文件。要获取一个,请按照“创建临时配置文件”标题下的说明进行操作:https://developer.apple.com/library/ios/documentation/IDEs/Conceptual/AppDistributionGuide/TestingYouriOSApp/TestingYouriOSApp.html。下载“name.mobileprovision”文件后,请确保双击该文件,将其添加到 Xcode。

  4. 不要浪费时间在 Xcode 项目/构建设置中查找临时代码签名权利。它没有出现在我的 Xcode 副本中,而且我也不需要它。

  5. 即使临时代码签名权利没有出现在项目/构建设置中,您也可以在管理器/设备/库/配置文件中看到它。它将具有您在第 3 步中指定的名称。

  6. 现在您已准备好构建用于 Ad-Hoc 分发的应用版本:

  7. 在 Xcode 中,确保您位于项目窗口中,选择了您的项目,并根据上面接受的答案,选择了 iOS 设备左上角靠近“运行/停止”按钮的字段中的构建目标。

    1. 从 Xcode 菜单栏中,选择 Product/Build for.../Archiving(如果“Build For...”选项呈灰色,则您可能位于项目窗口以外的某个窗口中,例如 Organizer 窗口)。

    2. 从 Xcode 菜单栏中选择“产品/存档”

    3. 打开管理器窗口(Shift-Cmd-2),选择顶部中间的“档案”图标。

    4. 突出显示您要分发的版本,然后点击右侧的“分发”按钮。

    5. 选择“保存用于企业或临时部署”选项。

    6. 出现“选择要签名的身份”对话框。从下拉列表中,选择您在第 3 步中创建的 iOS 发行版。对于我来说,带有我在第 3 步中创建的名称的行显示为灰色,但其正下方的行有效。

    7. 出现一个对话框,允许您命名 Ad-Hoc 应用程序并将其另存为 .ipa 文件。

  8. 在 Windows 电脑上:

    1. 将 YourApp.ipa 文件和 name.mobileprovision 文件复制到桌面等位置。

    2. 在 iTunes 中,找到主菜单(任务栏左上角可能有一个小图标),然后选择“将文件添加到资料库... Ctrl+O< /kbd>“

    3. 将这两个文件添加到库中。

    4. 将 iPhone 插入 Windows PC

    5. 转至 iTunes 的 iPhone 部分,然后转至“应用程序”选项卡。如果幸运的话,您将看到 YourApp,然后您可以单击“安装”。

I also couldn't find current (August 2013) information on this, particularly for distributing the app to iPhone users with PCs, not Macs. Sorting through the Google results, I found a lot of redundant and confusing information about iTunes Connect and Validation.

Here's what worked for me:

  1. You don't need to create an app record in iTunes Connect—that's just for when you want to put it in the store. If that's what you want, look at this: https://developer.apple.com/library/ios/documentation/ToolsLanguages/Conceptual/YourFirstAppStoreSubmission/CreateYourAppRecordiniTunesConnect/CreateYourAppRecordiniTunesConnect.html

  2. You don't need to Validate your app. That's just for when you want to put it in the store. If that's what you want, look at this: https://developer.apple.com/library/ios/recipes/xcode_help-archives_organizer/articles/validating_apps.html

  3. You do need an Ad-Hoc provisioning profile. To get one, follow the instructions under the heading: "Creating Ad Hoc Provisioning Profiles" at: https://developer.apple.com/library/ios/documentation/IDEs/Conceptual/AppDistributionGuide/TestingYouriOSApp/TestingYouriOSApp.html. Make sure you double click on the 'name.mobileprovision' file after you download it, to add it to Xcode.

  4. Don't waste time looking in your Xcode Project/Build Settings for an Ad-Hoc Code Signing Entitlement. It doesn't appear in my copy of Xcode, and I didn't need it.

  5. Even though the Ad-Hoc Code Signing Entitlement doesn't appear in the Project/Build Settings, you can see it in the Organizer/Devices/Library/Provisioning Profiles. It will have the name you gave it in step 3.

  6. Now you are ready to build a version of your app for Ad-Hoc distribution:

  7. In Xcode, make sure you are in your project window, with your project selected, and according to the accepted answer above, the iOS Device selected as the build target in the field at the top left adjacent to the Run/Stop buttons.

    1. From the Xcode Menu Bar, select Product/Build for…/ Archiving (if the "Build For…" options are greyed out, you may be in some window other than the project window, for example the Organizer window).

    2. From the Xcode menu bar, select Product/Archive

    3. Open the Organizer window (Shift-Cmd-2), select the Archives icon at the top in the middle.

    4. Highlight the version you want to distribute, and click on the "Distribute" button over on the right.

    5. Select the "Save for Enterprise or Ad-Hoc deployment" option.

    6. A "Choose an identity to sign with" dialog appears. From the dropdown list, select the iOS Distribution one you created in step 3. For me, the line with the name I created in Step 3 was greyed out, but the one directly below it worked.

    7. A dialog appears allowing you to name and save your Ad-Hoc app as an .ipa file.

  8. On your Windows PC:

    1. Copy the YourApp.ipa file and the name.mobileprovision file to somewhere like the desktop.

    2. In iTunes, find the main menu (maybe a little icon in the top left of the task bar), and select "Add File to Library… Ctrl+O"

    3. Add both the files to the library.

    4. Plug the iPhone in to the Windows PC

    5. Go to the iPhone section of iTunes, then to the Apps tab. With any luck you'll see YourApp, and you can click on Install.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文