Debugging iOS Apps

From RAD Studio
Jump to: navigation, search

Go Up to Debugging Multi-Device Applications

RAD Studio offers debugging in the IDE for iOS apps that are running on either the iOS Simulator or the iOS Device. For iOS apps, the debugging experience in the IDE is much like debugging Windows or Mac OS X applications in RAD Studio. However, the debugger functionality that is available to you varies according to the target platform and operating system. That is, the debugger for the iOS Simulator target platform (Mac OS X operating system) has more available features in the IDE than the debugger for the iOS Device - 32 bit and iOS Device - 64 bit target platforms (iOS operating system).

The following sections describe the availability of debugger features for the iOS Simulator, iOS Device - 32 bit, and the iOS Device - 64 bit.

iOS Simulator: Debugging Apps Running on the iOS Simulator

In general, this debugger gives you more complete functionality than the debugger for the iOS Device.

Evaluation and modification of properties are fully supported in iOS Simulator.

iOS Device: Debugging Apps Running on the iOS Device

Functionality for the debuggers for the 32-bit and 64-bit iOS Device are subject to platform-related differences between Windows and iOS.

In the Modules Window

  • Function entry is not supported.
  • The Entry point and Address columns are not populated.

In the Debug Inspector

  • Only the Data column is populated.
  • Methods and Properties are not shown.

Resolving bfd_mach_o_scan_read Errors

After updating to a new SDK or OS version, you might see warnings such as the following:

bfd_mach_o_scan_read_symtab_symbol: symbol "_strcmp" is unsupported 'indirect' reference: setting to undefined
bfd_mach_o_scan_read_symtab_symbol: symbol "_bzero" is unsupported 'indirect' reference: setting to undefined
bfd_mach_o_scan_read_symtab_symbol: symbol "_strchr" is unsupported 'indirect' reference: setting to undefined
bfd_mach_o_scan_read_symtab_symbol: symbol "_memset_pattern16" is unsupported 'indirect' reference: setting to undefined
bfd_mach_o_scan_read_symtab_symbol: symbol "_memcpy" is unsupported 'indirect' reference: setting to undefined
bfd_mach_o_scan_read_symtab_symbol: symbol "_memcmp" is unsupported 'indirect' reference: setting to undefined
bfd_mach_o_scan_read_symtab_symbol: symbol "_memchr" is unsupported 'indirect' reference: setting to undefined
bfd_mach_o_scan_read_symtab_symbol: symbol "_memccpy" is unsupported 'indirect' reference: setting to undefined
bfd_mach_o_scan_read_symtab_symbol: symbol "_memset_pattern8" is unsupported 'indirect' reference: setting to undefined

These warnings occur because the debugger uses SDK libraries instead of actual device libraries. To resync the files, run your iOS project from Xcode iOS projects templates (Empty iOS app, for example). The warnings should go away. If not, the warnings will go away after the device is upgraded to the next subminor iOS version. These warnings do not impact the debugging experience.

When Run Without Debugging, an iOS App Might Not Stop

Running an app on the iOS device without debugging might leave the app running, because the iOS installer is still attached to the program. Your iOS app might not stop when you close it, because the debugger is not running and therefore cannot stop the app.

In this case, you should close the connected PAServer instance on the Mac. (Enter the q command at the PAServer command prompt, >).

See Also