解决eclipse调试c++程序出现“No source file named” error
2017-05-18 10:54
651 查看
http://blog.initm.com/eclipse-error-debug/
前些天遇到的问题这是,早就应该写了,但是需要做的事情太多,一直拖到要走了,拖不动了,写!和上一篇文章是相关的,因为我换了一个编辑器eclipse,第一次用,所以遇到一些问题,提示出现No source file named 怎么解决呢?
试了几次没有效果之后开始百度。中文的没有找到相关的文章,于是开始找英文的,英文很水,但是能看懂大概意思。下面我来说一下解决方法:
1.首先我们打开Debug Configurations
![](http://blog.initm.com/wp-content/uploads/2016/08/image_thumb-37.png)
2.在弹出的窗口中选择Select other
![](http://blog.initm.com/wp-content/uploads/2016/08/image_thumb-38.png)
3.然后在弹出的对话框中勾选Use configuration specific settings 然后选择Standard Create Process Launcher 确定
![](http://blog.initm.com/wp-content/uploads/2016/08/image_thumb-39.png)
4.然后打开Debugger选项卡,如下设置一下
![](http://blog.initm.com/wp-content/uploads/2016/08/image_thumb-40.png)
5.然后勾选这个Use full file path to set breakpoints
![](http://blog.initm.com/wp-content/uploads/2016/08/image_thumb-41.png)
OK 搞定
参考资料:
http://stackoverflow.com/questions/12965726/no-source-file-named-error-debugging-eclipse-cdt
http://wp.brodzinski.net/eclipse/source-file-named-main-c-gdb-error/
Recently I came across a quite difficult problem during setting up a debug configuration for my STM32 ARM development environment in Eclipse.
When I was running a I always got „file not found” error in GDB console.
GDB error:
![](http://wp.brodzinski.net/wp-content/uploads/2014/09/1.png)
Solution:
Go to your Debug Configuration -> Configure Workspace Settings
![](http://wp.brodzinski.net/wp-content/uploads/2014/09/2.png)
Expand Run/Debug -> Launching -> Default Launchers
Select GDB Hardware debugging -> Debug (or Release depending on your Configurations)
Select option Legacy GDB Hardware Debugging Launcher
Then click Apply and OK
![](http://wp.brodzinski.net/wp-content/uploads/2014/09/3.png)
Then click Apply and OK
Now debug should work without any problems.
Related links:
http://stackoverflow.com/questions/19864204/eclipse-mingw-cdt-gdb-and-problems-with-debugging
前些天遇到的问题这是,早就应该写了,但是需要做的事情太多,一直拖到要走了,拖不动了,写!和上一篇文章是相关的,因为我换了一个编辑器eclipse,第一次用,所以遇到一些问题,提示出现No source file named 怎么解决呢?
试了几次没有效果之后开始百度。中文的没有找到相关的文章,于是开始找英文的,英文很水,但是能看懂大概意思。下面我来说一下解决方法:
1.首先我们打开Debug Configurations
![](http://blog.initm.com/wp-content/uploads/2016/08/image_thumb-37.png)
2.在弹出的窗口中选择Select other
![](http://blog.initm.com/wp-content/uploads/2016/08/image_thumb-38.png)
3.然后在弹出的对话框中勾选Use configuration specific settings 然后选择Standard Create Process Launcher 确定
![](http://blog.initm.com/wp-content/uploads/2016/08/image_thumb-39.png)
4.然后打开Debugger选项卡,如下设置一下
![](http://blog.initm.com/wp-content/uploads/2016/08/image_thumb-40.png)
5.然后勾选这个Use full file path to set breakpoints
![](http://blog.initm.com/wp-content/uploads/2016/08/image_thumb-41.png)
OK 搞定
参考资料:
http://stackoverflow.com/questions/12965726/no-source-file-named-error-debugging-eclipse-cdt
http://wp.brodzinski.net/eclipse/source-file-named-main-c-gdb-error/
„NO SOURCE FILE NAMED” – GDB ERROR IN ECLIPSE LUNA
Recently I came across a quite difficult problem during setting up a debug configuration for my STM32 ARM development environment in Eclipse.When I was running a I always got „file not found” error in GDB console.
GDB error:
![](http://wp.brodzinski.net/wp-content/uploads/2014/09/1.png)
Solution:
Go to your Debug Configuration -> Configure Workspace Settings
![](http://wp.brodzinski.net/wp-content/uploads/2014/09/2.png)
Expand Run/Debug -> Launching -> Default Launchers
Select GDB Hardware debugging -> Debug (or Release depending on your Configurations)
Select option Legacy GDB Hardware Debugging Launcher
Then click Apply and OK
![](http://wp.brodzinski.net/wp-content/uploads/2014/09/3.png)
Then click Apply and OK
Now debug should work without any problems.
Related links:
http://stackoverflow.com/questions/19864204/eclipse-mingw-cdt-gdb-and-problems-with-debugging
相关文章推荐
- Eclipse - CDT使用GDB调试C++的问题-无源文件命名(No source file named)
- Eclipse - CDT使用GDB调试C++的问题-无源文件命名(No source file named)
- Eclipse - CDT使用GDB调试C++的问题-无源文件命名(No source file named)
- 解决eclipse查看源代码出现The jar file rt.jar has no source attachment问题的方法
- 【转】eclipse 查看原始类出现The jar file rt.jar has no source attachment解决方法
- eclipse 查看原始类出现The jar file rt.jar has no source attachment解决方法
- eclipse 查看原始类出现The jar file rt.jar has no source attachment解决方法
- 3、eclipse 查看原始类出现The jar file rt.jar has no source attachment解决方法
- Eclipse 查看源码出现 The jar file rt.jar has no source attachment 解决方法
- eclipse 查看原始类出现The jar file rt.jar has no source attachment解决方法
- eclipse 查看原始类出现The jar file rt.jar has no source attachment解决方法
- hadoop+eclipse 调试程序出现的问题warn: no job jar file set 以及 点击run on hadoop 无反应
- eclipse 查看原始类出现The jar file rt.jar has no source attachment解决方法
- eclipse 查看原始类出现The jar file rt.jar has no source attachment解决方法
- .NET下编译C++代码时出现fatal error C1083: 无法打开包含文件:“iostream.h”: No such file or directory错误的解决方法.
- 安卓Eclipse出现an error has occurred. see the log file的解决
- 使用 eclipse时,出现如下问题:org.eclipse.swt.SWTError: No more handles的解决办法
- STM32用IAR调试出现Error[Pe020]: identifier "FILE" is undefined 解决方法
- Eclipse导入Android工程出现Project has no default.properties file! Edit the project properties to set one.的解决方法
- eclipse、android开发 logcat出现 Unable to open log device ‘/dev/log/main’: No such file or directory 解决办法