Launch installed app on tethered iPhone

后端 未结 3 918
挽巷
挽巷 2021-01-12 01:37

I\'m working on trying to launch an automated testing solution for some iOS applications. I\'m using fruitstrap to transfer and install a compiled app over to the connected

3条回答
  •  梦谈多话
    2021-01-12 02:05

    Creating a bootstrap program and using URL Schemes may be an option for some people, and certainly should be considered, but it doesn't fit into my requirements.

    What I ended up doing was to launch the app with the debugger through fruitstrap. I re-compiled fruitstrap to include the following prep commands (In the GDB_PREP_CMDS define):

    handle all noprint pass nostop
    continue
    

    The handle will pass the signal on to the program so the custom signal handler (crash handler in this case) will handle the signal. The continue was something I needed so that the app would actually run once the debugger started.

    There is one unfortunate flaw in this, which unfortunately I do not know a workaround for. The ARM7 version of GDB does not have the 'set dont_handle_bad_access' command like the darwin version does. For some reason passing EXC_BAD_ACCESS signals to the program does not work and the app hangs. This is significant since this is the signal for most crashes. But as it stands now, its the best I can do, and at least its handling uncaught exceptions.

提交回复
热议问题