C++

Setting Up C++ Development Environment on Windows with EasyEclipse and MinGW

14

Many people complain that configuring Eclipse+CDT/EasyEclipse IDE to work with MinGW C/C++ compiler tools on Windows doesn’t always go on expected lines. I hope the following howto would go some distance in addressing this issue. I use EasyEclipse IDE(what is EasyEclipse?) in this howto but the same procedure applies to Eclipse + CDT combination too.

To set up a C++ development environment using Eclipse+CDT/EasyEclipse and MinGW on a Windows operating system, the following steps need to be completed:

  1. Download and Install MinGW for Windows.
  2. Set MinGW in system PATH.
  3. Download and Install EasyEclipse for C++ and configure it to use MinGW tools.
  • Download and Install MinGW for Windows

    1. First download the Automated MinGW Installer from the sourceforge.net website.

      Download MinGW C/C++ From Sourceforge

    2. From whatever location you run the downloaded MinGW installer, it creates a few settings file there. So I recommend moving it to its own directory before running it. Move the installer file to a location like C:\mingw\ and run it from there.

      You will see a welcome dialog; click Next to continue. Select “Download and Install” option from the next dialog box and click Next.

      Installing MinGW C/C++ on Windows

    3. Read the license and click Next if you agree to it. Select “Current” option from the next dialog box and click Next.

      Installing MinGW C/C++ on Windows

    4. Select at least “g++ compiler” and “MinGW make” from the shown components and click Next.

      Installing MinGW C/C++ on Windows

    5. Accept the default install location or enter a new location(should not contain any spaces in the path name) in “Destination Folder” text box and click Next.

      Installing MinGW C/C++ on Windows

    6. Accept the suggested Start Menu shortcut and click Install to begin the installation procedure. Depending on the number of selected components in Step 4 and the Internet speed, the download may take some time. When the installation is finished, click Close to dismiss the installer. MinGW is now installed on the system.
  • Set MinGW in system PATH

    The second step is to add the MinGW bin directory path to the system/user PATH variable.

    1. Right-click on “My Computer,” go to “Advanced” tab and click the “Environment Variables…” button.

      Setting PATH variable for MinGW C/C++ on Windows

    2. Select the entry of PATH field, click the “Edit” button, hit the END key on the keyboard, add a semicolon and then type/paste the MinGW bin directory path. Click OK to dismiss all the dialog boxes.

      Setting PATH variable for MinGW C/C++ on Windows

    3. To verify that the PATH variable is set correctly, select to Start -> Run command and enter cmd in the text box. In the command window, type:
      C:\> g++ -v

      You should see the version information displayed.

      Checking GCC version of MinGW on Windows

      If you get an error that g++ command is not found, then you have not set the PATH properly. Repeat the above instructions carefully or search through the Internet to learn how to change PATH variable in Windows.

  • Configure EasyEclipse for C++ to use MinGW tools

    The third step is to download EasyEclipse for C++ package for the Windows OS and unpack it to a directory(say, C:\easyeclipse).

    Go to the unpacked directory and click on the startup.jar file to run the EasyEclipse for C++ IDE. (You can right-click on this file and send a shortcut to the desktop or pin it to the start menu or add it to quick launch panel for easier access in the future.)

    1. To create a new C++ project, select File -> New -> Managed Make C++ project(File->New -> New Project to see all the options), enter a name and click Finish.

      Developing C/C++ Applications in EasyEclipse with CDT

    2. Once the project is created, change the default ‘Build Command’ from ‘make -k’ to ‘mingw32-make -k’(to use MinGW’s make tool). This setting can be changed from Project -> Properties -> C/C++ Build -> Build Settings tab:

      Developing C/C++ Applications in EasyEclipse with CDT
      You can also access project settings by right-clicking on the project name and selecting ‘Properties’.

    3. To add a new file to the project, select File -> New -> Source File, enter a name(say, hello.cpp) in the ‘Source File:’ text box and click Finish.

      Type the following program in the editor:
      [cpp]
      #include
      #include

      int main()
      {
      std::string name = “world”;
      std::cout << "Hello, " << name << ".";
      std::cout << std::endl;
      }
      [/cpp]

      As soon as the file is saved, it is built automatically. The errors, if any, are highlighted by underlining them with red lines.

      Developing C/C++ Applications in EasyEclipse with CDT

      If you want to build the project manually, then uncheck the “Build Automatically” option from the Project menu.

      Developing C/C++ Applications in EasyEclipse with CDT

    4. You are all set to add additional source (and header) files to the project now and expand the C++ application. Remember that Step 2 has to be repeated for every new C++ application created.

      Developing C/C++ Applications in EasyEclipse with CDT

Good luck!

EasyEclipse is the Best Packaged Distribution of Eclipse Platform

6

EasyEclipse is a distribution of Eclipse software development platform that simplifies the tasks of downloading, installing and maintenance while providing the same rich development environment of Eclipse. In the words of EasyEclipse creators:

EasyEclipse packages together Eclipse and selected open source plugins and is free and open-source, easy to download and install, and simple to maintain, without version and dependency issues.

EasyEclipse has become the perfect Eclipse distribution for me as I have always hated the fact that the newer versions of plugins played havoc with my old installation of Eclipse or vice versa; upgrading is so much simpler with EasyEclipse. All the work that I used to do of locating various plugins from all sorts of locations on the Internet, downloading and installing them, testing them, and once that is done, trying to always maintain the latest versions of Eclipse as well as all the installed plugins, is now done for me by the EasyEclipse creators. At least for the collection of plugins that EasyEclipse supports.

There are several different packages that can be downloaded from the EasyEclipse website depending on the kind of development environment one wants to set up. This further reduces the getting-started-with-eclipse curve. There are three major distribution categories:

  1. Distributions for web and dynamic languages

    Following packaged distributions are available for different type of web technologies:

    If you want one distribution to develop all kind of web applications, there is a ~180MB EasyEclipse for LAMP distribution that includes PHP, Python, Perl as well as Ruby on Rails environments. If you don’t already have a web server/database installed for testing web applications, XAMPP is the easiest way to do so.

  2. Distributions for Java

    The following varieties of Java distributions are available:

  3. Distribution for C/C++

    For C/C++ development, EasyEclipse neatly packages Eclipse with the CDT plugin as well as several other useful plugins; to access CVS/Subversion repositories, generating Doxygen documentation, etc. My experience of installing CDT in Eclipse always had mixed results whereas EasyEclipse for C++ worked every single time I installed it, on every single platform it supports. Eclipse for C++(just like Eclipse) needs some kind of a C/C++ development environment already installed on the system: Topic of next post.

There is also an EasyEclipse distribution for Eclipse plugin development: EasyEclipse Plugin Warrior

Eclipse for LAMP(PHP, Perl, Python, Ruby on Rails) Web Development

Once one of the above distributions is selected as the appropriate one based on one’s requirements, additional plugins can be installed easily by downloading them from EasyEclipse Plugins web page. All these plugins are well tested with all the EasyEclipse distributions and hence problems arise on very rare occasions. Such problems can be addressed at EasyEclipse Forum or the mailing list. There is an #easyeclipse channel on irc.freenode.net too but you need to hit the right time to find someone to answer your queries there.

If you want completely personalised Eclipse environment and you find all the plugins you need on EasyEclipse Plugins page, then start with EasyEclipse Expert Java and install just the plugins you need. You can also install all the plugins for Web, Java and C++ development this way to create a complete development environment(I start with Server Java or LAMP versions to do the same; saves me some time).

Last Words

EasyEclipse doesn’t (officially) support all the plugins that exist for Eclipse, far from it. But all these plugins do work with EasyEclipse just like they do with Eclipse, they are merely not tested by the EasyEclipse maintainers. In that sense, EasyEclipse gives me a better starting point than Eclipse does. I do hope that the number of Eclipse plugins supported by EasyEclipse increases with passing time.

buy prednisone medication COD purchase prednisone without prescription needed purchase prednisone prescription online prednisone no prior script prednisone no rx needed order prednisone usa cod buy prednisone without rx from us pharmacy buy prednisone online without rx purchase prednisone without prescription order prednisone saturday delivery buy prednisone amex online without prescription ordering prednisone over the counter buy prednisone amex online without rx ordering Paxil over the counter order Paxil without rx needed order Paxil pharmacy Paxil overnight delivery fed ex ordering Paxil without a script order Paxil order amex order Paxil amex online without prescription buy Paxil pay pal without prescription order rx free Paxil cheapest Paxil available online purchase Paxil without purchase Paxil without prescription how to order Paxil online without a prescription purchase Paxil cod next day delivery buy discount Paxil online buy Paxil no visa online without rx prednisone cheap overnight fedex purchase Strattera usa cod where to buy accutane buy frontpage software cheap mortgage application software buy autocad software best price for final draft 7 software iphone software download plagiarism software to buy for parents Crestor side effects buy masterwriter software discount bmi sesac microsoft software downloads wm5 software download treo software download cheap discount software xxasdf discount trellian software best antivirus software download cheap microsoft word software buy software for mac software discounts for educators microsoft office buy windows xp oem software buy flash cs3 software photoshop cs 5 full fashion conference italy buy Orlistat with amex ordering Lasix over the counter purchase online prescription Lasix without windows 7 product key purchase online cheapest xenical available online prescription xenical online online Maxalt achat Maxalt Zithromax uk sales where to buy Valtrex by cod where to purchase generic valtrex online without a prescription quality generic valtrex cheap valtrex usa (no prescriptions needed for Buspar|buy Buspar with no prescription|online pharmacies Buspar|Buspar cheap|buy Buspar without rx|purchase rx Buspar without|Buspar purchase online|purchase Buspar online without rx|purchase Buspar free consultation|buy Buspar Online|buy Buspar american express|buy Buspar Online|buy cheap Buspar with dr. prescription|Buspar side effects|fedex Buspar without priscription|overnight Buspar without a rx|order cheap overnight Buspar|Buspar toronto|uk order Buspar|Buspar no doctors prescription|Buspar mexico|Buspar order|no prescription Buspar with fedex|order generic Buspar|buy Buspar without rx from us pharmacy|prezzo Buspar|Buspar 10mg|Buspar from canada|purchasing Buspar without a script|buy Buspar australia|purchase Buspar visa without prescription|online purchase Buspar|buy Buspar no perscription cod|buy Buspar drugs|buy Buspar with visa|buy Buspar without rx needed|buy Buspar without prescription|buy Buspar no prescription low cost|purchase purchase Buspar no prescription cheap buy cheap Nolvadex cod buy Nolvadex infertility in internet visa at Wisconsin Ontario omicrosoft office 2003 megaupload online purchase Lasix Buy genuine accutane online buy Cytotec online no rx Cytotec online buy nolvadex amex online where to buy synthroid in germany where to buy synthroid pills cheap discount Nolvadex overnight Accutane 20mg mexico order Lasix usa Lasix overnight delivery fed ex buy zithromax overnight purchase online prescription zithromax without buy Nolvadex cheap cheapest Nolvadex available online buy Nolvadex without rx from us pharmacy buy Nolvadex without a prescription overnight delivery buy 20mg Nolvadex free shipping buy Nolvadex no prescription order zithromax overnight delivery buy zithromax 100 mg visa Valtrex without doctor prescription buying zithromax over the counter order zithromax with no prescription order zithromax 250mg mastercard order zithromax 250 mg visa order zithromax 500mg amex buy mail order Orlistat buy Valtrex online now Orlistat tablets purchase cheap Maxalt onlinebuy generic Maxalt pills free fedex delivery Buspar buy cheap Finpecia under without rx purchase online finpecia without rx finpecia fedex no prescription buy line finpecia generic Crestor uk Buspar u.p.s shipping cod order cheap overnight Buspar free fedex delivery prednisone prednisone no script fedex buy valtrex cheap without prescription generic Valtrex fedex Online overnight shipping Valtrex purchase Zithromax without purchase Zithromax no scams Arimidex delivered overnight order cheap overnight Arimidex purchase Cytotec over the counter fedex buy Cytotec online overnight adobe financial results microsoft office professional 2007 upgrade download microsoft office professional 2007 cheap Buspar by money order how to buy Valtrex without a prescription cheap valtrex uk buy Flomax in the uk purchase Proscar usa cod adobe lm service adobe after effects simple creativity latest adobe flash download buy Crestor amex measurement software Photoshop For Sale buy discount Tamsulosin line Autocad 2010 Review download adobe premiere complete removal of office 2003 adobe indesign cs2 photoshop lightroom 3 cheap where can i buy herbal Crestor where to buy Crestor buy Crestor online cod Buy Fincar online 5 mg mastercard cheapest price for microsoft office vio software discount coupon purchase Orlistat amex online without prescription buy maxalt online without a prescription adobe photoshop 6 cd key Cheap Software Buy Downloads For Photoshop flash catalyst sql ms office 2010 enterprise windows 7 upgrade oem Windows Server 2003 Standard Edition Downloads For Windows 7 Ultimate Buy cheap Valtrex without a perscription application free download office microcoft2007 buy Crestor drugs Valtrex no prescription purchase Valtrex amex online without prescription Xenical Orlistat Flomax buy on line boilsoft viseo create new instrument logic studio 9 cheap purchase finpecia buy Strattera no prescription low cost Flomax best buy buy cheap oem software formica countertop cyberlink power dvd 9 download buy Prednisone no prescriptions cheap indesign cs android acdsee buy Flomax australia generic Valtrex online lightroom license .txt download de driver para corel windvd buy microsoft office online cheap generic Valtrex online buy Flomax online no prescription buy pharmacy Flomax waterview ifinance price price of valtrex buy valtrex doctor prescription buy generic Crestor order generic Tamsulosin imtoo dvd ripper serial look like buy Buspar without a rx cheap digital video want to buy Buspar in malaysia buy Crestor now buy Valtrex without a rx purchase rx Valacyclovir without Bupropion buy Bupropion buy no perscription Amitriptyline buy discount Zithromax cheapest Zithromax available online how to order Buspar online without a rx purchase prednisone cod next day delivery where can i purchase prednisone online prednisone online cash on delivery microsoft office 2010 3 user license cheap mac desktops no prescription Orlistat cod delivery Work Order Tracking System Acrobat 6.0 Professional Oem Version Windows 7 buy Valtrex where order Orlistat no rx cheap proffes Microsoft Windows Xp Purchase buy Valtrex legally buy cheap Proscar without prescription Windows Xp Server buy cheap online pharmacy Buspar buy Prednisone online now generic Zithromax usa accutane 40 mg delivered overnight buy accutane 40 mg with no prescription media 8 oline cheap cs software Discount Microsoft WindowsLightroom 2 Windows 7Ms Office StandardPhotoshop Cs5 UpgradeComputer Monitors For SaleWindows Xp InstallSuite Microsoft OfficeAutocad Version 2007Adobe Acrobat 9.0 Standard DownloadIe8 Download For Windows 7Adobe Paint ShopMicrosoft Service Pack 2Free Download Adobe AcrobatStudent And Teacher EditionManage ImageAdobe Acrobat 7 Pro DownloadVista Home Premium To Windows 7 UltimateWindows 7 Home Premium Upgrade OemAdobe Creative Suite 5 Master Collection Student And Teacher EditionBuy Adobe Photoshop Lightroom 3Ms Office 2010 Home And StudentCompare Photo SoftwareMicrosoft Office Word Viewer 2010Windows 7 Upgrade Student Discount ProfessionalWindows 7 Updates DownloadCreative Suite WebAdobe Reader VistaMicrosoft Windows 7 Home Premium Upgrade 64 BitPhotoshop 2Ie8 Download For Windows 7Photoshop 2009Suite Microsoft OfficeMicrosoft Office 2007 VersionUpgrade Windows Vista To 7Autocad Lt 2010Autocad 2010 Best PriceDownload Acrobat Reader 8 buy Flomax online us pharmacy cheapest Buspar available online where can i purchase Buspar without a prescription sony oem software Valtrex from india Maxalt pharmacy Prednisone prescription order Buspar shipped by cash on delivery purchase Proscar online with overnight delivery buy Valtrex with no prescription prezzo Valtrex buy Valtrex shipped cod Proscar no prescription overnight Proscar overnight no consult where to purchase cheap Cytotec no rx Cytotec to buy canadian prescriptions prednisone where to buy Prednisone online Prednisone buy Prednisone Proscar online no rx overnight where can i buy Valtrex online without a prescription buy valtrex legally order Valtrex without a rx overnight shipping c.o.d prednisone purchase Prednisone money purchase is it legal to buy Cytotec online in australia buy Cytotec cheapest buy finpecia without prescription finpecia buy cod want to buy finpecia in malaysia buy finpecia with mastercard Buy Finpecia 1 mg online microsoft onenote and educator discount window mirror film charset windows 1252 reinstal windows finpecia overdose excel new window windows for loop microsoft office 2008 for mac home student cheap collection software virtual dj software web design software mac cheap or discount photoshop software load windows xp buy Orlistat legally Rosuvastatin generic order buspar pharmacy buy Flomax in mo dreamweaver cs4 windows mobile opera adobe photoshop price epson creativity suite
Go to Top