试图在崇高中奔跑. 错误 已发生: 收集2.exe: 错误: ld 返回 1 退出状态
Trying to run in sublime. error ocured : collect2.exe: error: ld returned 1 exit status
>gcc my.cpp
c:/mingw/bin/../lib/gcc/mingw32/9.2.0/../../../../mingw32/bin/ld.exe: C:UsersVENKAT~1AppDataLocalTempcccMqWsr.o:my.cpp:(.text+0x19): undefined reference to `std::cout'
c:/mingw/bin/../lib/gcc/mingw32/9.2.0/../../../../mingw32/bin/ld.exe: C:UsersVENKAT~1AppDataLocalTempcccMqWsr.o:my.cpp:(.text+0x1e): undefined reference to `std::basic_ostream<char, std::char_traits<char> >& std::operator<< <std::char_traits<char> >(std::basic_ostream<char, std::char_traits<char> >&, char const*)'
c:/mingw/bin/../lib/gcc/mingw32/9.2.0/../../../../mingw32/bin/ld.exe: C:UsersVENKAT~1AppDataLocalTempcccMqWsr.o:my.cpp:(.text+0x35): undefined reference to `std::ios_base::Init::~Init()'
c:/mingw/bin/../lib/gcc/mingw32/9.2.0/../../../../mingw32/bin/ld.exe: C:UsersVENKAT~1AppDataLocalTempcccMqWsr.o:my.cpp:(.text+0x56): undefined reference to `std::ios_base::Init::Init()'
collect2.exe: error: ld returned 1 exit status
只是我,还是您尝试使用C编译器来编译C++程序 尝试改用 G++
相关文章:
- Visual Studio mkl_link_tool.exe链接错误
- VI工作室代码错误无法打开输出文件主.exe
- 试图在崇高中奔跑. 错误 已发生: 收集2.exe: 错误: ld 返回 1 退出状态
- 找不到 -llibmysqld Collect2.exe:错误:ld 返回 1 退出状态
- 编译器收到错误消息(textc.exe已停止)
- gcc 找不到 -lgcc, g++.exe: 错误: 创建进程: 没有这样的文件或目录
- NMAKE:致命错误 U1077:cl.exe 和 nmake.exe 返回代码'0x2'
- 使用 Arduino 对 ATtiny10 进行编程 ( "ld.exe" 错误)
- 每次我要使用外部资源时,我都会得到:collect2。exe:错误 ld 返回 1 退出状态
- .exe应用程序在windows10中创建新模块时抛出错误,但在windows7中工作正常
- Qt .exe文件错误
- 错误 在测试.exe 0x76C9FD62时出现未经处理的异常:Microsoft C++异常:内存位置0x006FF8
- 'Cannot output file filename.exe Permission denied' C++ 代码::块中的错误
- 将代码移动到函数中时,DLL "myApp.exe"中找不到序号错误0xC0000138
- OpenCV.exe - 系统错误
- C++ / CannyEdgeDetection.exe 已停止工作 代码块 /OpenCV 错误:断言失败
- 对"displayForStudent(int, int const*, double const*, int)"的未定义引用 collect2.exe:错误:ld 返回 1 个退出状态
- 错误 MSB6006:"midl.exe"退出,代码为 -1073741515
- VS 2012 调试 处理<文件时出现意外的符号读取器错误.exe>
- 如何解决此错误:.exe文件已停止工作