gpt4 book ai didi

c - 源文件未编译 Dev C++

转载 作者:太空狗 更新时间:2023-10-29 16:28:38 34 4
gpt4 key购买 nike

我刚刚安装了 Dev C++,正在学习 C 编程。我使用的代码是

#include <stdio.h>    
int main()
{
printf("Hello world");
getch();
}

我将其保存为.c 文件。当我编译时它工作正常,但是当我编译并运行时它说源文件未编译。所以我用谷歌搜索了 buncha things 并在 youtube 上看到了这个视频,它向您展示了如何修复它。我还在谷歌上看到其他论坛也提出了同样的建议......但是,在按照要求进行操作之后,现在我什至无法编译我的代码。我得到这个错误

Compiler: Default compiler
Executing C:\Dev-Cpp\bin\gcc.exe...
C:\Dev-Cpp\bin\gcc.exe "C:\Users\ubaid\Documents\C\Untitled1.c" -o "C:\Users\ubaid\Documents\C\Untitled1.exe" -I"C:\Dev-Cpp\include" -L"C:\Dev-Cpp\lib"
gcc.exe: Internal error: Aborted (program collect2)
Please submit a full bug report.
See <URL:http://www.mingw.org/bugs.shtml> for instructions.

Execution terminated

我也使用了这个链接上的要求,但仍然没有运气.. http://learntogeek.com/miscellaneous/solved-source-file-not-compiled-error-in-dev-cpp/

我正在使用 Windows 8

最佳答案

我遇到了这个问题并通过以下方式修复了它:C:\Dev-Cpp\libexec\gcc\mingw32\3.4.2, 然后删除 collect2.exe

关于c - 源文件未编译 Dev C++,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14514682/

34 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com