9

我读过 iPhone SDK(Xcode 3 的一部分)仅限于带有英特尔芯片组的 Mac。此限制是否仅适用于 SDK 的模拟器部分或完整的 shebang?

我有一台运行 Leopard 的 Powerbook G4,非常想在它上面进行开发,而不是购买一台新机器。

同样值得澄清的是,我出于个人原因对开发感兴趣,因此接受我需要一个经过认证的平台来为 App Store 创建提交。

4

4 回答 4

7

As things have moved on since the original post on 3by9.com, here are the steps that I had to follow to get the environment working on my PowerBook G4.

BTW, I would like to say that I realise that this is not a supported environment and I share this for purely pedagogic reasons.

  1. Download and install the iPhoneSDK (final version)
  2. After the install finishes, navigate to the packages directory in the mounted DMG
  3. Install all of the pkg's that start with iPhone
  4. Copy the contents of /Platforms to /Developer/Platforms (should be two folders starting with iPhone)
  5. Locate 'iPhone Simulator Architectures.xcspec' in /Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Xcode/Specifications and open in a text editor.
  6. Change line 12 to: Name = "Standard (iPhone Simulator: i386 ppc)";
  7. Change line 16 to: RealArchitectures = ( i386, ppc );
  8. Add the following to line 40 onwards:
    // PowerPC
    { Type = Architecture;
    Identifier = ppc;
    Name = "PowerPC";
    Description = "32-bit PowerPC";
    PerArchBuildSettingName = "PowerPC";
    ByteOrder = big;
    ListInEnum = NO;
    SortNumber = 106;
    },
  1. Save the file and start Xcode
  2. You should see under the New Project Folder the ability to create iPhone applications.
  3. To get an app to work in the simulator (and using the WhichWayIsUp example) open Edit Project Settings under the Project menu
  4. On the Build tab change the Architectures to: Standard (iPhone Simulator:i386 ppc)
  5. Change Base SDK to Simulator - iPhone OS 2.0
  6. Build and go should now see the app build and run in the simulator
于 2008-09-05T11:48:40.800 回答
2

iPhone SDK 被记录为需要基于 Intel 的 Mac。即使有些人能够让它在其他硬件上运行并不意味着它会正确运行,Apple 会修复您报告的错误,或者它是受支持的环境。

于 2008-09-01T22:39:06.310 回答
1

如果你真的想在设备上运行你的二进制文件,而不仅仅是模拟器,你需要来自以下页面的建议:

http://discussions.apple.com/thread.jspa?messageID=7958611

它涉及一个 Perl 脚本,该脚本执行一些“魔术”以使代码签名在 PowerPC 上工作。您还需要从 SDK 包中安装 Developer Disk Image。当一切都说完后,您可以使用 G4 在真实设备上进行开发,甚至调试器也可以工作。但我认为仪器不起作用。

于 2008-09-22T21:37:10.297 回答
1

我有一台运行 Leopard 的 Powerbook G4,非常想在上面做开发

不确定您正在开发哪种应用程序,但如果您越狱 iPhone,您可以:

  • 使用 Ruby/Python/Java 开发完全不需要编译的应用程序
  • 在手机上编译(!),因为在 Cydia 中安装了 GCC/工具链 - 虽然我不知道这需要多长时间,或者您是否可以简单地使用常规 iPhone SDK 项目并将其通过 SSH 连接到手机,并运行xcodebuild

应该能够从 PPC 机器编译 iPhone 应用程序,因为您可以从 Intel Mac 编译 PPC 应用程序,反之亦然,不应该有任何理由不能从 PPC 编译 ARM 二进制文件。不是 Apple 在 Xcode 中包含必要的东西来允许这是另一回事.. Ingmar 发布的步骤似乎暗示你可以..?

于 2008-09-01T22:58:47.213 回答