Example: stock market

Eclipse for Windows Installation

Eclipse on Windows 1 Eclipse for Windows Installation This is how I was able to set up Eclipse for Windows . The following software is being used: java 8 64-bit Eclipse (Oxygen) 64 bit MinGW 64 bit The MinGW 64 bit compiler seems to have pretty good support for C++11. The traditional MinGW download does not support some of the new C++11 support. The Eclipse product supports multiple platforms and multiple versions of the C++ compiler. We will be using the MinGW-64 compiler at the level. This version defaults to a version of C++ known as C++14. The MinGW compile we are using allows you to turn off extensions to better ensure your code adheres to standard C++. Here are the steps for setting up MinGW-64 and Eclipse CDT (the C/C++ support for Eclipse ).

The Java SE Development Kit (SDK) is preferred for doing Java development, but the other one will work for C++ development. Much of Eclipse is writing in Java, so it needs the Java environment.

Tags:

  Eclipse, Installation, Windows, Java, Eclipse for windows installation

Information

Domain:

Source:

Link to this page:

Please notify us if you found a problem with this document:

Other abuse

Transcription of Eclipse for Windows Installation

1 Eclipse on Windows 1 Eclipse for Windows Installation This is how I was able to set up Eclipse for Windows . The following software is being used: java 8 64-bit Eclipse (Oxygen) 64 bit MinGW 64 bit The MinGW 64 bit compiler seems to have pretty good support for C++11. The traditional MinGW download does not support some of the new C++11 support. The Eclipse product supports multiple platforms and multiple versions of the C++ compiler. We will be using the MinGW-64 compiler at the level. This version defaults to a version of C++ known as C++14. The MinGW compile we are using allows you to turn off extensions to better ensure your code adheres to standard C++. Here are the steps for setting up MinGW-64 and Eclipse CDT (the C/C++ support for Eclipse ).

2 I assume you already have a 64-bit version of java installed and running on your systems. If you do not have the 64-bit version of java installed you will need to do so before you install Eclipse . Checking / Installing java You can make sure you have a 64-bit version of java by going to Programs and Features in Windows and looking to see what versions of java you have installed. You should see something that is java version 8 and it 64-bits. It should, hopefully, contain something similar to one of the following: java SE Development Kit 8 Update xx (64-bit) java 8 Update (64-bit) The java SE Development Kit (SDK) is preferred for doing java development, but the other one will work for C++ development. Much of Eclipse is writing in java , so it needs the java environment.

3 You can install a 64 bit version of java using the following URL: The SDK can be obtained from: You want the Windows X64 version. Eclipse on Windows 2 Setting up MinGW: Go to the link below to download MinGW-64. The file you need is Other versions may work but this is the one I have been using. The rev0 version is dated 2017-05-04. Note that this is build This version defaults to the C++14 level of the language. Other versions may work but this is the one that will be used for grading. You will need to ensure any version you pick will create code that is 100% compatible with this version. Unzip the file and put it into directory C:\MinGW. If you unzip the file to c:\ it will unzip the files into C:\mingw64. You can then rename that to C:\MinGW.

4 Set the PATH environment variable for Windows to include C:\MinGW\bin. This is a critical step and must be done successfully to get GCC and Eclipse to work together. To do this you need to open up the Control Panel and then go to System. From there click Advanced system settings. From the System Properties dialog click Environment Variables. From the System variables scroll to find and select the Path entry. Use the button edit the path to include C:\MinGW\bin. If you have a text field you will need to add ;C:\MinGW\bin to the end of the text field value. If you have a list of entry you will need to add a new entry with the value C:\MinGW\bin. If you need additional help getting the PATH updated you should look at the Microsoft website for directions.

5 Verify your PATH: Open up a Command Prompt in Windows . From the command prompt enter in the following command: g++ --version You should see output similar to the following: g++ (x86_64-win32-sjlj-rev0, Built by MinGW-W64 project) Copyright (C) 2017 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. If you get an error message telling you that g++ is not recognized as an internal or external command you need to make sure you have installed the MinGW compiler in directory C:\MinGW and that C:\MinGW was added to your PATH environment. Not doing either or both of these will cause an error and Eclipse will not work properly.

6 Eclipse on Windows 3 You can close the command prompt by typing in the following command: exit Setting up Eclipse (New Installation ): Go to and download the Windows 64-bit version of the Eclipse IDE for C/C++ Developers. Here is a link. Make sure you select a 64-bit version: You can get Eclipse by using the Windows 64-bit link to the right of the Eclipse IDE for C/C++ Developers entry. The file name is Create directory C:\ Eclipse and unzip Eclipse into that directory. You will now have a directory structure of C:\ Eclipse \ Eclipse . Rename this to C:\ Eclipse \CPP. Adding C/C++ Developers support to an existing Eclipse Installation : If you are already running Eclipse for other uses (such as java development) you can add the packages you need for the C/C++ development to your existing Installation .

7 See the How to Combine Packages document for your version of Eclipse . Here is the link if you are running the Oxygen version of Eclipse : Running Eclipse the first time Running Eclipse for the first time (or for a new workspace): Go to C:\ Eclipse \CPP directory and run the file. You can create a shortcut of this and move it to the start menu or to the desktop. You can also select and bring up a pop-up menu and pin it to the start menu or the taskbar. When you start Eclipse it will prompt you for a workspace location. You need to give it a directory and it will create the workspace in that directory. You can make this the default directory and Eclipse will not prompt you for the directory each time. You can also have different workspaces for different courses.

8 Your workspace can be on a USB drive or a network drive, but it will not perform as well as a local drive. When you open Eclipse the first time (or the first time with a new workspace) you will get a Welcome tab. You can go through that to learn about Eclipse . When you close the Welcome tab you will go into the C/C++ perspective. Eclipse on Windows 4 Go to Window -> Preferences and then go to C/C++ New C/C++ Project Wizard. Make sure the Preferred Toolchains tab is selected. Select Empty Project and then toolchain MinGW GCC. Click the Make toolchain(s) preferred button. Apply the changes. Once again, you only need to do this once per workspace. This makes the MinGW the compiler the one used, by default, whenever you create a new C or C++ project.

9 Eclipse supports a number of different styles that it will use for code formatting. Go to C/C++ - Code Style Formatter. Note that the default formatter is K&R [built-in]. Look though the various profiles and use one of the existing ones that most closely matches your coding styles. You can also create a new one if you want. To show the capability I will select the BSD/Allman [built-in] style and click Apply to make it the new default. Again, you only need to do this once per workspace. You can override this in the project properties if you need to. When you are working on your C++ source files you can format the source and it will change the indentation and spacing for your source to what you have specified as your default formatter.

10 While still in the Preference dialog go to C/C++ - Editor Content Assist Advanced and check the Parsing-based Proposals entry (in both lists). Apply the changes. You can now close the Preferences dialog. This is the last of the workspace options we are changing. The changes below will need to be done for every project. Creating and running Projects Like Visual Studio the Eclipse product wants all programs to reside in a Project. It has a very nice import and export capability that makes it easy to bring code into Eclipse and makes it very easy to save a copy of your source files to another location so it can be uploaded to eLearning or saved to a USB drive or to the H: network drive. When you enter the workspace name give it a directory as well (such as H:\EclipseCPPW orkspace).


Related search queries