I've never used such a software as this. I programmed in Java previously and it was just a text editor and it was able to run the JS2E compiler inside itself.
Now I'm taking another programming class and the professor would like use to compile C++ with GNU G++. I checked the GNU website and it looks like it installs with Cygwin. Is there a way to install just G++ so it would work with Dev-C++? Maybe there is an alternative to G++? I *have* to make the programs work/compile under G++, however.
Thank you.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The Dev-C++ 4.9.8.0 "full package" download includes the GCC 3.2 (with g++) MinGW port to Windows, so that should qualify, if I understand your question correctly. The current IDE (Integrated Development Environment, i.e., Dev-C++ itself), is version 4.9.8.5, to which you can can easily update. (You can also use Cygwin with Dev-C++.)
(P.S. -- Best bet is to install Dev-C++ to the installation default directory and then create a "matching" directory such as C:\Dev-Proj to begin work.)
-- Jim.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Okay, I see. Is there any difference between MinGW and Cygwin, since you said they both use G++?
So you recommended I create matching directories. If I do one of my assignments in Dev-Proj, what would I do with my next assignment? Could I just do Dev-hw01, Dev-hw02, etc?
Thanks.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Okay, I see. Is there any difference between MinGW and Cygwin, since you said they both use G++?
So you recommended I create matching directories. If I do one of my assignments in Dev-Proj, what would I do with my next assignment? Could I just do Dev-hw01, Dev-hw02, etc?
Thanks.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
"So you recommended I create matching directories. If I do one of my assignments in Dev-Proj, what would I do with my next assignment? Could I just do Dev-hw01, Dev-hw02, etc?"
Pretty much. The main thing is to avoid spaces in the path of either the Dev-C++ binaries or your source files.
As such, \Dev-Proj\Proj1; \Dev-Proj\Proj2, etc, would work fine.
t0mmyp
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
You could read more at the MinGW and Cygwin sites (try a Google search). One notable difference is that MinGW is designed with a dll that is generally considered to be a standard Windows system file, and Cygwin uses a special dll of its own (which would have to be distributed with your programs). Also, MinGW seems to work a bit better with Dev-C++ in some minor respects (e.g., compiler log output, for one.) Anyway, I keep a Cygwin setup (as a Dev-C++ external compiler set)handy here, since I occasionally run into code that is designed to be used with Cygwin. (There *are* differences in the GCC implementation, generally minor.)
On the directory tips, I was mainly trying to steer you clear of setting up your program and projects in directories with spaces in the path. What I do is put my projects in subdirectories of Dev-Proj. I named my "main" project directory Dev-Proj so it shows up conveniently in a Win Explorer or dir listing. Example: C:\Dev-Proj\WinTest1. Just a suggestion....
Again, some advice: Don't worry about the MinGW/Cygwin question at first unless you *know* you need one or the other. If you get the Dev-C++ package, install it in the default directory, update the GUI and get organized to start coding, you'll be working with the GCC (Gnu Compiler Collection). If you are writing C++ code, you'll be compiling with g++ . Hope that helps get you started, and good luck!
-- Jim.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
"Okay, I see. Is there any difference between MinGW and Cygwin, since you said they both use G++?"
A couple of important points. Both MinGW and Cygwin can be thought of as some degree of Unix emulation. In the case of MingW, it is a minimal environment neccessary to support running the GCC compilers. (which include more than C and C++, it includes Fortran, Objective C, Java, and even Ada)
Cygwin is a ***MUCH*** bigger emulation of Unix on windows. A full installation of Cygwin includes hundreds of Unix related tools, and is approaching 1 Gig in size (with everything installed).
I use both, Cygwin a ton at work, where we work on both PC and SGI environments.
Wayne
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Not to quibble, Wayne, but the differences in the compiler itself (headers, libraries, and the main compiler executables and core tools -- basically, what you ordinarily need to compile an exe/dll from source), are relatively minor. Unlike Cygwin, MinGW isn't meant to be a full Unix-like "emulation enviroment" package.
Good point, though. I was looking at it from the standpoint of what you see/use from the Dev-C++ IDE, considering either MinGW's or Cygwin's GCC implementation as a "compiler set".
(Phew -- between the two of us, do you think we've throughly confused Eli?)
-- Jim.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I was addressing more of the fundamental differences between MinGW and Cygwin, rather than any difference between the compilers.
It is interesting to note that if one combines MSYS with MinGW, you start to get an environment that is becoming a more useful Unix environment.
Also, just to hopelessly confuste things a bit further, there is another tool that is a DOS cousin of Cygwin that also has GCC included. It is called djgpp.
Wayne
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
There are also times when one benefits from doing a purge, so check the directions for the uninstall/delete/reinstall dance in the "Read This Before Asking A Question" thread.
Pay close attention to the details of it, lingering traces of past installation can mess you up.
Wayne
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Okay the upgrading seemed to do the trick. It now compiles. :)
Yes, these little comments comparing them overwhelm me quite a bit. I've only programming in Java before and all this C++ is confusing.
A quick question about the program itself, though. When you open a file, and you have the code on the screen, is there supposed to be a column of numbers on the left? Mine is just showing up as a big black bar. If I click on it, there will be red check marks. :/
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Look at Tools > Editor Options > Display. There you can set Gutter (and Line Numbers) options. (Tip: There's a bug involving the selection to "Use Custom Font", known to be a problem for Win 9x/Me....)
Glad to hear you're up and running!
-- Jim.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Woohoo - great! Gutter seems to turn gray, now. And the parameters field is perfect, too. Thanks Jim and Wayne.
The only concern I have left is if differences between Cygwin and MinGW will mess me up with I start doing more difficult or larger homework assignments...
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
"The only concern I have left is if differences between Cygwin and MinGW will mess me up with I start doing more difficult or larger homework assignments..."
Personally, I have not run into anything with respect to the compilers that I can think of to warn you about...I have a nearly full installation of Cygwin on the 6 or 7 computers that I use at one time or another...there are some more Unix type things that are in Cygwin and not in MinGW...maybe you might have some funnies with threads and sockets type stuff....but thats pretty specialized...
Wayne
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I've never used such a software as this. I programmed in Java previously and it was just a text editor and it was able to run the JS2E compiler inside itself.
Now I'm taking another programming class and the professor would like use to compile C++ with GNU G++. I checked the GNU website and it looks like it installs with Cygwin. Is there a way to install just G++ so it would work with Dev-C++? Maybe there is an alternative to G++? I *have* to make the programs work/compile under G++, however.
Thank you.
Eli --
The Dev-C++ 4.9.8.0 "full package" download includes the GCC 3.2 (with g++) MinGW port to Windows, so that should qualify, if I understand your question correctly. The current IDE (Integrated Development Environment, i.e., Dev-C++ itself), is version 4.9.8.5, to which you can can easily update. (You can also use Cygwin with Dev-C++.)
(P.S. -- Best bet is to install Dev-C++ to the installation default directory and then create a "matching" directory such as C:\Dev-Proj to begin work.)
-- Jim.
Okay, I see. Is there any difference between MinGW and Cygwin, since you said they both use G++?
So you recommended I create matching directories. If I do one of my assignments in Dev-Proj, what would I do with my next assignment? Could I just do Dev-hw01, Dev-hw02, etc?
Thanks.
Okay, I see. Is there any difference between MinGW and Cygwin, since you said they both use G++?
So you recommended I create matching directories. If I do one of my assignments in Dev-Proj, what would I do with my next assignment? Could I just do Dev-hw01, Dev-hw02, etc?
Thanks.
"So you recommended I create matching directories. If I do one of my assignments in Dev-Proj, what would I do with my next assignment? Could I just do Dev-hw01, Dev-hw02, etc?"
Pretty much. The main thing is to avoid spaces in the path of either the Dev-C++ binaries or your source files.
As such, \Dev-Proj\Proj1; \Dev-Proj\Proj2, etc, would work fine.
t0mmyp
Eli --
You could read more at the MinGW and Cygwin sites (try a Google search). One notable difference is that MinGW is designed with a dll that is generally considered to be a standard Windows system file, and Cygwin uses a special dll of its own (which would have to be distributed with your programs). Also, MinGW seems to work a bit better with Dev-C++ in some minor respects (e.g., compiler log output, for one.) Anyway, I keep a Cygwin setup (as a Dev-C++ external compiler set)handy here, since I occasionally run into code that is designed to be used with Cygwin. (There *are* differences in the GCC implementation, generally minor.)
On the directory tips, I was mainly trying to steer you clear of setting up your program and projects in directories with spaces in the path. What I do is put my projects in subdirectories of Dev-Proj. I named my "main" project directory Dev-Proj so it shows up conveniently in a Win Explorer or dir listing. Example: C:\Dev-Proj\WinTest1. Just a suggestion....
Again, some advice: Don't worry about the MinGW/Cygwin question at first unless you *know* you need one or the other. If you get the Dev-C++ package, install it in the default directory, update the GUI and get organized to start coding, you'll be working with the GCC (Gnu Compiler Collection). If you are writing C++ code, you'll be compiling with g++ . Hope that helps get you started, and good luck!
-- Jim.
PS -- t0mmyp's post wasn't up yet when I replied. Also, where I said "update the GUI", I meant update the IDE (the Dev-C++ program itself)....
-- Jim.
"Okay, I see. Is there any difference between MinGW and Cygwin, since you said they both use G++?"
A couple of important points. Both MinGW and Cygwin can be thought of as some degree of Unix emulation. In the case of MingW, it is a minimal environment neccessary to support running the GCC compilers. (which include more than C and C++, it includes Fortran, Objective C, Java, and even Ada)
Cygwin is a ***MUCH*** bigger emulation of Unix on windows. A full installation of Cygwin includes hundreds of Unix related tools, and is approaching 1 Gig in size (with everything installed).
I use both, Cygwin a ton at work, where we work on both PC and SGI environments.
Wayne
Hmm, okay all that stuff is installed. My course (at school) is doing command line programs.
But before I talk about that, I tried to update and the update window says:
>> "Your devcpp.cfg file is missing the $BIN field in its [VUPDATE] section..."
So I can't update...
So anyway, a basic program code was provided (A Hello-World type) and I tried to compile it to see what happens, and the compiler log says this:
"Compiler: Default compiler
Building Makefile: "C:\Dev-Proj\01-Hello\Makefile.win"
Executing make...
make.exe -f "C:\Dev-Proj\01-Hello\Makefile.win" all
Execution terminated"
The compiler window says: Line 2, file 2, unable to run program file.
I'm supposed to be running programs with ./ProgramName or something.
If this doesn't work, I might be stuck with Cygwin and ugly blocky text...
Thanks.
Not to quibble, Wayne, but the differences in the compiler itself (headers, libraries, and the main compiler executables and core tools -- basically, what you ordinarily need to compile an exe/dll from source), are relatively minor. Unlike Cygwin, MinGW isn't meant to be a full Unix-like "emulation enviroment" package.
Good point, though. I was looking at it from the standpoint of what you see/use from the Dev-C++ IDE, considering either MinGW's or Cygwin's GCC implementation as a "compiler set".
(Phew -- between the two of us, do you think we've throughly confused Eli?)
-- Jim.
I was addressing more of the fundamental differences between MinGW and Cygwin, rather than any difference between the compilers.
It is interesting to note that if one combines MSYS with MinGW, you start to get an environment that is becoming a more useful Unix environment.
Also, just to hopelessly confuste things a bit further, there is another tool that is a DOS cousin of Cygwin that also has GCC included. It is called djgpp.
Wayne
Eli --
Look here for the Dev-C++ 4.9.8.5 download:
http://www.bloodshed.net/dev/devcpp.html
(I forgot -- or neglected to mention -- that the 4.9.8.0 "automatic update" feature has been replaced.)
See how things go from there. If you have problems, check the "Read This Before Asking..." thread for more information....
-- Jim.
There are also times when one benefits from doing a purge, so check the directions for the uninstall/delete/reinstall dance in the "Read This Before Asking A Question" thread.
Pay close attention to the details of it, lingering traces of past installation can mess you up.
Wayne
Okay the upgrading seemed to do the trick. It now compiles. :)
Yes, these little comments comparing them overwhelm me quite a bit. I've only programming in Java before and all this C++ is confusing.
A quick question about the program itself, though. When you open a file, and you have the code on the screen, is there supposed to be a column of numbers on the left? Mine is just showing up as a big black bar. If I click on it, there will be red check marks. :/
Forgot to add this: how would I run something with arguments? The run command in Dev-C++ just runs the program. Like "./programfile argument argument"
Eli --
Look at Tools > Editor Options > Display. There you can set Gutter (and Line Numbers) options. (Tip: There's a bug involving the selection to "Use Custom Font", known to be a problem for Win 9x/Me....)
Glad to hear you're up and running!
-- Jim.
With respect to your parameters question:
Go to the Execute menu, and under that menu is an item called "Parameters", you can enter your command line arguments there.
Note that they do go away if you close Dev...
Wayne
Woohoo - great! Gutter seems to turn gray, now. And the parameters field is perfect, too. Thanks Jim and Wayne.
The only concern I have left is if differences between Cygwin and MinGW will mess me up with I start doing more difficult or larger homework assignments...
"The only concern I have left is if differences between Cygwin and MinGW will mess me up with I start doing more difficult or larger homework assignments..."
Personally, I have not run into anything with respect to the compilers that I can think of to warn you about...I have a nearly full installation of Cygwin on the 6 or 7 computers that I use at one time or another...there are some more Unix type things that are in Cygwin and not in MinGW...maybe you might have some funnies with threads and sockets type stuff....but thats pretty specialized...
Wayne
A good place to lurk and learn is the Cygwin mailing list:
http://cygwin.com/ml/cygwin/
Wayne