Author Topic: Climits not found  (Read 7283 times)

Offline Kamaitachi

  • Single posting newcomer
  • *
  • Posts: 5
Climits not found
« on: July 26, 2010, 10:44:22 pm »
I tried to compile a file and it said that climits wasn't found. I just installed Code::Blocks. Any ideas?

Edit: Forgot. It's Code::Blocks 10.05, with gcc 4.4.1 running on Windows 7 64.
« Last Edit: July 27, 2010, 12:09:56 am by Kamaitachi »

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Climits not found
« Reply #1 on: July 27, 2010, 12:22:07 am »
Do you have a c++ compiler (g++) installed?

Also read this: http://wiki.codeblocks.org/index.php?title=FAQ#Q:_How_do_I_troubleshoot_an_compiler_problem.3F
And probably you should ask your question in a beginners c/c++ forum.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline Kamaitachi

  • Single posting newcomer
  • *
  • Posts: 5
Re: Climits not found
« Reply #2 on: July 27, 2010, 11:09:55 am »
Well, I downloaded the Code::Blocks bundled with MinGW...

EDIT: I was browsing the MinGW installation folder, and I found that, while every other type of file was alright, climits (and all the others) were called simply "Files"... What should I do?
« Last Edit: July 27, 2010, 05:28:21 pm by Kamaitachi »

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7601
    • My Best Post
Re: Climits not found
« Reply #3 on: July 27, 2010, 10:38:59 pm »
Do you have a c++ compiler (g++) installed?

Also read this: http://wiki.codeblocks.org/index.php?title=FAQ#Q:_How_do_I_troubleshoot_an_compiler_problem.3F
And probably you should ask your question in a beginners c/c++ forum.

Do the above and look at the rebuild log; and, post here the line of code where you do the include.

Tim S.
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline Kamaitachi

  • Single posting newcomer
  • *
  • Posts: 5
Re: Climits not found
« Reply #4 on: August 06, 2010, 10:43:00 pm »
This is all that appears in the build log, with the "Full command line" option, when I try to compile a simple "Hello World" program:

C:\Users\Mkh\Documents\C++\Untitled1.c:8: error: `cout' undeclared (first use in this function)
C:\Users\Mkh\Documents\C++\Untitled1.c:8: error: (Each undeclared identifier is reported only once
C:\Users\Mkh\Documents\C++\Untitled1.c:8: error: for each function it appears in.)
Process terminated with status 1 (0 minutes, 0 seconds)
5 errors, 1 warnings


 

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7601
    • My Best Post
Re: Climits not found
« Reply #5 on: August 07, 2010, 12:18:29 am »
C:\Users\Mkh\Documents\C++\Untitled1.c:8: error: `cout' undeclared (first use in this function)

Please use the extension cpp for C++ files. C::B treats .c files as "C" program files!

Tim S.
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline Kamaitachi

  • Single posting newcomer
  • *
  • Posts: 5
Re: Climits not found
« Reply #6 on: August 07, 2010, 12:38:57 pm »
It won't save them as .cpp files...

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7255
Re: Climits not found
« Reply #7 on: August 07, 2010, 01:15:14 pm »
It won't save them as .cpp files...
You have to give the file-ending on save.

Offline Kamaitachi

  • Single posting newcomer
  • *
  • Posts: 5
Re: Climits not found
« Reply #8 on: August 07, 2010, 01:45:18 pm »
*Headdesk* It worked now *facepalm* I'm a idiot  :oops: :oops: Well, sorry >.< Should've checked that out first... Anyway, thank you very much! ^^