Configure the C ++ Development Environment mingw5.16 in the latest Windows

Source: Internet
Author: User

Mingw 32 configuration in Windows

 

First, go to the mingw Official Website: htttp: // www.mingw.orgnow mingw5.16.exe

 

Download the package and decompress it online. Do not install it in the subdirectory of other files during installation,

Cannot be installed in the Program Files directory. After decompression, you will see that the downloaded file contains

  • Binutils-assembler, linker ,...
  • Mingw-runtime-headers and libraries for the C library
  • W32api-Windows API header files and libraries
  • Gcc-core-C Compiler
  • Gcc-G ++-C ++ Compiler
  • Gcc-objc-Objective C Compiler
  • Gcc-gfortran-Fortran 90 Compiler
  • Gcc-java Compiler
  • Gcc-Ada Compiler
  • Make File
  • But it does not have GDB and the make that comes with mingw cannot be used. In fact, it is in its Bin
  • With mingw32-make.exeand no make.exe, you can run the command in cmd.
  • You still cannot compile the C ++ language.

Therefore, you also need to download GDB and msys from the mingw official website. The msys version is 1.0.

Before installing msys, You need to configure the mingw environment variable, that is, add the mingw bin directory

To the end of path.

 

GDB directly decompress and overwrite it to the mingw directory. After installation, You need to test the environment.

The command line in cmd cannot test make -- version. You can use msys to test,

In fact, msys simulates Linux Command lines in windows.

If G ++ -- v.

GCC -- V

GDB -- V

Make -- V

If no error occurs, the installation is successful. You can write a C program for testing.

GCC and G ++ are the C and C ++ compilers respectively.

For example, GCC-C hello. c

 

 

 

 

 

 

 

 

 

Related Article

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.