不能在调试器中运行程序? [英] Can't run program in debugger?
问题描述
我试图在一台Linux 64位机器上的一个程序中使用gdb,并且运行gdb bomb(这是程序名),而在gdb中,我只是输入了ran。它返回错误 / bin / bash:/ home / imicrothinking / ics11302016004 / lab2 / bomb:没有这样的文件或目录在启动过程中,程序退出时出现了代码127。
我在网络上挖了一下,我迄今听到的建议导致没有具体的解决方案,这是我确信的: p>
- 我以root用户身份登录。
- 我没有进入错误的目录。
- 可执行文件肯定存在。
我欢迎所有建议。 也许gdb无法找到你的shell。所以将env var SHELL设置为你的shell。
eg:export SHELL = / bin / bash
ref: http://www.linuxquestions.org/questions/linux-software-2/gdb-giving-wierd-error-169299/ < a>
I was trying to use gdb on a program earlier on a Linux 64-bit machine, and I ran gdb bomb (that's the program name), and within gdb, I simply typed in ran. It came back with the error /bin/bash: /home/imicrothinking/ics11302016004/lab2/bomb: No such file or directory During startup program exited with code 127.
I've dug around the net for a bit, and suggestions I've heard so far led to no concrete solutions, here's what I'm sure of so far:
- I'm logged on as a root level user.
- I haven't gone to the wrong directory.
- The executable file definitely exists.
I'd welcome all suggestions.
maybe gdb cann't find your shell. so set the env var SHELL to your shell. eg: export SHELL=/bin/bash
ref : http://www.linuxquestions.org/questions/linux-software-2/gdb-giving-wierd-error-169299/
这篇关于不能在调试器中运行程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!