Setting Up Code Block Compiler
Setting Up Code Block Compiler
http://www.codeblocks.org/downloads/26
Look for the file that includes mingw in the name. (The name as of this
writing was codeblocks-10.05mingw-setup.exe; the 10.05 may be different).
Save the file to your desktop. It is roughly 74 megabytes.
1
Binayak Bhandari, Ph.D (Prepared for SRRT)
When you get the compiler auto-detection window, just hit OK.
Code ::Blocks may ask if you want to associate it as the default viewer for
C/C++ files . Click OK
Click Next two times until you get to the Language Selection Dialog:
2
Binayak Bhandari, Ph.D (Prepared for SRRT)
Youll be asked to choose whether you want to use C or C++. Choose C and click
Next.
Code::Blocks will then prompt you with where youd like to save the console
application:
3
Binayak Bhandari, Ph.D (Prepared for SRRT)
Id recommend you put it in its own folder (specify a separate folder for all C related work),
as the compiler will create several files with each project. Give your project a name,
anything will be fine.
4
Binayak Bhandari, Ph.D (Prepared for SRRT)
You dont need to do anything here. Just accept the defaults by hitting Finish.
5
Binayak Bhandari, Ph.D (Prepared for SRRT)
At this point, you will have your main.cpp file, which you can modify if you like. For
now, it just says Hello World!, so we can run it as is.
You now have a running program! You can simply edit main.cpp and then hit F9 to compile it
and run it again.