Help with MIinGW in netBeans 6.0

Started by
8 comments, last by ajm0528 15 years, 8 months ago
hello everyone! i want to use "MinGW" in netBeans 6.0, but i can't seem to make it work. I have exhausted all the resources on the net telling to set up MinGW in netBeans, but it don't work. Interestingly, my program's build is succesful everytime, but it fails only when i execute the run button. It just displays a command prompt and says "[press a key to continue]". I have been using VS quite a while now just wanted to switch the IDE. Any help will be greatly appreciated.
Advertisement
Perhaps that means that the problem is with your program, and not the compiler setup?
Any reason you don't wanna use Cygwin instead of MinGW? I use it and it runs fine on NetBeans; never had a problem with it.
hi Ocelot,

I am sure the problem is not with my program, as i have been programming for quite a while now.

Quote:Original post by ajm0528
Any reason you don't wanna use Cygwin instead of MinGW? I use it and it runs fine on NetBeans; never had a problem with it.



The reason for not using Cygwin is i wanted a very light compiler,
as the MinGW site says, it is the minimalist system (Msys) i thought better give it a try.

Any way i would like to use Cygwin also, can any one help me with it.

Thanks
One question: what happens if you run the program from outside the IDE?
You say that a prompt is shown with that text, but if you're programming in console mode, this is correct. Are you saying that it does not output the right thing? Does this happen also with a hello world program?

If the code compiles and the linker runs (in fact, you end up with an exe) then I suppose that your compilation chain works.

Anyway, if you want to try with Cygwin you just need to download the installer, then you must choose what you want (I'm not sure that g++, make and gdb are selected by default, so be sure that theyare checked). Then I don't really remember how to setup NetBeans to use those tools, but it should be trivial because I didn't had any issue...
Quote:Original post by cignox1
One question: what happens if you run the program from outside the IDE?
You say that a prompt is shown with that text, but if you're programming in console mode, this is correct. Are you saying that it does not output the right thing? Does this happen also with a hello world program?


yeah! that's the intersting part, if i use Msys from command line the program executes fine and displays the desired output. The problem arises only when i want to use the netBeans. I have all the setup done correctly, all the make files everything.

All my programs works fine in VS 2005. I use netBeans for java & VS for C++, thought that it will be better to work on one IDE...
Quote:Original post by cignox1
Anyway, if you want to try with Cygwin you just need to download the installer, then you must choose what you want (I'm not sure that g++, make and gdb are selected by default, so be sure that theyare checked). Then I don't really remember how to setup NetBeans to use those tools, but it should be trivial because I didn't had any issue...


I dont believe they are. When the downloader is open, click the VIEW button on the top right so you have the full list. Make sure everything is set to SKIP except: gcc-core, gcc-g++, gdb, and make. Those are all you need to be able to compile C/C++ programs within NetBeans. Once the installer is finished, NetBeans automatically recognizes them on the system (atleast mine did).

Good luck.

Thanks a lot. All of u guys.

But for my problem i will post the exact error codes and msg. somtimes down the line. till then hope i can figure out the config of cygwin.

Thnx again!!!
Quote:Original post by metalman666
Thanks a lot. All of u guys.

But for my problem i will post the exact error codes and msg. somtimes down the line. till then hope i can figure out the config of cygwin.

Thnx again!!!


No problem. I forgot to mention, here is an install guide for Cygwin provided by NetBeans's website: Click here! You can also download Cygwin via a link on that page.

This topic is closed to new replies.

Advertisement