iPhone Dev:Xcode调试器不会在断点上停止 [英] iPhone Dev: Xcode debugger does not stop on breakpoints

查看:156
本文介绍了iPhone Dev:Xcode调试器不会在断点上停止的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在OS X 10.5.5上有Xcode 3.1.2。我有一个iPhone项目构建良好,但调试器不会打到我设置的任何断点。我已经尝试了我在网上找到的所有标准修复程序:


  1. 我已经在Xcode首选项中关闭了加载符号Lazily

  2. 我的活动配置是Debug

  3. 构建设置中的优化级别为0

  4. 我已经全部清理目标和重建

  5. 我使用构建和调试(而不是构建和运行)

我以为我可能无意中调整了我的项目的设置。所以我创建了一个新项目,并且有一个同样的问题。



我希望我在这里遗漏一些容易的东西。我的调试器刚刚工作了几天,但突然间已经停止了。






更新:

事情只是越来越陌生了。以下是答复的一些答案


  1. 我无法在任何地方找到GCC 4.0 - 代码生成选项。我在目标和可执行信息页面中都看到了高和低。我看到的唯一选择是选择编译器版本,并选择GCC 4.0,但这是一个没有其他选项的单行部分。

  2. 关于放置断点的位置:我唯一的现在的断点是在main(),并且它没有被击中

  3. 我正在使用Run - > Debug(/%Y)命令启动调试器。仍然没有运气






更新2:




  1. 将目标设置中的基本SDK更改为Sim 2.2.1。将Active SDK更改为Sim 2.2.1。

  2. 现在我可以看到GCC 4.0代码生成选项 - 检查符号

  3. 仍然没有打破断点

这里是控制台日志(在main.m的第一行设置断点):

  [会话开始于2009-03-06 21:29:19 -0600。] 
将程序加载到调试器...
GNU gdb 6.3.50 -20050815(Apple版本gdb-962)(Sat Jul 26 08:14:40 UTC 2008)
版权所有2004免费软件基金会,
GDB是免费软件,涵盖了GNU通用公共许可证,并且您在
欢迎更改它和/或在特定条件下分发它的副本。
输入show copy来查看条件。
GDB绝对没有保修。输入显示保修的详细信息。
这个GDB配置为i386-apple-darwin.warning:无法读取/System/Library/Frameworks/UIKit.framework/UIKit的符号(找不到文件)。
警告:无法从UIKit读取符号(尚未映射到内存中)。
警告:无法读取/System/Library/Frameworks/CoreGraphics.framework/CoreGraphics的符号(找不到文件)。
警告:无法从CoreGraphics读取符号(尚未映射到内存中)。
程序加载。
sharedlibrary apply-load-rules all
附加到程序:`/ private / var / root / Library / Application Support / iPhone Simulator / User / Applications / 753D12B3-777C-473B-B098-3E0AF6282545 / TestApp .app / TestApp',进程577.
重新启用共享库断点1

此处还有gdb log:

  t = 0.000852 Tepoch = 1236463545.631514 
< (gdb)
- > 135-gdb-version
#PBXGDB_MIGDBVersionCommand t = 4.308986 Tepoch = 1236463549.939648
- > 136-gdb-set auto-raise-load-levels 1
#PBXGDB_MISetAutoRaiseSymbols t = 4.309420 Tepoch = 1236463549.940082
- > 139-gdb-set env __CF_USER_TEXT_ENCODING 0x0:0:0
#PBXGDB_MISetEnvCommand t = 4.309702 Tepoch = 1236463549.940364
- > 140-gdb-set env USERBREAK 1
#PBXGDB_MISetEnvCommand t = 4.309935 Tepoch = 1236463549.940598
- > 141-gdb-set env DYLD_FRAMEWORK_PATH / Projects / TestApp / build / Debug-iphonesimulator
#PBXGDB_MISetEnvCommand t = 4.310175 Tepoch = 1236463549.940837
- > 142-gdb-set env Apple_PubSub_Socket_Render / tmp / launch-GqkpX5 / Render
#PBXGDB_MISetEnvCommand t = 4.310568 Tepoch = 1236463549.941231
- > 143-gdb-set env SECURITYSESSIONID 715cd0
#PBXGDB_MISetEnvCommand t = 4.310803 Tepoch = 1236463549.941465
- > 144-gdb-set env DYLD_LIBRARY_PATH / Projects / TestApp / build / Debug-iphonesimulator
#PBXGDB_MISetEnvCommand t = 4.311040 Tepoch = 1236463549.941702
- > 145-gdb-set env SSH_AUTH_SOCK / tmp / launch-hRgLzb / Listeners
#PBXGDB_MISetEnvCommand t = 4.311299 Tepoch = 1236463549.941961
- > 146-gdb-set env HOME / var / root
#PBXGDB_MISetEnvCommand t = 4.311587 Tepoch = 1236463549.942250
- > 147-gdb-set env SHELL / bin / sh
#PBXGDB_MISetEnvCommand t = 4.311818 Tepoch = 1236463549.942480
- > 148-gdb-set env DYLD_NO_FIX_PREBINDING YES
#PBXGDB_MISetEnvCommand t = 4.312048 Tepoch = 1236463549.942710
- > 149-gdb-set env COMMAND_MODE unix2003
#PBXGDB_MISetEnvCommand t = 4.312281 Tepoch = 1236463549.942943
- > 150-gdb-set env DYLD_NEW_LOCAL_SHARED_REGIONS YES
#PBXGDB_MISetEnvCommand t = 4.312546 Tepoch = 1236463549.943209
- > 151-gdb-set env SSH_ASKPASS /Developer/Library/PrivateFrameworks/DevToolsInterface.framework/Resources/Xcode SSHPassKey
#PBXGDB_MISetEnvCommand t = 4.312780 Tepoch = 1236463549.943443
- > 152-gdb-set env PATH / Developer / usr / bin:/ usr / bin:/ bin:/ usr / sbin:/ sbin
#PBXGDB_MISetEnvCommand t = 4.313612 Tepoch = 1236463549.944275
- > 153-gdb-set env DISPLAY / tmp / launch-yrv3vV /:0
#PBXGDB_MISetEnvCommand t = 4.313849 Tepoch = 1236463549.944512
- > 154-gdb-set env USER root
#PBXGDB_MISetEnvCommand t = 4.314141 Tepoch = 1236463549.944803
- > 155-gdb-set env NSUnbufferedIO YES
#PBXGDB_MISetEnvCommand t = 4.314377 Tepoch = 1236463549.945039
#命令中的入队序列Q:< PBXGDB_SetupSharedLibrarySequence:0x9049db0> t = 4.314625 Tepoch = 1236463549.945288
#执行顺序:< PBXGDB_SetupSharedLibrarySequence:0x9049db0> t = 4.314718 Tepoch = 1236463549.945380
- > 157-gdb-set inferior-auto-start-cfm off
#PBXGDB_MISetLoadCFMInfoCommand t = 4.314895 Tepoch = 1236463549.945557
- > 156-gdb-set sharedLibrary load-rules dyld。* Foundation。*all dyld。* libobjc。*all dyld。* libauto。*all dyld。* / usr / lib / dyld。*all dyld* CFDataFormatters. *all dyld* PBGDBIntrospectionSupport。*所有dyld* AppKit。*所有dyld。* libSystem。*所有dyld* CarbonDataFormatters *所有dyld* CoreFoundation *extern dyld/ System / Library / Frameworks\\\\ | / System / Library / PrivateFrameworks\\\\ || / usr / libextern dyld*extern exec 。*extern
#PBXGDB_MISetSharedLibraryLoadSymbolsCommand t = 4.315975 Tepoch = 1236463549.946637
- > 137-file-exec-and-symbols/ private / var / root / Library / Application Support / iPhone Simulator / User / Applications / 09734C45-F595-4CB9-8707-744E92D66245 / TestApp.app / TestApp
# PBXGDB_MILoadExecutableCommand t = 4.320612 Tepoch = 1236463549.951275
#命令中的Enqueue seq Q:< PBXGDB_FixAndContinueIsSupportedSequence:0x9bdc260> t = 4.321476 Tepoch = 1236463549.952138
#命令中的Enqueue seq Q:< PBXGDB_NewBreakpointSequence:0xa516f90> t = 4.321941 Tepoch = 1236463549.952603
#命令中的Enqueue seq Q:< PBXGDB_AttachControlSequence:0xa4fceb0> t = 4.322157 Tepoch = 1236463549.952820
< - 〜GNU gdb 6.3.50-20050815(Apple version gdb-962)(Sat Jul 26 08:14:40 UTC 2008)\\\

< ; - 〜版权所有2004免费软件基金会,Inc. \
- 〜GDB是免费软件,由GNU通用公共许可证覆盖,您不欢迎更改它和/或在某些条件下分发它的副本。\\\
Type \显示复制\以查看条件。\GDB绝对不保证GDB。请输入\显示保修。详细信息。\
< - 〜这个GDB被配置为i386-apple-darwin\。
< - 135 ^ done,version =6.3.50-20050815(Apple version gdb-962),rc_version =962,target =i386-apple-darwin,build-date =Sat 7月26日08:14:40 UTC 2008,time = {wallclock =0.03311,user =0.00081,system =0.00014,start =1236463549.989179,end =1236463550.022291}
#结果t = 4.392345 Tepoch = 1236463550.023007
< - (gdb)
< - 136 ^ done,time = {wallclock =0.00005,user =0.00005,system =0.00001 =1236463550.024272,end =1236463550.024325}
#处理结果t = 4.394163 Tepoch = 1236463550.024826
< - (gdb)
< - 139 ^ done,time = {wallclock = 0.00007,user =0.00005,system =0.00002,start =1236463550.025511,end =1236463550.025581}
#处理结果t = 4.395347 Tepoch = 1236463550.026010
< )
< - 140 ^ done,time = {wallclock =0.00003,user =0.00003,system =0.00001,start =1236463550.026564,end =1236463550.026597}
#处理结果t = 4.396328 Tepoch = 1236463550.026991
< - (gdb)
< - 141 ^ done,time = {wa llclock =0.00003,user =0.00003,system =0.00001,start =1236463550.027857,end =1236463550.027890}
#处理结果t = 4.397653 Tepoch = 1236463550.028315
< (gdb)
< - 142 ^ done,time = {wallclock =0.00003,user =0.00003,system =0.00001,start =1236463550.029080,end =1236463550.029113}
#处理结果t = 4.398865 Tepoch = 1236463550.029528
< - (gdb)
< - 143 ^ done,time = {wallclock =0.00003,user =0.00003,system =0.00001 ,start =1236463550.030126,end =1236463550.030159}
#处理结果t = 4.399923 Tepoch = 1236463550.030585
< - (gdb)
< - 144 ^ done,time = {wallclock =0.00003,user =0.00003,system =0.00001,start =1236463550.031449,end =1236463550.031482}
#处理结果t = 4.401855 Tepoch = 1236463550.032518
< - (gdb)
< - 145 ^ done,time = {wallclock =0.00003,user =0.00003,system =0.00001,start =1236463550.033257,end =1236463550.033291}
#processing result t = 4.403022 Tepoch = 1236463550.033685
< - (gdb)
< - 146 ^ done,time = {wallclock =0.00006,user =0.00003,system =0.00002,start =1236463550.034226 1236463550.034287}
#处理结果t = 4.404018 Tepoch = 1236463550.034680
< - (gdb)
< - 147 ^ done,time = {wallclock =0.00003,user =0.00003 ,system =0.00001,start =1236463550.035215,end =1236463550.035247}
#处理结果t = 4.405007 Tepoch = 1236463550.035670
< - (gdb)
< 148 ^ done,time = {wallclock =0.00003,user =0.00003,system =0.00001,start =1236463550.036306,end =1236463550.036340}
#处理结果t = 4.406068 Tepoch = 1236463550.036731
< - (gdb)
< - 149 ^ done,time = {wallclock =0.00003,user =0.00003,system =0.00001,start =1236463550.037344 1236463550.037377}
#处理结果t = 4.407107 Tepoch = 1236463550.037770
< - (gdb)
< - 150 ^ done,time = {wallclock =0.00003,user = 0.00003,system =0.00001,start =1236463550.038448,end =1236463550.038483}
#处理结果t = 4.408214 Tepoch = 1236463550.038876
< - (gdb)
< - 151 ^ done,time = {wallclock =0.00003,user =0.00003,system =0.00001 =1236463550.040541,end =1236463550.040576}
#处理结果t = 4.410438 Tepoch = 1236463550.041101
< - (gdb)
< - 152 ^ done,time = {wallclock = 0.00003,user =0.00003,系统=0.00001,开始=1236463550.041901,结束=1236463550.041933}
#处理结果t = 4.411665 Tepoch = 1236463550.042327
< )
< - 153 ^ done,time = {wallclock =0.00003,user =0.00003,system =0.00001,start =1236463550.042984,end =1236463550.043016}
#处理结果t = 4.412784 Tepoch = 1236463550.043446
< - (gdb)
< - 154 ^ done,time = {wallclock =0.00003,user =0.00002,system =0.00001 start =1236463550.043956,end =1236463550.043988}
#处理结果t = 4.413717 Tepoch = 1236463550.044379
< - (gdb)
< - 155 ^ done,time = {wallclock =0.00003,user =0.00003,system =0.00001,start =1236463550.044974 ,end =1236463550.045007}
#处理结果t = 4.414737 Tepoch = 1236463550.045400
< - (gdb)
< - 157 ^ done,time = {wallclock =0.00003 ,user =0.00003,system =0.00001,start =1236463550.046108,end =1236463550.046141}
#处理结果t = 4.415931 Tepoch = 1236463550.046594
< - (gdb)
< - 156 ^ done,time = {wallclock =0.00005,user =0.00005,system =0.00001,start =1236463550.050271,end =1236463550.050324}
# = 4.420235 Tepoch = 1236463550.050897
- > 158sharedlibrary apply-load-rules all
#PBXGDB_MISharedLibraryApplyLoadRulesCommand t = 4.420386 Tepoch = 1236463550.051049
< - (gdb)
< - &警告:无法读取\/系统/库/框架/ UIKit.framework / UIKit\(找不到文件).\\\

< - &警告:无法从\UIKit\读取符号但是映射到内存中).\\\

< - &警告:无法读取\/System/Library/Frameworks/CoreGraphics.framework/CoreGraphics\的文件(未找到文件) .\\\

< - &警告:无法从\CoreGraphics\中读取符号(尚未映射到内存中).\\\

< - 137 ^完成,time = {wallclock =0.34917,user =0.17115,system =0.11409,start =1236463550.052577,end =1236463550.401747}
#处理结果t = 4.771918 Tepoch = 1236463550.402580
< - (gdb)
< - &sharedlibrary apply-load-rules all\\\

< - 158 ^ done
#处理结果t = 4.820019 T epoch = 1236463550.450681
#didFinish序列:< PBXGDB_SetupSharedLibrarySequence:0x9049db0> t = 4.820135 Tepoch = 1236463550.450797
#执行顺序:< PBXGDB_FixAndContinueIsSupportedSequence:0x9bdc260> t = 4.820259 Tepoch = 1236463550.450921
- > 159-mi-verify-command file-fix-file-is-grooveved
#PBXGDB_MIVerifyCommandCommand t = 4.820398 Tepoch = 1236463550.451060
< - (gdb)
< - 159 ^ done,name =file-fix-file-is-grooveved,defined =true,implements =true,time = {wallclock =0.00011,user =0.00007,system =0.00001,start =1236463550.451848 ,end =1236463550.451955}
#处理结果t = 4.821746 Tepoch = 1236463550.452409
- > 160-file-fix-file-is-grooveved
#PBXGDB_MIFixAndContinueSupportedCommand t = 4.821894 Tepoch = 1236463550.452556
< - (gdb)
< - 160 ^ done,supported =1 details =Yes grooveved!,time = {wallclock =0.00006,user =0.00005,system =0.00002,start =1236463550.453356,end =1236463550.453417}
# 4.823203 Tepoch = 1236463550.453865
#didFinish序列:< PBXGDB_FixAndContinueIsSupportedSequence:0x9bdc260> t = 4.823344 Tepoch = 1236463550.454006
#执行序列:< PBXGDB_NewBreakpointSequence:0xa516f90> t = 4.823433 Tepoch = 1236463550.454095
#通过破产前状态的验证命令t = 4.823569 Tepoch = 1236463550.454231
- > 161-break-insert -l -1 -f -sTestApp\main.m:13\
#PBXGDB_MICreateFileBreakpointCommand t = 4.823679 Tepoch = 1236463550.454342
< - (gdb )
< - = shlib-state-modified,shlib-info = [num =1,name =TestApp,kind = - ,dyld-addr = - ,reason =exec ,requested-state =Y,state =Y,path =/ private / var / root / Library / Application Support / iPhone Simulator / User / Applications / 09734C45-F595-4CB9-8707-744E92D66245 / TestApp。 app / TestApp,description =/ private / var / root / Library / Application Support / iPhone Simulator / User / Applications / 09734C45-F595-4CB9-8707-744E92D66245 / TestApp.app / TestApp,loaded_addr = =0x0,prefix =,dsym-objpath =/ Projects / TestApp / build / Debug-iphonesimulator / TestApp.app.dSYM / Contents / Resources / DWARF / TestApp]
<完成,bkpt = {number =1,type =breakpoint,disp =keep,enabled =y,addr =0x000028cf,func =main,file =/ Projects / TestApp / main .m,line =13,shlib =/ private / var / root / Library / Application Support / iPhone Simulator / User / Applications / 09734C45-F595-4 CB =0,= =0},time = {wallclock =0.15835,user =0.00321,系统=0.00184,start =1236463550.455187 1236463550.613542}
#处理结果t = 4.996437 Tepoch = 1236463550.627100
#didFinish序列:< PBXGDB_NewBreakpointSequence:0xa516f90> t = 4.996599 Tepoch = 1236463550.627262
#执行顺序:< PBXGDB_AttachControlSequence:0xa4fceb0> t = 4.996690 Tepoch = 1236463550.627352
-> 162-mi-verify-command target-attach
#PBXGDB_MIVerifyCommandCommand t = 4.996824 Tepoch = 1236463550.627486
< - (gdb)
< - 162 ^ done,name =target-attach ,defined =true,implements =true,time = {wallclock =0.00007,user =0.00006,system =0.00001,start =1236463550.627975,end =1236463550.628046}
#processing result t = 4.998137 Tepoch = 1236463550.628799
- > 163-target-attach 288
#PBXGDB_MIAttachCommand t = 4.998293 Tepoch = 1236463550.628955
< - (gdb)
< - 〜附加到程序:`/ private / var / root / Library /应用程序支持/ iPhone模拟器/用户/应用程序/ 09734C45-F595-4CB9-8707-744E92D66245 / TestApp.app / TestApp',过程288.\\\

< - 〜重新启用共享库断点1 \\\

<= = shlibs更新
< - 163 ^ done,thread-id =1,time = {wallclock =0.00362,user =0.00151 system =0.00203,start =1236463550.629436,end =1236463550.633055}
#处理结果t = 5.010455 Tepoch = 1236463550.641117
#命令中的入队序列Q:< PBXGDB_ThreadListSequence:0xa4e0520> t = 5.011284 Tepoch = 1236463550.641946
- > 164-exec-continue
#PBXGDB_MIContinueExecutableCommand t = 5.011420 Tepoch = 1236463550.642082
< - (gdb)
< - 164 ^运行
#处理结果t = 5.070065 Tepoch = 1236463550.700727
#didFinish Sequence:< PBXGDB_AttachControlSequence:0xa4fceb0> t = 5.071843 Tepoch = 1236463550.702505
< - (gdb)


解决方案


我在任何地方找不到GCC 4.0 - 代码
生成选项。我已经
在Target和
可执行信息页面中看起来都很低。唯一的选项
我看到的是选择编译器
版本,并选择GCC 4.0,但是
是一个没有
附加选项的单行段。


如果Active SDK与目标的Base SDK不同步,那么这是3.1.1和3.1.2中的Xcode错误。将目标的基本SDK设置为模拟器,确保您的Active SDK是模拟器,然后重试。



如果你真的想要这个回答,你将不得不发布有关您的项目的更多信息:构建设置的屏幕截图或调试器控制台中的文本。



更新:
还请注意Xcode>首选项>调试:
alt text http://idisk.mac.com/cdespinosa/公开/ GDB%20Log.png



选中该框,在路径字段中输入合理的路径,尝试调试方案,然后在<一个href =http://bugreporter.apple.com =noreferrer> http://bugreporter.apple.com ,附有日志并对您的场景进行描述,或者询问好人在xcode-users@lists.apple.com。 gdb日志包含有关调试器如何与应用程序交互的所有信息。


I've got Xcode 3.1.2 on OS X 10.5.5. I have an iPhone project that builds fine but the debugger will not hit any of the breakpoints I set. I've tried all the standard fixes that I find on the net:

  1. I've turned off 'Load Symbols Lazily' in Xcode preferences
  2. My active config is Debug
  3. Optimization level is 0 in build settings
  4. I've cleaned all targets and rebuilt
  5. I use Build and Debug (as opposed to Build and Run)

I thought I might have inadvertently tweaked settings on my project. So I created a new project and that one has the same problem.

I'm hoping that I am missing something easy here. My debugger was working just a few days back but all of a sudden it has stopped.


UPDATE:

Things are just getting stranger. Here are some answers to the responses

  1. I cannot find 'GCC 4.0 - Code Generation' options anywhere. I've looked hi and low in both Target and Executable Info pages. The only option I see is to select the compiler version, and GCC 4.0 is selected, but that is a one-line section with no additional options.
  2. About where to put breakpoints: My only breakpoint for now is in main(), and it is not being hit
  3. I am starting the debugger with the Run -> Debug (/% Y) command. Still no luck


UPDATE 2:

  1. Changed Base SDK in target settings to Sim 2.2.1. Changed Active SDK to Sim 2.2.1.
  2. Now I can see GCC 4.0 Code Generation options - Debug Symbols are checked
  3. Still does not hit breakpoints

here is the Console log (breakpoint set at first line of main.m):

[Session started at 2009-03-06 21:29:19 -0600.]
Loading program into debugger…
GNU gdb 6.3.50-20050815 (Apple version gdb-962) (Sat Jul 26 08:14:40 UTC 2008)
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386-apple-darwin".warning: Unable to read symbols for "/System/Library/Frameworks/UIKit.framework/UIKit" (file not found).
warning: Unable to read symbols from "UIKit" (not yet mapped into memory).
warning: Unable to read symbols for "/System/Library/Frameworks/CoreGraphics.framework/CoreGraphics" (file not found).
warning: Unable to read symbols from "CoreGraphics" (not yet mapped into memory).
Program loaded.
sharedlibrary apply-load-rules all
Attaching to program: `/private/var/root/Library/Application Support/iPhone Simulator/User/Applications/753D12B3-777C-473B-B098-3E0AF6282545/TestApp.app/TestApp', process 577.
Re-enabling shared library breakpoint 1

Also is here the gdb log:

t=0.000852 Tepoch=1236463545.631514
<- (gdb) 
-> 135-gdb-version
#  PBXGDB_MIGDBVersionCommand t=4.308986 Tepoch=1236463549.939648
-> 136-gdb-set auto-raise-load-levels 1
#  PBXGDB_MISetAutoRaiseSymbols t=4.309420 Tepoch=1236463549.940082
-> 139-gdb-set env __CF_USER_TEXT_ENCODING 0x0:0:0
#  PBXGDB_MISetEnvCommand t=4.309702 Tepoch=1236463549.940364
-> 140-gdb-set env USERBREAK 1
#  PBXGDB_MISetEnvCommand t=4.309935 Tepoch=1236463549.940598
-> 141-gdb-set env DYLD_FRAMEWORK_PATH /Projects/TestApp/build/Debug-iphonesimulator
#  PBXGDB_MISetEnvCommand t=4.310175 Tepoch=1236463549.940837
-> 142-gdb-set env Apple_PubSub_Socket_Render /tmp/launch-GqkpX5/Render
#  PBXGDB_MISetEnvCommand t=4.310568 Tepoch=1236463549.941231
-> 143-gdb-set env SECURITYSESSIONID 715cd0
#  PBXGDB_MISetEnvCommand t=4.310803 Tepoch=1236463549.941465
-> 144-gdb-set env DYLD_LIBRARY_PATH /Projects/TestApp/build/Debug-iphonesimulator
#  PBXGDB_MISetEnvCommand t=4.311040 Tepoch=1236463549.941702
-> 145-gdb-set env SSH_AUTH_SOCK /tmp/launch-hRgLzb/Listeners
#  PBXGDB_MISetEnvCommand t=4.311299 Tepoch=1236463549.941961
-> 146-gdb-set env HOME /var/root
#  PBXGDB_MISetEnvCommand t=4.311587 Tepoch=1236463549.942250
-> 147-gdb-set env SHELL /bin/sh
#  PBXGDB_MISetEnvCommand t=4.311818 Tepoch=1236463549.942480
-> 148-gdb-set env DYLD_NO_FIX_PREBINDING YES
#  PBXGDB_MISetEnvCommand t=4.312048 Tepoch=1236463549.942710
-> 149-gdb-set env COMMAND_MODE unix2003
#  PBXGDB_MISetEnvCommand t=4.312281 Tepoch=1236463549.942943
-> 150-gdb-set env DYLD_NEW_LOCAL_SHARED_REGIONS YES
#  PBXGDB_MISetEnvCommand t=4.312546 Tepoch=1236463549.943209
-> 151-gdb-set env SSH_ASKPASS /Developer/Library/PrivateFrameworks/DevToolsInterface.framework/Resources/Xcode SSHPassKey
#  PBXGDB_MISetEnvCommand t=4.312780 Tepoch=1236463549.943443
-> 152-gdb-set env PATH /Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin
#  PBXGDB_MISetEnvCommand t=4.313612 Tepoch=1236463549.944275
-> 153-gdb-set env DISPLAY /tmp/launch-yrv3vV/:0
#  PBXGDB_MISetEnvCommand t=4.313849 Tepoch=1236463549.944512
-> 154-gdb-set env USER root
#  PBXGDB_MISetEnvCommand t=4.314141 Tepoch=1236463549.944803
-> 155-gdb-set env NSUnbufferedIO YES
#  PBXGDB_MISetEnvCommand t=4.314377 Tepoch=1236463549.945039
#  Enqueue seq in Command Q: <PBXGDB_SetupSharedLibrarySequence: 0x9049db0> t=4.314625 Tepoch=1236463549.945288
#  Executing Sequence: <PBXGDB_SetupSharedLibrarySequence: 0x9049db0> t=4.314718 Tepoch=1236463549.945380
-> 157-gdb-set inferior-auto-start-cfm off
#  PBXGDB_MISetLoadCFMInfoCommand t=4.314895 Tepoch=1236463549.945557
-> 156-gdb-set sharedLibrary load-rules dyld ".*Foundation.*" all dyld ".*libobjc.*" all dyld ".*libauto.*" all dyld ".*/usr/lib/dyld.*" all dyld ".*CFDataFormatters.*" all dyld ".*PBGDBIntrospectionSupport.*" all dyld ".*AppKit.*" all dyld ".*libSystem.*" all dyld ".*CarbonDataFormatters.*" all dyld ".*CoreFoundation.*" extern dyld "/System/Library/Frameworks\\\\|/System/Library/PrivateFrameworks\\\\|/usr/lib" extern dyld ".*" extern exec ".*" extern 
#  PBXGDB_MISetSharedLibraryLoadSymbolsCommand t=4.315975 Tepoch=1236463549.946637
-> 137-file-exec-and-symbols "/private/var/root/Library/Application Support/iPhone Simulator/User/Applications/09734C45-F595-4CB9-8707-744E92D66245/TestApp.app/TestApp"
#  PBXGDB_MILoadExecutableCommand t=4.320612 Tepoch=1236463549.951275
#  Enqueue seq in Command Q: <PBXGDB_FixAndContinueIsSupportedSequence: 0x9bdc260> t=4.321476 Tepoch=1236463549.952138
#  Enqueue seq in Command Q: <PBXGDB_NewBreakpointSequence: 0xa516f90> t=4.321941 Tepoch=1236463549.952603
#  Enqueue seq in Command Q: <PBXGDB_AttachControlSequence: 0xa4fceb0> t=4.322157 Tepoch=1236463549.952820
<- ~"GNU gdb 6.3.50-20050815 (Apple version gdb-962) (Sat Jul 26 08:14:40 UTC 2008)\n"
<- ~"Copyright 2004 Free Software Foundation, Inc.\n"
<- ~"GDB is free software, covered by the GNU General Public License, and you are\nwelcome to change it and/or distribute copies of it under certain conditions.\nType \"show copying\" to see the conditions.\nThere is absolutely no warranty for GDB.  Type \"show warranty\" for details.\n"
<- ~"This GDB was configured as \"i386-apple-darwin\"."
<- 135^done,version="6.3.50-20050815 (Apple version gdb-962)",rc_version="962",target="i386-apple-darwin",build-date="Sat Jul 26 08:14:40 UTC 2008",time={wallclock="0.03311",user="0.00081",system="0.00014",start="1236463549.989179",end="1236463550.022291"}
#  processing result t=4.392345 Tepoch=1236463550.023007
<- (gdb) 
<- 136^done,time={wallclock="0.00005",user="0.00005",system="0.00001",start="1236463550.024272",end="1236463550.024325"}
#  processing result t=4.394163 Tepoch=1236463550.024826
<- (gdb) 
<- 139^done,time={wallclock="0.00007",user="0.00005",system="0.00002",start="1236463550.025511",end="1236463550.025581"}
#  processing result t=4.395347 Tepoch=1236463550.026010
<- (gdb) 
<- 140^done,time={wallclock="0.00003",user="0.00003",system="0.00001",start="1236463550.026564",end="1236463550.026597"}
#  processing result t=4.396328 Tepoch=1236463550.026991
<- (gdb) 
<- 141^done,time={wallclock="0.00003",user="0.00003",system="0.00001",start="1236463550.027857",end="1236463550.027890"}
#  processing result t=4.397653 Tepoch=1236463550.028315
<- (gdb) 
<- 142^done,time={wallclock="0.00003",user="0.00003",system="0.00001",start="1236463550.029080",end="1236463550.029113"}
#  processing result t=4.398865 Tepoch=1236463550.029528
<- (gdb) 
<- 143^done,time={wallclock="0.00003",user="0.00003",system="0.00001",start="1236463550.030126",end="1236463550.030159"}
#  processing result t=4.399923 Tepoch=1236463550.030585
<- (gdb) 
<- 144^done,time={wallclock="0.00003",user="0.00003",system="0.00001",start="1236463550.031449",end="1236463550.031482"}
#  processing result t=4.401855 Tepoch=1236463550.032518
<- (gdb) 
<- 145^done,time={wallclock="0.00003",user="0.00003",system="0.00001",start="1236463550.033257",end="1236463550.033291"}
#  processing result t=4.403022 Tepoch=1236463550.033685
<- (gdb) 
<- 146^done,time={wallclock="0.00006",user="0.00003",system="0.00002",start="1236463550.034226",end="1236463550.034287"}
#  processing result t=4.404018 Tepoch=1236463550.034680
<- (gdb) 
<- 147^done,time={wallclock="0.00003",user="0.00003",system="0.00001",start="1236463550.035215",end="1236463550.035247"}
#  processing result t=4.405007 Tepoch=1236463550.035670
<- (gdb) 
<- 148^done,time={wallclock="0.00003",user="0.00003",system="0.00001",start="1236463550.036306",end="1236463550.036340"}
#  processing result t=4.406068 Tepoch=1236463550.036731
<- (gdb) 
<- 149^done,time={wallclock="0.00003",user="0.00003",system="0.00001",start="1236463550.037344",end="1236463550.037377"}
#  processing result t=4.407107 Tepoch=1236463550.037770
<- (gdb) 
<- 150^done,time={wallclock="0.00003",user="0.00003",system="0.00001",start="1236463550.038448",end="1236463550.038483"}
#  processing result t=4.408214 Tepoch=1236463550.038876
<- (gdb) 
<- 151^done,time={wallclock="0.00003",user="0.00003",system="0.00001",start="1236463550.040541",end="1236463550.040576"}
#  processing result t=4.410438 Tepoch=1236463550.041101
<- (gdb) 
<- 152^done,time={wallclock="0.00003",user="0.00003",system="0.00001",start="1236463550.041901",end="1236463550.041933"}
#  processing result t=4.411665 Tepoch=1236463550.042327
<- (gdb) 
<- 153^done,time={wallclock="0.00003",user="0.00003",system="0.00001",start="1236463550.042984",end="1236463550.043016"}
#  processing result t=4.412784 Tepoch=1236463550.043446
<- (gdb) 
<- 154^done,time={wallclock="0.00003",user="0.00002",system="0.00001",start="1236463550.043956",end="1236463550.043988"}
#  processing result t=4.413717 Tepoch=1236463550.044379
<- (gdb) 
<- 155^done,time={wallclock="0.00003",user="0.00003",system="0.00001",start="1236463550.044974",end="1236463550.045007"}
#  processing result t=4.414737 Tepoch=1236463550.045400
<- (gdb) 
<- 157^done,time={wallclock="0.00003",user="0.00003",system="0.00001",start="1236463550.046108",end="1236463550.046141"}
#  processing result t=4.415931 Tepoch=1236463550.046594
<- (gdb) 
<- 156^done,time={wallclock="0.00005",user="0.00005",system="0.00001",start="1236463550.050271",end="1236463550.050324"}
#  processing result t=4.420235 Tepoch=1236463550.050897
-> 158sharedlibrary apply-load-rules all
#  PBXGDB_MISharedLibraryApplyLoadRulesCommand t=4.420386 Tepoch=1236463550.051049
<- (gdb) 
<- &"warning: Unable to read symbols for \"/System/Library/Frameworks/UIKit.framework/UIKit\" (file not found).\n"
<- &"warning: Unable to read symbols from \"UIKit\" (not yet mapped into memory).\n"
<- &"warning: Unable to read symbols for \"/System/Library/Frameworks/CoreGraphics.framework/CoreGraphics\" (file not found).\n"
<- &"warning: Unable to read symbols from \"CoreGraphics\" (not yet mapped into memory).\n"
<- 137^done,time={wallclock="0.34917",user="0.17115",system="0.11409",start="1236463550.052577",end="1236463550.401747"}
#  processing result t=4.771918 Tepoch=1236463550.402580
<- (gdb) 
<- &"sharedlibrary apply-load-rules all\n"
<- 158^done
#  processing result t=4.820019 Tepoch=1236463550.450681
#  didFinish Sequence: <PBXGDB_SetupSharedLibrarySequence: 0x9049db0> t=4.820135 Tepoch=1236463550.450797
#  Executing Sequence: <PBXGDB_FixAndContinueIsSupportedSequence: 0x9bdc260> t=4.820259 Tepoch=1236463550.450921
-> 159-mi-verify-command file-fix-file-is-grooved
#  PBXGDB_MIVerifyCommandCommand t=4.820398 Tepoch=1236463550.451060
<- (gdb) 
<- 159^done,name="file-fix-file-is-grooved",defined="true",implemented="true",time={wallclock="0.00011",user="0.00007",system="0.00001",start="1236463550.451848",end="1236463550.451955"}
#  processing result t=4.821746 Tepoch=1236463550.452409
-> 160-file-fix-file-is-grooved
#  PBXGDB_MIFixAndContinueSupportedCommand t=4.821894 Tepoch=1236463550.452556
<- (gdb) 
<- 160^done,supported="1",details="Yes grooved!",time={wallclock="0.00006",user="0.00005",system="0.00002",start="1236463550.453356",end="1236463550.453417"}
#  processing result t=4.823203 Tepoch=1236463550.453865
#  didFinish Sequence: <PBXGDB_FixAndContinueIsSupportedSequence: 0x9bdc260> t=4.823344 Tepoch=1236463550.454006
#  Executing Sequence: <PBXGDB_NewBreakpointSequence: 0xa516f90> t=4.823433 Tepoch=1236463550.454095
#  Passed verification of state before break create command t=4.823569 Tepoch=1236463550.454231
-> 161-break-insert -l -1 -f  -s "TestApp" "\"main.m:13\""
#  PBXGDB_MICreateFileBreakpointCommand t=4.823679 Tepoch=1236463550.454342
<- (gdb) 
<- =shlib-state-modified,shlib-info=[num="1",name="TestApp",kind="-",dyld-addr="-",reason="exec",requested-state="Y",state="Y",path="/private/var/root/Library/Application Support/iPhone Simulator/User/Applications/09734C45-F595-4CB9-8707-744E92D66245/TestApp.app/TestApp",description="/private/var/root/Library/Application Support/iPhone Simulator/User/Applications/09734C45-F595-4CB9-8707-744E92D66245/TestApp.app/TestApp",loaded_addr="",slide="0x0",prefix="",dsym-objpath="/Projects/TestApp/build/Debug-iphonesimulator/TestApp.app.dSYM/Contents/Resources/DWARF/TestApp"]
<- 161^done,bkpt={number="1",type="breakpoint",disp="keep",enabled="y",addr="0x000028cf",func="main",file="/Projects/TestApp/main.m",line="13",shlib="/private/var/root/Library/Application Support/iPhone Simulator/User/Applications/09734C45-F595-4CB9-8707-744E92D66245/TestApp.app/TestApp",times="0"},time={wallclock="0.15835",user="0.00321",system="0.00184",start="1236463550.455187",end="1236463550.613542"}
#  processing result t=4.996437 Tepoch=1236463550.627100
#  didFinish Sequence: <PBXGDB_NewBreakpointSequence: 0xa516f90> t=4.996599 Tepoch=1236463550.627262
#  Executing Sequence: <PBXGDB_AttachControlSequence: 0xa4fceb0> t=4.996690 Tepoch=1236463550.627352
-> 162-mi-verify-command target-attach
#  PBXGDB_MIVerifyCommandCommand t=4.996824 Tepoch=1236463550.627486
<- (gdb) 
<- 162^done,name="target-attach",defined="true",implemented="true",time={wallclock="0.00007",user="0.00006",system="0.00001",start="1236463550.627975",end="1236463550.628046"}
#  processing result t=4.998137 Tepoch=1236463550.628799
-> 163-target-attach 288
#  PBXGDB_MIAttachCommand t=4.998293 Tepoch=1236463550.628955
<- (gdb) 
<- ~"Attaching to program: `/private/var/root/Library/Application Support/iPhone Simulator/User/Applications/09734C45-F595-4CB9-8707-744E92D66245/TestApp.app/TestApp', process 288.\n"
<- ~"Re-enabling shared library breakpoint 1\n"
<- =shlibs-updated
<- 163^done,thread-id="1",time={wallclock="0.00362",user="0.00151",system="0.00203",start="1236463550.629436",end="1236463550.633055"}
#  processing result t=5.010455 Tepoch=1236463550.641117
#  Enqueue seq in Command Q: <PBXGDB_ThreadListSequence: 0xa4e0520> t=5.011284 Tepoch=1236463550.641946
-> 164-exec-continue
#  PBXGDB_MIContinueExecutableCommand t=5.011420 Tepoch=1236463550.642082
<- (gdb) 
<- 164^running
#  processing result t=5.070065 Tepoch=1236463550.700727
#  didFinish Sequence: <PBXGDB_AttachControlSequence: 0xa4fceb0> t=5.071843 Tepoch=1236463550.702505
<- (gdb) 

解决方案

I cannot find 'GCC 4.0 - Code Generation' options anywhere. I've looked hi and low in both Target and Executable Info pages. The only option I see is to select the compiler version, and GCC 4.0 is selected, but that is a one-line section with no additional options.

That's an Xcode bug in 3.1.1 and 3.1.2 if the Active SDK is out of synch with the target's Base SDK. Set the Target's Base SDK to Simulator, make sure your Active SDK is Simulator, and try again.

If you really want this answered, you're going to have to post more information about your project: a screen shot of the Build Settings, or text from the Debugger Console.

UPDATED: Also note in Xcode > Preferences > Debugging: alt text http://idisk.mac.com/cdespinosa/Public/GDB%20Log.png

Check the box, enter a reasonable path into the path field, try your debug scenario, then file a bug at http://bugreporter.apple.com with the log attached and a description of your scenario, or ask the good people over at xcode-users@lists.apple.com. The gdb log contains all the information about how the debugger is interacting with your application.

这篇关于iPhone Dev:Xcode调试器不会在断点上停止的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆