How to configure C + + development in Eclipse (20140721 latest Version)

Source: Internet
Author: User

To prepare for the exam, you need to configure the C + + standard operating environment under Windows to find this article, mark.

Let's start by listing the situation you're experiencing:

1 JRE is not installed, no response after the EXE file has been ordered:
Installing jdk!!!

2 Eclipse could not find the JRE:
Copy the JRE folder under the JDK installation directory to the Eclipse root directory.

3 did not change the name according to the original words. is operating normally.

Original Sticker Address:

http://blog.csdn.net/baimafujinji/article/details/38026421

Eclipse is an open-source, Java-based, extensible development platform. For its part, it is just a framework and a set of services for building a development environment through plug-in components. --The language of Baidu Encyclopedia.

In short, Eclipse is a free, open source Java IDE, and it works very well, especially with the introduction of some extensible plugins, which can become very powerful.

But in fact, eclipse can not only be used for Java programming, it supports a variety of languages, C, C + +, Ada, Python, PHP and so on. Under Windows, a lot of people are used to writing C, C + + programs in Visual C + + (or visual Studio), some people will think that in Eclipse write C, C + + programs, the total feeling is not fish, or is like using chopsticks to eat Western food, or use like a knife and fork to eat Chinese food. Nonetheless, there are still a lot of people writing C and C + + programs in Eclipse. This article is dedicated to those who like to try new things. Special note: The installation and configuration of this article is for Windows-based scenarios.

Although there are many articles on the web that introduce the configuration methods for C/s + + development in eclipse, they are older, and the software updates are always faster, and the author describes the specific installation and configuration methods based on the present (July 21, 2014).

1. First make sure that you have Java installed on your computer, if not, or unsure, please download and install it on the official website (This step I will not detail):

http://www.java.com/zh_CN/

2. Download and install Eclipse on the official website, at this point the latest version is Eclipse Luna (4.4) at the following URL:

http://www.eclipse.org/downloads/

Many versions are given in the list, because it is used for C, C + + programming, you need to select Eclipse IDE for C + + developers (and choose 32-bit or 64-bit depending on the system you are using), such as (note the one that chooses the red box), which is already integrated with the CDT.

Download down is a compressed package, without installation, directly decompression can. Of course, the revolution has not been successful and comrades still have to work hard.

3, need to download and install MinGW. MinGW, is minimalist GNU on Windows abbreviation. It is a free-to-use and freely published collection of Windows-specific header files and import libraries using the GNU toolset, allowing you to generate local Windows programs on Gnu/linux and Windows platforms without the need for a third-party C run-time library. --excerpt from Baidu Encyclopedia. In short, there are a lot of libraries that you need to write C code for, and so on.


Official Download website: http://www.mingw.org/, as shown in the Red box, select Download Installer in the upper left corner and download.

After the download is successful, get a Mingw-get-setup.exe file, run and install it properly.

After successful installation, you will get an icon called MinGW Installer on the desktop, because the content in MinGW is more, you still need to select the part you need and then in the online installation, double-click Open MinGW Installer as follows:

Obviously, several of these packages are required, first mark the packages you need to install (that is, those that are shaded), by selecting mark for installation in the right-click menu, then clicking Installation in the main menu bar, and then selecting Apply from the drop-down menu Changes, and then install it (you need to keep the network up and running, as the installer needs to be downloaded from the site in real time).

4, configure environment variables.

First of all, you need to change the name of Mingw32-make.exe in C:\MinGW\bin to Make.exe (if you install the MinGW directly under the C packing directory), as shown in:

Next, configure the environment variables, right-click My Computer, select Properties, and in the dialog box that pops up, select the Advanced tab, and then click the Environment Variables button. As shown in the diagram on the left.

And then in the dialog box to edit the environment variables, the most important is three--that is, the right picture of the red three, note that this is based on your MinGW installation path to edit, for example, my mingw is directly installed in the C packing directory, so there are:

Include--c:\mingw\include

Lib--c:\mingw\lib

Path--c:\mingw\bin

PS: If you have other development tools installed on your computer, such as VC, it is best to put MinGW entries in front of you.

The basic installation and configuration steps are now complete. In principle, you can already use Eclipse to program C and C + +. But some people may be in the process of writing the actual program, mainly when the implementation of the program, will encounter the following two error messages, and can not be developed.

Launch failed. Bianry not found

A program file is not specified in the launch configuration

Many people on the Internet ask how to solve this problem, but basically there is no answer to the question. (Readers can paste the above two error messages into the Baidu Search bar to try). On this issue, I will introduce the response in the next article.

(RPM) configuration method for C/D + + development in Eclipse (20140721 latest Version)

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.