使用dev-c++的问题!!

「已注销」 2003-08-26 09:28:05
我的dev-c++使用是出现的问题如下:
建立控制台程序编译不能通过,任何代码都没有写,只是默认的几行代码

#include <iostream>
#include <stdlib.h>

int main(int argc, char *argv[])
{

system("PAUSE");
return 0;
}






便宜日志如下:

编译器: Default compiler
Building Makefile: "F:\aaaa\Makefile.win"
执行 make...
make.exe -f "F:\aaaa\Makefile.win" all
g++.exe -c main.cpp -o main.o -I"C:/Dev-Cpp/include" -I"C:/Dev-Cpp/include/c++" -I"C:/Dev-Cpp/include" In file included from main.cpp:1:
C:/Dev-Cpp/include/c++/iostream:44:28: bits/c++config.h: No such file or directory
In file included from C:/Dev-Cpp/include/c++/ios:44,
from C:/Dev-Cpp/include/c++/ostream:45,
from C:/Dev-Cpp/include/c++/iostream:45,
from main.cpp:1:
C:/Dev-Cpp/include/c++/iosfwd:44:28: bits/c++config.h: No such file or directory
In file included from C:/Dev-Cpp/include/c++/iosfwd:45, from C:/Dev-Cpp/include/c++/ios:44,
from C:/Dev-Cpp/include/c++/ostream:45, from C:/Dev-Cpp/include/c++/iostream:45,
from main.cpp:1:
C:/Dev-Cpp/include/c++/bits/stringfwd.h:44:28: bits/c++config.h: No such file or directory
In file included from C:/Dev-Cpp/include/c++/iosfwd:46,
from C:/Dev-Cpp/include/c++/ios:44,
from C:/Dev-Cpp/include/c++/ostream:45,
from C:/Dev-Cpp/include/c++/iostream:45,
from main.cpp:1:C:/Dev-Cpp/include/c++/bits/fpos.h:44:24: bits/c++io.h: No such file or directory
In file included from C:/Dev-Cpp/include/c++/bits/fpos.h:45,
from C:/Dev-Cpp/include/c++/iosfwd:46,
from C:/Dev-Cpp/include/c++/ios:44, from C:/Dev-Cpp/include/c++/ostream:45,
from C:/Dev-Cpp/include/c++/iostream:45,
from main.cpp:1:
C:/Dev-Cpp/include/c++/cwchar:49:28: bits/c++config.h: No such file or directory
In file included from C:/Dev-Cpp/include/c++/iosfwd:46,
from C:/Dev-Cpp/include/c++/ios:44,
from C:/Dev-Cpp/include/c++/ostream:45,
from C:/Dev-Cpp/include/c++/iostream:45,
from main.cpp:1:
C:/Dev-Cpp/include/c++/bits/fpos.h:60: 'streamoff' is used as a type, but is not defined as a type.C:/Dev-Cpp/include/c++/bits/fpos.h:74: parse error before `__off'C:/Dev-Cpp/include/c++/bits/fpos.h:75: missing ';' before right braceC:/Dev-Cpp/include/c++/bits/fpos.h:77: semicolon missing after declaration of `
std::fpos<_StateT>'C:/Dev-Cpp/include/c++/bits/fpos.h: In constructor
`std::fpos<_StateT>::fpos()':
C:/Dev-Cpp/include/c++/bits/fpos.h:72: class `std::fpos<_StateT>' does not have
any field named `_M_off'C:/Dev-Cpp/include/c++/bits/fpos.h: At global scope:
C:/Dev-Cpp/include/c++/bits/fpos.h:77: parse error before `(' tokenC:/Dev-Cpp/include/c++/bits/fpos.h:77: ISO C++ forbids defining types within
return typeC:/Dev-Cpp/include/c++/bits/fpos.h:77: syntax error before `(' tokenC:/Dev-Cpp/include/c++/bits/fpos.h:79: syntax error before `&' tokenC:/Dev-Cpp/include/c++/bits/fpos.h:82: syntax error before `&' tokenC:/Dev-Cpp/include/c++/bits/fpos.h:86: syntax error before `operator'C:/Dev-Cpp/include/c++/bits/fpos.h:89: syntax error before `+=' tokenC:/Dev-Cpp/include/c++/bits/fpos.h:94: syntax error before `operator'C:/Dev-Cpp/include/c++/bits/fpos.h:97: syntax error before `-=' tokenC:/Dev-Cpp/include/c++/bits/fpos.h:102: parse error before `&' tokenC:/Dev-Cpp/include/c++/bits/fpos.h:103: non-member function `bool
operator==(...)' cannot have `const' method qualifierC:/Dev-Cpp/include/c++/bits/fpos.h:103: `bool operator==(...)' must have an
argument of class or enumerated typeC:/Dev-Cpp/include/c++/bits/fpos.h:103: `bool operator==(...)' must take
exactly two argumentsC:/Dev-Cpp/include/c++/bits/fpos.h: In function `bool operator==(...)':
C:/Dev-Cpp/include/c++/bits/fpos.h:103: `_M_off' undeclared (first use this
function)C:/Dev-Cpp/include/c++/bits/fpos.h:103: (Each undeclared identifier is reported
only once for each function it appears in.)C:/Dev-Cpp/include/c++/bits/fpos.h:103: `__pos' undeclared (first use this
function)C:/Dev-Cpp/include/c++/bits/fpos.h: At global scope:
C:/Dev-Cpp/include/c++/bits/fpos.h:106: parse error before `&' tokenC:/Dev-Cpp/include/c++/bits/fpos.h:107: non-member function `bool
operator!=(...)' cannot have `const' method qualifierC:/Dev-Cpp/include/c++/bits/fpos.h:107: `bool operator!=(...)' must have an
argument of class or enumerated typeC:/Dev-Cpp/include/c++/bits/fpos.h:107: `bool operator!=(...)' must take
exactly two argumentsC:/Dev-Cpp/include/c++/bits/fpos.h:110: parse error before `)' tokenC:/Dev-Cpp/include/c++/bits/fpos.h:113: `streamoff' was not declared in this
scopeC:/Dev-Cpp/include/c++/bits/fpos.h:113: parse error before `)' tokenC:/Dev-Cpp/include/c++/bits/fpos.h: In function `void _M_position(...)':
C:/Dev-Cpp/include/c++/bits/fpos.h:113: `__off' undeclared (first use this
function)C:/Dev-Cpp/include/c++/bits/fpos.h: At global scope:
C:/Dev-Cpp/include/c++/bits/fpos.h:114: parse error before `}' tokenC:/Dev-Cpp/include/c++/bits/fpos.h:117: syntax error before `;' tokenIn file included from C:/Dev-Cpp/include/c++/ios:46,
from C:/Dev-Cpp/include/c++/ostream:45, from C:/Dev-Cpp/include/c++/iostream:45,
from main.cpp:1:
...全文
266 10 打赏 收藏 转发到动态 举报
写回复
用AI写文章
10 条回复
切换为时间正序
请发表友善的回复…
发表回复
「已注销」 2003-09-06
  • 打赏
  • 举报
回复
下个新版本就没有问题了!!问题已经解决!
vitalgg 2003-08-29
  • 打赏
  • 举报
回复
编译环境的配置有问题.
sudy_sh 2003-08-28
  • 打赏
  • 举报
回复
这个问题我也碰到过
看看tools/compiler options/directories/c++ includes下面,目录对不对,我发现安装dev-c++,的目录路径不能太长,点一下,delete invalid就知道对不对了
这是我的:
C:\Dev-Cpp\Bin
C:\Dev-Cpp\lib\gcc-lib\mingw32\3.2
「已注销」 2003-08-28
  • 打赏
  • 举报
回复
我的是4.9.7.0

是不是版本的问题啊~~~?我现在去下一个最新版本先!!然后再试试
970306 2003-08-27
  • 打赏
  • 举报
回复
请到里面的设置看一下
Beover1984 2003-08-27
  • 打赏
  • 举报
回复
我的也没问题 ,DEV-C++4.9.6
joskey 2003-08-27
  • 打赏
  • 举报
回复
编译日志如下:

Compiler: Default compiler
Executing g++.exe...
g++.exe "C:\Documents and Settings\Administrator\桌面\Untitled1.cpp" -o "C:\Documents and Settings\Administrator\桌面\Untitled1.exe" -I"D:\Dev-Cpp\include\c++" -I"D:\Dev-Cpp\include\c++\mingw32" -I"D:\Dev-Cpp\include\c++\backward" -I"D:\Dev-Cpp\include" -L"D:\Dev-Cpp\lib"
Execution terminated
Compilation successful
joskey 2003-08-27
  • 打赏
  • 举报
回复
我这里编译通过了,
我的devc++版本是4.9.8.1,是目前最新版本。
「已注销」 2003-08-27
  • 打赏
  • 举报
回复
没有人管吗?
「已注销」 2003-08-26
  • 打赏
  • 举报
回复
C:/Dev-Cpp/include/c++/bits/char_traits.h:59: parse error before `;' tokenC:/Dev-Cpp/include/c++/bits/char_traits.h:60: parse error before `;' tokenC:/Dev-Cpp/include/c++/bits/char_traits.h:113: parse error before `;' tokenC:/Dev-Cpp/include/c++/bits/char_traits.h:114: parse error before `;' tokenC:/Dev-Cpp/include/c++/bits/char_traits.h: In static member function `static
int std::char_traits<char>::eof()':
C:/Dev-Cpp/include/c++/bits/char_traits.h:168: `EOF' undeclared (first use this
function)In file included from C:/Dev-Cpp/include/c++/ios:47,
from C:/Dev-Cpp/include/c++/ostream:45, from C:/Dev-Cpp/include/c++/iostream:45,
from main.cpp:1:
C:/Dev-Cpp/include/c++/cstdio:49:28: bits/c++config.h: No such file or directoryIn file included from C:/Dev-Cpp/include/c++/ios:48,
from C:/Dev-Cpp/include/c++/ostream:45, from C:/Dev-Cpp/include/c++/iostream:45,
from main.cpp:1:
C:/Dev-Cpp/include/c++/bits/localefwd.h:45:28: bits/c++config.h: No such file or directory
C:/Dev-Cpp/include/c++/bits/localefwd.h:46:80: bits/c++locale.h: No such file or directory
In file included from C:/Dev-Cpp/include/c++/bits/localefwd.h:48,
from C:/Dev-Cpp/include/c++/ios:48,
from C:/Dev-Cpp/include/c++/ostream:45,
from C:/Dev-Cpp/include/c++/iostream:45,
from main.cpp:1:
C:/Dev-Cpp/include/c++/cctype:48:28: bits/c++config.h: No such file or directory
In file included from C:/Dev-Cpp/include/c++/bits/localefwd.h:49,
from C:/Dev-Cpp/include/c++/ios:48,
from C:/Dev-Cpp/include/c++/ostream:45,
from C:/Dev-Cpp/include/c++/iostream:45,
from main.cpp:1:
C:/Dev-Cpp/include/c++/string:45:28: bits/c++config.h: No such file or directory
In file included from C:/Dev-Cpp/include/c++/memory:54,
from C:/Dev-Cpp/include/c++/string:48,
from C:/Dev-Cpp/include/c++/bits/localefwd.h:49,
from C:/Dev-Cpp/include/c++/ios:48,
from C:/Dev-Cpp/include/c++/ostream:45,
from C:/Dev-Cpp/include/c++/iostream:45,
from main.cpp:1:
C:/Dev-Cpp/include/c++/bits/stl_algobase.h:64:28: bits/c++config.h: No such file or directory
In file included from C:/Dev-Cpp/include/c++/bits/stl_algobase.h:67,
from C:/Dev-Cpp/include/c++/memory:54,
from C:/Dev-Cpp/include/c++/string:48,
from C:/Dev-Cpp/include/c++/bits/localefwd.h:49,
from C:/Dev-Cpp/include/c++/ios:48,
from C:/Dev-Cpp/include/c++/ostream:45,
from C:/Dev-Cpp/include/c++/iostream:45,
from main.cpp:1:
C:/Dev-Cpp/include/c++/cstdlib:49:28: bits/c++config.h: No such file or directory
In file included from C:/Dev-Cpp/include/c++/bits/stl_algobase.h:72, from C:/Dev-Cpp/include/c++/memory:54,
from C:/Dev-Cpp/include/c++/string:48,
from C:/Dev-Cpp/include/c++/bits/localefwd.h:49,
from C:/Dev-Cpp/include/c++/ios:48,
from C:/Dev-Cpp/include/c++/ostream:45,
from C:/Dev-Cpp/include/c++/iostream:45, from main.cpp:1:
C:/Dev-Cpp/include/c++/bits/type_traits.h:54:28: bits/c++config.h: No such file or directory
In file included from C:/Dev-Cpp/include/c++/bits/stl_iterator_base_funcs.h:68,
from C:/Dev-Cpp/include/c++/bits/stl_algobase.h:74,
from C:/Dev-Cpp/include/c++/memory:54,
from C:/Dev-Cpp/include/c++/string:48,
from C:/Dev-Cpp/include/c++/bits/localefwd.h:49,
from C:/Dev-Cpp/include/c++/ios:48,
from C:/Dev-Cpp/include/c++/ostream:45,
from C:/Dev-Cpp/include/c++/iostream:45,
from main.cpp:1:
C:/Dev-Cpp/include/c++/bits/concept_check.h:40:28: bits/c++config.h: No such file or directory
In file included from C:/Dev-Cpp/include/c++/bits/stl_alloc.h:86,
from C:/Dev-Cpp/include/c++/memory:55,
from C:/Dev-Cpp/include/c++/string:48, from C:/Dev-Cpp/include/c++/bits/localefwd.h:49,
from C:/Dev-Cpp/include/c++/ios:48,
from C:/Dev-Cpp/include/c++/ostream:45,
from C:/Dev-Cpp/include/c++/iostream:45,
from main.cpp:1:
C:/Dev-Cpp/include/c++/bits/stl_threads.h:52:23: bits/gthr.h: No such file or directory
In file included from C:/Dev-Cpp/include/c++/bits/stl_alloc.h:86,
from C:/Dev-Cpp/include/c++/memory:55,
from C:/Dev-Cpp/include/c++/string:48,
from C:/Dev-Cpp/include/c++/bits/localefwd.h:49,
from C:/Dev-Cpp/include/c++/ios:48,
from C:/Dev-Cpp/include/c++/ostream:45,
from C:/Dev-Cpp/include/c++/iostream:45,
from main.cpp:1:
C:/Dev-Cpp/include/c++/bits/stl_threads.h: At global scope:
C:/Dev-Cpp/include/c++/bits/stl_threads.h:69: '__gthread_mutex_t' is used as a
type, but is not defined as a type.C:/Dev-Cpp/include/c++/bits/stl_threads.h:79:2: #error __GTHREAD_MUTEX_INIT or __GTHREAD_MUTEX_INIT_FUNCTION should be defined by gthr.h abstraction layer, report problem to libstdc++@gcc.gnu.org.
C:/Dev-Cpp/include/c++/bits/stl_threads.h: In member function `void
std::_Refcount_Base::_M_incr()':
C:/Dev-Cpp/include/c++/bits/stl_threads.h:86: `_M_ref_count_lock' undeclared (first use this function)C:/Dev-Cpp/include/c++/bits/stl_threads.h:86: `__gthread_mutex_lock' undeclared
(first use this function)C:/Dev-Cpp/include/c++/bits/stl_threads.h:88: `__gthread_mutex_unlock'
undeclared (first use this function)C:/Dev-Cpp/include/c++/bits/stl_threads.h: At global scope:
C:/Dev-Cpp/include/c++/bits/stl_threads.h:158: '__gthread_mutex_t' is used as a
type, but is not defined as a type.C:/Dev-Cpp/include/c++/bits/stl_threads.h: In member function `void
std::_STL_mutex_lock::_M_acquire_lock()':
C:/Dev-Cpp/include/c++/bits/stl_threads.h:192: `_M_lock' undeclared (first use
this function)In file included from C:/Dev-Cpp/include/c++/memory:55,
from C:/Dev-Cpp/include/c++/string:48,
from C:/Dev-Cpp/include/c++/bits/localefwd.h:49,
from C:/Dev-Cpp/include/c++/ios:48,
from C:/Dev-Cpp/include/c++/ostream:45,
from C:/Dev-Cpp/include/c++/iostream:45, from main.cpp:1:
C:/Dev-Cpp/include/c++/bits/stl_alloc.h: At global scope:
C:/Dev-Cpp/include/c++/bits/stl_alloc.h:575: syntax error before `;' tokenC:/Dev-Cpp/include/c++/bits/stl_alloc.h:575: confused by earlier errors, bailing outmake.exe: *** [main.o] Error 1执行结束







这到底是怎么回事?怎么解决啊~~??

谢谢!!

64,282

社区成员

发帖
与我相关
我的任务
社区描述
C++ 语言相关问题讨论,技术干货分享,前沿动态等
c++ 技术论坛(原bbs)
社区管理员
  • C++ 语言社区
  • encoderlee
  • paschen
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
  1. 请不要发布与C++技术无关的贴子
  2. 请不要发布与技术无关的招聘、广告的帖子
  3. 请尽可能的描述清楚你的问题,如果涉及到代码请尽可能的格式化一下

试试用AI创作助手写篇文章吧