Jailbroken iPhone 3G with iOS 4.2.1 can't be debugged with XCode

前端 未结 6 1653
难免孤独
难免孤独 2020-12-17 05:36

I\'m trying to debug my applications with XCode 3.2.5 and jailbroken iPhone 3G with iOS 4.2.1.

When I start debug with enabled breakpoints, applicat

相关标签:
6条回答
  • 2020-12-17 05:53

    Additional suggestion besides Fnord's suggestion is to make sure that multitasking, or the "Reenable Functionality" in PwnageTool is not enabled for iPhone 3G jailbroken device.

    I'm not sure if this has an effect though. But, it's reasonable to do this if we really want to test it on a real world condition of iPhone 3G.

    0 讨论(0)
  • 2020-12-17 05:54

    My completely non-Jailbroken iPhone does this with 4.2.1, and gets exactly the same messages and problems. It's new functionality in the latest version of XCode, so it may well be buggy.

    0 讨论(0)
  • 2020-12-17 05:57

    The latest Xcode+SDK drop doesn't know about iOS 4.2.1, because it was published before the latest patch came out. Xcode's Organizer has a new feature that tries to download debug support files directly from the device, but apparently it has some (possibly jailbreak-related) issues for some people.

    iOS 4.2.1 is similar enough to 4.2 that Xcode can be coerced to use 4.2 support files to debug on 4.2.1 devices. To do this, simply go to the /Developer/Platforms/iPhoneOS.platform/DeviceSupport folder and manually copy the Symbols subfolder and/or the DeveloperDiskImage.* files from 4.2 (8C134) to 4.2.1 (8C148) (or whatever release folder Organizer creates for your device).

    0 讨论(0)
  • 2020-12-17 06:02

    In order to get rid of (Re)Collecting Debug Symbols in Organizer (which in fact does nothing) each time the iPhone is presented to the XCode, a simple workaround is to copy:

    DeveloperDiskImage.dmg and DeveloperDiskImage.dmg.signature

    from the 4.2 (8C134) to the empty 4.2.1 (8C148) folder.

    The XCode will recognize device and you'll be able to debug your code, but without debug symbols for the IOS framework. But, the gdb console will be alive and you can use it do debug your code (with debug symbols).

    Btw. you can always use Simulator for the full IOS support :-)

    0 讨论(0)
  • 2020-12-17 06:08

    Jailbroken 3GS / 4.2.1

    I tried Matthew Frederick's recommendation without success. Anyone happened to find a solution to this problem?


    EDIT

    Please note that I used a jailbroken 3GS and a non-jailbroken 3GS. Workaround, requires a non-jailbroken iPhone 3GS with 4.2.1 (8C148a):

    1. Delete /Developer/Platforms/iPhoneOS.platform/DeviceSupport/4.2.1 (8C148a)
    2. Connect the non-jailbroken iPhone 3GS with 4.2.1 (8C148a)
    3. Open Xcode and Organizer
    4. Configure the new iPhone for development by clicking the "Use for development" button in the Organizer.
    5. Let it extract the debugging symbols from it recreating /Developer/Platforms/iPhoneOS.platform/DeviceSupport/4.2.1 (8C148a)
    6. Unplug it, remove from Organizer

    At this point you can debug your jailbroken iPhone again. Cheers!

    0 讨论(0)
  • 2020-12-17 06:09

    It's likely that your problem can be solved by reauthorizing your device:

    1. If your iPhone is plugged into the computer, unplug it

    2. In Xcode, display the Organizer (Window->Organizer)

    3. In the Devices area click on your device and delete it.

    4. Just in case, Quit Xcode and then re-launch it.

    5. Open the Organizer again, then plug your iPhone into your computer.

    6. Tell Xcode that yes, you'd like to authorize the device.

    7. If everything works correctly, Xcode will now download device information for 4.2.1.

    If this doesn't work then I suggest performing the steps again, but replace step 4 with removing all traces of Xcode from your computer and then reinstalling it. This includes the entire Developer folder.

    0 讨论(0)
提交回复
热议问题