Massassi Forums Logo

This is the static archive of the Massassi Forums. The forums are closed indefinitely. Thanks for all the memories!

You can also download Super Old Archived Message Boards from when Massassi first started.

"View" counts are as of the day the forums were archived, and will no longer increase.

ForumsDiscussion Forum → Dev C++ help - annoying compliler error, what does it mean :(
Dev C++ help - annoying compliler error, what does it mean :(
2004-07-12, 2:15 PM #1
I just downloaded dev c++ recently and decided to see how it was, and so far it sucks [http://forums.massassi.net/html/tongue.gif]
I can't even get it to compile! I keep getting this error and I have no clue what the heck it's trying to do (other than run a file called "2" in the project directory). It doesn't matter what my code looks like, this error always comes up. I can't even compile a simple Hello World program. Any hints?

[http://www.bellsouthpwp.net/C/o/Correction/devcpp.jpg]

------------------
Do you have stairs in your house?

[This message has been edited by Correction (edited July 12, 2004).]
Do you have stairs in your house?
2004-07-12, 3:14 PM #2
Post your code...

------------------
Dear lady, can you hear the wind blow, and did you know
Your stairway lies on the whispering wind.
:wq
And when the moment is right, I'm gonna fly a kite.
2004-07-12, 3:17 PM #3
I told you, it doesn't matter what the code is. But if it makes you feel any better, I'll give you the hello world code straight out of the help file. But like I said, the error occurs with EVERYTHING, from the examples given, to stuff I write, to stuff I've downloaded such as a tic-tac-toe source listed on the dev c++ website.

Code:
#include <stdin.h>
main()
{
    printf("Hello World\n");
}


------------------
Do you have stairs in your house?
Do you have stairs in your house?
2004-07-12, 3:22 PM #4
stdio, not stdin.

------------------
Dear lady, can you hear the wind blow, and did you know
Your stairway lies on the whispering wind.
:wq
And when the moment is right, I'm gonna fly a kite.
2004-07-12, 3:23 PM #5
It compiled it but it can't find stdin.h to run it.

------------------
Pissed off?
2004-07-12, 3:28 PM #6
I cant compile your code, GCC throws a bunch of errors...Try this code, it compiles for me:

Code:
#include "stdio.h"
main()
{
    printf("Hello World\n");
}


------------------
Dear lady, can you hear the wind blow, and did you know
Your stairway lies on the whispering wind.
:wq
And when the moment is right, I'm gonna fly a kite.
2004-07-12, 3:33 PM #7
no, same thing. I'm telling you it can't be a code error. I've tried compiling at least 10 different programs now that weren't written by me and that I know worked with whoever made them before they were released. Something's up with either the compiler or it's settings or something.

------------------
Do you have stairs in your house?
Do you have stairs in your house?
2004-07-12, 3:38 PM #8
The paths to your header files may be wrong?

*taking a guess*

------------------
When guitars are outlawed, only outlaws will have guitars.
2004-07-12, 3:38 PM #9
What version of Dev c++?
I had 4 and when I was using it I never had any trouble.

------------------
Pissed off?
2004-07-12, 3:41 PM #10
every version. I tried 4 at first, then reinstalled it, and now I'm trying 5. I mean, it's obviously something I'm doing wrong, or something I haven't done to set it up right, but it's just not with the code... :x

------------------
Do you have stairs in your house?
Do you have stairs in your house?
2004-07-12, 3:42 PM #11
Yeah. Check the paths to the header files. I had a similar problem with Foxserv once.

------------------
Pissed off?
2004-07-12, 3:53 PM #12
In the case of those really common headers, like stdio, usually you don't need .h. Anyhow, you might want to put your code in a directory right off of the root like c:\source. Prevents problems that might involve spaces. Try it out.
2004-07-12, 4:02 PM #13
Stupid Microsoft, putting spaces in default directory names... [http://forums.massassi.net/html/tongue.gif]

------------------
Dear lady, can you hear the wind blow, and did you know
Your stairway lies on the whispering wind.
:wq
And when the moment is right, I'm gonna fly a kite.
2004-07-12, 4:38 PM #14
Quote:
<font face="Verdana, Arial" size="2">Originally posted by Hebedee:
In the case of those really common headers, like stdio, usually you don't need .h. Anyhow, you might want to put your code in a directory right off of the root like c:\source. Prevents problems that might involve spaces. Try it out.</font>


I thought that was with C++ headers..
Code:
#include <iostream>
#include <algorithm>
#include <list>

using namespace std;


------------------
Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.
Code to the left of him, code to the right of him, code in front of him compil'd and thundered. Programm'd at with shot and $SHELL. Boldly he typed and well. Into the jaws of C. Into the mouth of PERL. Debug'd the 0x258.
2004-07-12, 11:33 PM #15
I always use the h's in the includes, even for sdio, conio, math etc..

And I had grief with dev, so i used simple old miracle C - did the job quite nicely!

------------------
If at first you don't succeed, lower your standards.
2004-07-13, 12:29 AM #16
http://www14.brinkster.com/aditsu/dev-cpp-faq.html#runfile

Quote:
<font face="Verdana, Arial" size="2">2 (some path)\2 unable to run program file
This happens when the IDE can't find one of the programs needed for compiling your file/project (usually it is make, gcc or g++). There are 2 solutions for this:
1. The "blind reinstall" solution: uninstall Dev-C++ cleanly, then reinstall the full latest version (see top of this page) in a folder with no spaces in the path. It should work afterwards.
2. The "smart fix" solution: read the compile log to see which program it tried to run; go to Tools - Compiler Options - Programs and see what file it is looking for and in which folder (click the "..." button) and check if it is found in that folder. If the specified file is not there, then select it from the Dev-cpp\bin folder (or wherever you installed your compiler).
Note: if you downloaded the IDE-only version (~2.4 MB) and you didn't install a gcc compiler (e.g. the mingw package), then you won't find the necessary programs; refer to solution 1.
It might also help to set Tools - Compiler Options - Directories - Binaries correctly.
If it still doesn't work, then try the first solution.</font>


Hope this helps [http://forums.massassi.net/html/smile.gif]

↑ Up to the top!