How to install MinGW compiler ?

Hi there,

I have a question regarding installation MinGW compiler. I've downloaded all compiler's files according to this page:

--- http://www.mingw.org/wiki/Getting_Started

(manual installation), and extracted all of them to C:\MinGW. This is a screenshot of that folder:

--- http://a.imageshack.us/img185/3240/95914978.png

But how can I install MinGW now ? There isn't any setup.exe there...

Do you have any ideas ?

Thx for help :)
You should continue reading that page you linked. It answers your question and tells you exactly what you need to do.

that page wrote:

extract the files from each package, and add C:\MinGW\bin; to your PATH environment variable:



Of course I would recommend you just get an IDE that bundles all of this in one "setup.exe" package so you don't have to deal with all of this crap.

http://www.cplusplus.com/forum/articles/7263/ <---
1. Download MinGW-get --> http://sourceforge.net/projects/mingw/files/Automated%20MinGW%20Installer/mingw-get/mingw-get-0.1-alpha-3/mingw-get-0.1-mingw32-alpha-3-bin.zip/download <-- and extract the zip file to C:\MinGW

2. Open the Control Panel -> Classic View -> System -> Advanced -> Environment Variables.

3. In the System variables box, find Path and double click it.

4. At the end of the line, type
 
;C:\MinGW\bin


5. Open the command prompt and type:
 
mingw-get install g++


Done!
that page wrote:
extract the files from each package


When I try to do that, a message asking me about overwrite A LOT OF folders and files appears...

Of course, those files and folders are different...
programmer47, thanks.

I saw this before, but this is the alpha installer. Is it stable ?
@john891: try what I said, its simpler and it only downloads g++ (the c++ compiler). that screenshot is of the whole compiler collection, i'm assuming you only want the c++ compiler?
john891, you beat me too my post :)
Its stable enough, I've used it without problems.
It's probably better to use the TDM release:
http://tdm-gcc.tdragon.net/

Even better would be to use the previous TDM release that comes bundled with Code::Blocks:
http://www.codeblocks.org/downloads/26

The new 4.5.0 release had some problems when I tried it (some missing header files and no OpenMP support, iirc).
Damn, when I try to link my wxWidgets project in wxDev-C++, I get a lot of the same errors (about 600):

[Warning] auto-importing has been activated without --enable-auto-import specified on the command line.
[Linker Error] undefined reference to `__dyn_tls_init_callback'
[Linker Error] undefined reference to `__gxx_personality_sj0'
[Linker Error] undefined reference to `_Unwind_SjLj_Register'
[Linker Error] undefined reference to `_Unwind_SjLj_Unregister'
[Linker Error] undefined reference to `_Unwind_SjLj_Resume'


What is going on ? :/
Last edited on
You're probably either not linking libstdc++ (which normally happens automatically if you invoke g++) or you're trying to reuse object files that were compiled with a different version of MinGW.
Never mind... I decided to change IDE for wxWidgets and I've choosen Code::Blocks.

But when I try to compile wxWidgets, I can't even run mingw32-make as my MinGW version doesn't have it!

It should be in the bin folder - but it isn't there...
Last edited on
Uninstall your current version of MinGW and install the Code::Blocks bundle. The version of MinGW that comes with it does have mingw32-make.
I wanted to do this, but when a new version of MinGW will be released, I'll have to wait until a new version C::B bundle will be published...
No, you can just install the new MinGW version and instruct Code::Blocks to use that one instead of the bundled one.
You can also use both by creating a new compiler preset.
Topic archived. No new replies allowed.