Install under Windows, configure the GCC compiler

Source: Internet
Author: User

go from: Install under Windows, configure the GCC compiler1. First introduce the next MinGW

MinGW is a compilation environment that uses only free software to generate pure Win32 executables, which are minimalist GNU on Windows merchants.

In fact, MinGW is not a simple C + + compiler, but a set of GNU tools. In addition to GCC, MinGW also contains some other GNU program development tools (such as gawk bison, etc.).
The MinGW was developed to provide a GNU-compliant GNU working environment for those who do not like to work on the Linux (FreeBSD) operating system and remain in Windows.
So, using MinGW, we can use the GNU Program development tool just like under Linux.
GCC is the core of MinGW, and GCC is a set of compiler systems that support a wide range of computer programming languages, and are closest to the standard in the implementation of language standards. And GCC can be ported to almost all available computer platforms today. (My computer is also equipped with Devkitpro, which contains GCC's ARM (for GBA/DS/GP32) and MIPS (for PSP) versions. )
GCC itself does not have an IDE interface like VC (the IDE that supports the MinGW compiler, such as Dev C + +, is also available on Windows). Source code editing You can choose any text editor you like (it is said that Microsoft developers, including VC development are not using the VC IDE Editor, but the GNU VIM editor). Then use tools such as make to compile, link, package, and even publish software projects. And like the CVS (SVN) Source version Control tool, people in any corner of the world can get involved in a software project.

2. Download MinGW

One way is to download a mingw-2.0.0-3.exe to Sourceforge (http://sourceforge.net/project/showfiles.php?group_id=2435).

but I configured the time I installed Codeblocks on my computer, I have brought my own mingw.

3. Configuration of environment variables

In (System Properties--advanced--environment variables--system variables) (the following directories vary depending on the location of your computer MinGW)

A. Add "C:\Program Files\mingwstudio\mingw\bin" to the value of path. This is the path to find the GCC compiler. If there is anything else in path, you need to split the semicolon in the English state

B. Create a new Library_path variable and add "C:\Program files\mingwstudio\mingw\lib" to its value. This is the path to the standard inventory drop.

c. Create a new C_include_path variable and add "C:\Program files\mingwstudio\mingw\include" to its value. This is the path to the include lookup header file.

4. Verify that GCC is working properly

Under the CMD console window, enter Gcc-v. If it has been successfully installed, the version information of GCC will be displayed.

Author Add content

settings for Make tools

By default, there is no make.exe tool in the "*\mingw\bin" directory, but there is mingw32-make.exe. So, you can copy this file and rename it "Make.exe" to create the Make tool.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.