Gcc.exe:CreateProcess:没有这样的文件或目录 - 错误? [英] Gcc.exe: CreateProcess : No such File or directory - Error?

查看:601
本文介绍了Gcc.exe:CreateProcess:没有这样的文件或目录 - 错误?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在写一个Objective C程序,并将其保存为hello.m。问题是当我试图编译它usig MinGW它是一个错误



gcc hello.m //我用来编译
,它提供以下错误



gcc.exe:CreateProcess:没有这样的文件或目录



有什么办法修复..我可以向前移动..



谢谢

解决方案

使用Sysinternals ProcessMonitor从 here 。你所做的是找到在进程名称列下进行编译的.exe名称,如 gcc.exe 。然后查看结果列,而不是 SUCCESS 的任何内容都可以查看。我想你正在寻找的是一个 NAME NOT FOUND result。另外,我注意到,当我从shell中运行它,像msys,它没有正常显示。因此,请确保从命令提示符运行gcc编译。



我有同样的问题,做了上面刚刚提到的,我发现 gcc.exe 获得 NAME c> c $ c> cc1obj.exe 的结果。所以我做了一个有教养的猜测,进入我的MinGW文件夹在 \libexec\gcc\mingw32\4.5.0 (版本号可能不一样你),并复制了一个 cc1.exe ,然后将其重命名为 cc1obj.exe 。和wala,这解决了问题。


I am writing an Objective C program and i saved it as 'hello.m'. The problem is when i am trying to compile it usig MinGW it is giving an error

gcc hello.m // i used for compiling and it is giving following error

gcc.exe: CreateProcess : No such File or directory

is there any way to fix ..so that i can move forward..

Thank You

解决方案

Use Sysinternals ProcessMonitor from here. What you do is find the .exe name that is doing the compiling under the Process Name column, like gcc.exe. Then look in the Result column and anything that is not a SUCCESS check it out. I think what you are looking for is a NAME NOT FOUND result though. Also, I noticed that when I ran it from a shell, like msys, it didn't show up properly. So make sure to run the gcc compile from the command prompt.

I had this same problem and did what I just mentioned above, I found that gcc.exe was getting a NAME NOT FOUND result for cc1obj.exe. So I made an educated guess and went into my MinGW folder under \libexec\gcc\mingw32\4.5.0 (the version number might not be the same for you) and made a copy of cc1.exe then renamed it as cc1obj.exe. And wala, that fixed the problem.

这篇关于Gcc.exe:CreateProcess:没有这样的文件或目录 - 错误?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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